From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) (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 5983481F9C for ; Wed, 25 Jan 2017 18:41:49 -0800 (PST) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga103.jf.intel.com with ESMTP; 25 Jan 2017 18:41:49 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.33,287,1477983600"; d="scan'208";a="58307072" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by fmsmga006.fm.intel.com with ESMTP; 25 Jan 2017 18:41:49 -0800 Received: from fmsmsx126.amr.corp.intel.com (10.18.125.43) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.248.2; Wed, 25 Jan 2017 18:41:48 -0800 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by FMSMSX126.amr.corp.intel.com (10.18.125.43) with Microsoft SMTP Server (TLS) id 14.3.248.2; Wed, 25 Jan 2017 18:41:48 -0800 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.59]) by SHSMSX103.ccr.corp.intel.com ([10.239.4.69]) with mapi id 14.03.0248.002; Thu, 26 Jan 2017 10:41:46 +0800 From: "Ni, Ruiyu" To: Thomas Huth , "edk2-devel@ml01.01.org" Thread-Topic: [PATCH] OptionRomPkg: Remove superfluous return statement Thread-Index: AQHSdvIao3od9Xy5zEuMrbISKFfEyqFKDVPQ Date: Thu, 26 Jan 2017 02:41:44 +0000 Deferred-Delivery: Thu, 26 Jan 2017 02:41:00 +0000 Message-ID: <734D49CCEBEEF84792F5B80ED585239D5B88BC05@SHSMSX104.ccr.corp.intel.com> References: <1485338519-29861-1-git-send-email-thuth@redhat.com> In-Reply-To: <1485338519-29861-1-git-send-email-thuth@redhat.com> Accept-Language: en-US, zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH] OptionRomPkg: Remove superfluous return statement X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Jan 2017 02:41:49 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Ruiyu Ni Thanks/Ray > -----Original Message----- > From: Thomas Huth [mailto:thuth@redhat.com] > Sent: Wednesday, January 25, 2017 6:02 PM > To: edk2-devel@ml01.01.org > Cc: Ni, Ruiyu > Subject: [PATCH] OptionRomPkg: Remove superfluous return statement >=20 > If the code eventually returns "Status" anyway, it does not make sense to > explicitly return "Status" in case of an error, too. >=20 > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Thomas Huth > --- > OptionRomPkg/Bus/Usb/FtdiUsbSerialDxe/FtdiUsbSerialDriver.c | 3 --- > 1 file changed, 3 deletions(-) >=20 > diff --git a/OptionRomPkg/Bus/Usb/FtdiUsbSerialDxe/FtdiUsbSerialDriver.c > b/OptionRomPkg/Bus/Usb/FtdiUsbSerialDxe/FtdiUsbSerialDriver.c > index c03606b..1eceb23 100644 > --- a/OptionRomPkg/Bus/Usb/FtdiUsbSerialDxe/FtdiUsbSerialDriver.c > +++ b/OptionRomPkg/Bus/Usb/FtdiUsbSerialDxe/FtdiUsbSerialDriver.c > @@ -2404,9 +2404,6 @@ SetAttributes ( > DataBits, > StopBits > ); > - if (EFI_ERROR (Status)) { > - return Status; > - } >=20 > return Status; > } > -- > 1.8.3.1