From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=104.47.2.83; helo=eur01-db5-obe.outbound.protection.outlook.com; envelope-from=meenakshi.aggarwal@nxp.com; receiver=edk2-devel@lists.01.org Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0083.outbound.protection.outlook.com [104.47.2.83]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 3EF53220F33CF for ; Thu, 15 Feb 2018 04:02:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=rVHrdCds2dgMXklV7hLHUZMCjP/NGoDX8gZs8Euiupk=; b=aMSYW74/z2PZVa5iLNK7gJscDOsZogutaJcY+x8AUU/7ku1Zpzysg/uA+RsSlqlGcx+rt75BhmXf4E6tA8/rwin1IiCzTgFFeWdx8CkFceiimXrajh5Jxdopfam/UmJdSeeuP2s1VK0MzJZlsK7Qya2ocFOlUIfm2fj6zGsi56U= Received: from DB5PR04MB0998.eurprd04.prod.outlook.com (10.161.199.12) by DB5PR04MB1624.eurprd04.prod.outlook.com (10.164.38.154) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.506.18; Thu, 15 Feb 2018 12:08:38 +0000 Received: from DB5PR04MB0998.eurprd04.prod.outlook.com ([fe80::5b4:dfb7:891f:32ce]) by DB5PR04MB0998.eurprd04.prod.outlook.com ([fe80::5b4:dfb7:891f:32ce%13]) with mapi id 15.20.0485.015; Thu, 15 Feb 2018 12:08:37 +0000 From: Meenakshi Aggarwal To: Meenakshi Aggarwal , "ruiyu.ni@intel.com" , "jaben.carsey@intel.com" , "edk2-devel@lists.01.org" Thread-Topic: [PATCH] RFC : Ping : Fix for loss of first ping packet Thread-Index: AQHTpK3icgPy8vaNCUmz5mBiOFpiuqOlYePw Date: Thu, 15 Feb 2018 12:08:36 +0000 Message-ID: References: <1518535345-3327-1-git-send-email-meenakshi.aggarwal@nxp.com> In-Reply-To: <1518535345-3327-1-git-send-email-meenakshi.aggarwal@nxp.com> Accept-Language: en-GB, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=meenakshi.aggarwal@nxp.com; x-originating-ip: [180.188.246.227] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; DB5PR04MB1624; 7:bXNyKebDN8rg+6kCdoXnpRmjkmX3b/j4wIga03LsgfA9NpVRqK5tFxUsHCwTwlvlgJJuq7fsJsS5DbCZGYCLofZDGq599yXtVQUp6NV9XsFY1hoCUhIJN7Z8Tn3bq//JxGKVHvC+KXuUeTVaSPO7rjMigbSb+lhCRCddK4JpTzWMQHNZiHImV1LMF/XLG49XYe7WnCSiw1ei6C9mDcfnGIO4cFcHDaTfviGgjx2g4qO1R1t2jDOXzEX46JZ1FRnp x-ms-exchange-antispam-srfa-diagnostics: SSOS;SSOR; x-forefront-antispam-report: SFV:SKI; SCL:-1; SFV:NSPM; SFS:(10009020)(396003)(366004)(39860400002)(376002)(346002)(39380400002)(13464003)(189003)(199004)(2501003)(3660700001)(53546011)(6506007)(68736007)(97736004)(478600001)(25786009)(99286004)(81166006)(5660300001)(59450400001)(6436002)(229853002)(305945005)(7736002)(26005)(2900100001)(4326008)(7696005)(106356001)(102836004)(81156014)(33656002)(3280700002)(6246003)(14454004)(2950100002)(2201001)(86362001)(53936002)(5250100002)(2906002)(8676002)(316002)(105586002)(6116002)(76176011)(110136005)(54906003)(66066001)(55016002)(3846002)(74316002)(9686003)(8936002); DIR:OUT; SFP:1101; SCL:1; SRVR:DB5PR04MB1624; H:DB5PR04MB0998.eurprd04.prod.outlook.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: 2f66a6f6-eb1e-412b-977c-08d5746cd803 x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(48565401081)(5600026)(4604075)(3008032)(2017052603307)(7153060)(7193020); SRVR:DB5PR04MB1624; x-ms-traffictypediagnostic: DB5PR04MB1624: x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:(185117386973197)(162533806227266)(228905959029699); x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(6040501)(2401047)(8121501046)(5005006)(3231101)(944501161)(10201501046)(3002001)(93006095)(93001095)(6055026)(6041288)(20161123560045)(20161123562045)(20161123564045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(6072148)(201708071742011); SRVR:DB5PR04MB1624; BCL:0; PCL:0; RULEID:; SRVR:DB5PR04MB1624; x-forefront-prvs: 058441C12A received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-microsoft-antispam-message-info: sYZsSrz1Gfj/ffa5lGyKU5T8mk2VqIIG58fELgvJ9NP3ev2SUrQXXBRomwcxAHskeKf5R7IIsagXGOMUCxrchQ== spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 2f66a6f6-eb1e-412b-977c-08d5746cd803 X-MS-Exchange-CrossTenant-originalarrivaltime: 15 Feb 2018 12:08:37.1415 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB5PR04MB1624 Subject: Re: [PATCH] RFC : Ping : Fix for loss of first ping packet X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 15 Feb 2018 12:02:50 -0000 Content-Language: en-US Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: quoted-printable Hi, Any comment? Thanks & Regards, Meenakshi > -----Original Message----- > From: Meenakshi Aggarwal [mailto:meenakshi.aggarwal@nxp.com] > Sent: Tuesday, February 13, 2018 8:52 PM > To: ruiyu.ni@intel.com; jaben.carsey@intel.com; edk2-devel@lists.01.org > Cc: Udit Kumar ; Varun Sethi ; > Meenakshi Aggarwal > Subject: [PATCH] RFC : Ping : Fix for loss of first ping packet >=20 > Issue: > Reply for first ping packet was getting dropped. >=20 > Cause: > Sometimes reply message comes even before trasmit > function returns, hence missing 1st reply >=20 > Fix: > Prepare the TxList before calling Transmit function. >=20 > Contributed-under: TianoCore Contribution Agreement 1.1 > Signed-off-by: Meenakshi Aggarwal > --- > ShellPkg/Library/UefiShellNetwork1CommandsLib/Ping.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) >=20 > diff --git a/ShellPkg/Library/UefiShellNetwork1CommandsLib/Ping.c > b/ShellPkg/Library/UefiShellNetwork1CommandsLib/Ping.c > index bec9535..46ba701 100644 > --- a/ShellPkg/Library/UefiShellNetwork1CommandsLib/Ping.c > +++ b/ShellPkg/Library/UefiShellNetwork1CommandsLib/Ping.c > @@ -784,14 +784,17 @@ PingSendEchoRequest ( > } >=20 > ASSERT(Private->ProtocolPointers.Transmit !=3D NULL); > + > + InsertTailList (&Private->TxList, &TxInfo->Link); > + > Status =3D Private->ProtocolPointers.Transmit (Private->IpProtocol, Tx= Info- > >Token); >=20 > if (EFI_ERROR (Status)) { > + RemoveEntryList (&TxInfo->Link); > PingDestroyTxInfo (TxInfo, Private->IpChoice); > return Status; > } >=20 > - InsertTailList (&Private->TxList, &TxInfo->Link); > Private->TxCount++; >=20 > return EFI_SUCCESS; > -- > 1.9.1