From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=134.134.136.31; helo=mga06.intel.com; envelope-from=jiaxin.wu@intel.com; receiver=edk2-devel@lists.01.org Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 300B321B00DC1 for ; Tue, 14 Nov 2017 21:51:32 -0800 (PST) Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga104.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Nov 2017 21:55:40 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,398,1505804400"; d="scan'208";a="173682855" Received: from fmsmsx104.amr.corp.intel.com ([10.18.124.202]) by orsmga005.jf.intel.com with ESMTP; 14 Nov 2017 21:55:39 -0800 Received: from fmsmsx117.amr.corp.intel.com (10.18.116.17) by fmsmsx104.amr.corp.intel.com (10.18.124.202) with Microsoft SMTP Server (TLS) id 14.3.319.2; Tue, 14 Nov 2017 21:55:39 -0800 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by fmsmsx117.amr.corp.intel.com (10.18.116.17) with Microsoft SMTP Server (TLS) id 14.3.319.2; Tue, 14 Nov 2017 21:55:39 -0800 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.213]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.159]) with mapi id 14.03.0319.002; Wed, 15 Nov 2017 13:55:37 +0800 From: "Wu, Jiaxin" To: "Fu, Siyuan" , "edk2-devel@lists.01.org" CC: "Ye, Ting" Thread-Topic: [Patch] MdeModulePkg/SNP: remove redundant DEBUG print in SNP Transmit.c Thread-Index: AQHTXb/mqySMWjfekEWTR2wJ4tJj56MU8S5g Date: Wed, 15 Nov 2017 05:55:37 +0000 Message-ID: <895558F6EA4E3B41AC93A00D163B727416347044@SHSMSX103.ccr.corp.intel.com> References: <20171115031443.17784-1-siyuan.fu@intel.com> In-Reply-To: <20171115031443.17784-1-siyuan.fu@intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiMzBhODk5MTItM2I5NS00M2UwLTg4NDgtM2RiZDU0MmZkYjhhIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE2LjUuOS4zIiwiVHJ1c3RlZExhYmVsSGFzaCI6IjU0bk90M294YXdUV1RDMkNtRlN4VklNc1lIUzdyM2w0WWFyYVp3bkxwdUk9In0= x-ctpclassification: CTP_IC dlp-product: dlpe-windows dlp-version: 11.0.0.116 dlp-reaction: no-action x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [Patch] MdeModulePkg/SNP: remove redundant DEBUG print in SNP Transmit.c X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Nov 2017 05:51:33 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Wu Jiaxin > -----Original Message----- > From: Fu, Siyuan > Sent: Wednesday, November 15, 2017 11:15 AM > To: edk2-devel@lists.01.org > Cc: Wu, Jiaxin ; Ye, Ting > Subject: [Patch] MdeModulePkg/SNP: remove redundant DEBUG print in > SNP Transmit.c >=20 > This patch is to remove some redundant DEBUG output in SNP transmit > function. > In case of return EFI_NOT_READY in PxeTransmit, the SNP driver is indicat= e > the caller that the transmit queue is full, it's a very common situation = druing > transmit, not a critical error. So the patch move the DEBUG lever to > EFI_D_NET. >=20 > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Fu Siyuan > Cc: Wu Jiaxin > Cc: Ye Ting > --- > MdeModulePkg/Universal/Network/SnpDxe/Transmit.c | 22 > +++++++++++++--------- > 1 file changed, 13 insertions(+), 9 deletions(-) >=20 > diff --git a/MdeModulePkg/Universal/Network/SnpDxe/Transmit.c > b/MdeModulePkg/Universal/Network/SnpDxe/Transmit.c > index 73461bc..2c7083e 100644 > --- a/MdeModulePkg/Universal/Network/SnpDxe/Transmit.c > +++ b/MdeModulePkg/Universal/Network/SnpDxe/Transmit.c > @@ -1,7 +1,7 @@ > /** @file > Implementation of transmitting a packet. >=20 > -Copyright (c) 2004 - 2016, Intel Corporation. All rights reserved.
> +Copyright (c) 2004 - 2017, Intel Corporation. All rights reserved.
> This program and the accompanying materials are licensed > and made available under the terms and conditions of the BSD License whi= ch > accompanies this distribution. The full text of the license may be found= at > @@ -186,7 +186,6 @@ PxeTransmit ( > (*Snp->IssueUndi32Command) ((UINT64) (UINTN) &Snp->Cdb); >=20 > DEBUG ((EFI_D_NET, "\nexit Snp->undi.transmit() ")); > - DEBUG ((EFI_D_NET, "\nSnp->Cdb.StatCode =3D=3D %r", Snp->Cdb.StatCode)= ); >=20 > // > // we will unmap the buffers in get_status call, not here > @@ -199,19 +198,24 @@ PxeTransmit ( > case PXE_STATCODE_QUEUE_FULL: > case PXE_STATCODE_BUSY: > Status =3D EFI_NOT_READY; > + DEBUG ( > + (EFI_D_NET, > + "\nSnp->undi.transmit() %xh:%xh\n", > + Snp->Cdb.StatFlags, > + Snp->Cdb.StatCode) > + ); > break; >=20 > default: > + DEBUG ( > + (EFI_D_ERROR, > + "\nSnp->undi.transmit() %xh:%xh\n", > + Snp->Cdb.StatFlags, > + Snp->Cdb.StatCode) > + ); > Status =3D EFI_DEVICE_ERROR; > } >=20 > - DEBUG ( > - (EFI_D_ERROR, > - "\nSnp->undi.transmit() %xh:%xh\n", > - Snp->Cdb.StatFlags, > - Snp->Cdb.StatCode) > - ); > - > return Status; > } >=20 > -- > 1.9.5.msysgit.1