MdeModulePkg/Mtftp4Dxe: Separate the timer ticking to calculate the packet live time.

TPL deadlock issue was enrolled by the commit of 39b0867d. To resolve the issue,
this patch separated the timer ticking for all the MTFTP clients to calculate the
packet live time in TPL_NOTIFY level.

Cc: Wang Fan <fan.wang@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Cc: Ye Ting <ting.ye@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Fu Siyuan <siyuan.fu@intel.com>
Signed-off-by: Jiaxin Wu <jiaxin.wu@intel.com>
Reviewed-by: Ye Ting <ting.ye@intel.com>
Reviewed-by: Fu Siyuan <siyuan.fu@intel.com>
(cherry picked from commit 0e2a5749d8)
This commit is contained in:
Fu Siyuan
2018-03-02 11:33:28 +08:00
committed by Jiaxin Wu
parent dded7cddfc
commit 65208a68ce
5 changed files with 98 additions and 22 deletions

View File

@ -1082,6 +1082,7 @@ EfiMtftp4Poll (
{
MTFTP4_PROTOCOL *Instance;
EFI_UDP4_PROTOCOL *Udp;
EFI_STATUS Status;
if (This == NULL) {
return EFI_INVALID_PARAMETER;
@ -1096,7 +1097,9 @@ EfiMtftp4Poll (
}
Udp = Instance->UnicastPort->Protocol.Udp4;
return Udp->Poll (Udp);
Status = Udp->Poll (Udp);
Mtftp4OnTimerTick (NULL, Instance->Service);
return Status;
}
EFI_MTFTP4_PROTOCOL gMtftp4ProtocolTemplate = {