From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) (using TLSv1 with cipher CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id EE5AB1A1E43 for ; Wed, 26 Oct 2016 18:47:45 -0700 (PDT) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga102.jf.intel.com with ESMTP; 26 Oct 2016 18:47:45 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.31,404,1473145200"; d="scan'208";a="778286978" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by FMSMGA003.fm.intel.com with ESMTP; 26 Oct 2016 18:47:45 -0700 Received: from fmsmsx101.amr.corp.intel.com (10.18.124.199) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.248.2; Wed, 26 Oct 2016 18:47:45 -0700 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by fmsmsx101.amr.corp.intel.com (10.18.124.199) with Microsoft SMTP Server (TLS) id 14.3.248.2; Wed, 26 Oct 2016 18:47:45 -0700 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.209]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.139]) with mapi id 14.03.0248.002; Thu, 27 Oct 2016 09:47:43 +0800 From: "Ni, Ruiyu" To: Laszlo Ersek , edk2-devel-01 Thread-Topic: [PATCH 36/47] OptionRomPkg/AtapiPassThruDxe: rebase to ARRAY_SIZE() Thread-Index: AQHSL7wPToV2hI2B2UOzIc3AEVV2qqC7iLaw Date: Thu, 27 Oct 2016 01:47:42 +0000 Message-ID: <734D49CCEBEEF84792F5B80ED585239D58E42CD2@SHSMSX104.ccr.corp.intel.com> References: <20161026190504.9888-1-lersek@redhat.com> <20161026190504.9888-37-lersek@redhat.com> In-Reply-To: <20161026190504.9888-37-lersek@redhat.com> Accept-Language: en-US, zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiYTQ1NzdjNjctZGY0MC00NmEwLTgxN2ItNWQyZjZmYjM0ZDk2IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjkuNi42IiwiVHJ1c3RlZExhYmVsSGFzaCI6IlRKRXE0WlZMSjB2OVVBV0l4c015bllkbXFJUEI1ajVnVVZudHZsbG56NTg9In0= x-ctpclassification: CTP_IC x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH 36/47] OptionRomPkg/AtapiPassThruDxe: rebase to ARRAY_SIZE() 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, 27 Oct 2016 01:47:46 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Reviewed-by: Ruiyu Ni >-----Original Message----- >From: Laszlo Ersek [mailto:lersek@redhat.com] >Sent: Thursday, October 27, 2016 3:05 AM >To: edk2-devel-01 >Cc: Ni, Ruiyu >Subject: [PATCH 36/47] OptionRomPkg/AtapiPassThruDxe: rebase to ARRAY_SIZE= () > >Cc: Ruiyu Ni >Contributed-under: TianoCore Contribution Agreement 1.0 >Signed-off-by: Laszlo Ersek >--- > OptionRomPkg/AtapiPassThruDxe/AtapiPassThru.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/OptionRomPkg/AtapiPassThruDxe/AtapiPassThru.c b/OptionRomPkg/= AtapiPassThruDxe/AtapiPassThru.c >index 3578a1e4459c..e2654e5c2566 100644 >--- a/OptionRomPkg/AtapiPassThruDxe/AtapiPassThru.c >+++ b/OptionRomPkg/AtapiPassThruDxe/AtapiPassThru.c >@@ -1752,7 +1752,7 @@ Returns: > UINT8 ArrayLen; > > OpCode =3D (UINT8 *) (Packet->Cdb); >- ArrayLen =3D (UINT8) (sizeof (gSupportedATAPICommands) / sizeof (gSuppo= rtedATAPICommands[0])); >+ ArrayLen =3D (UINT8) (ARRAY_SIZE (gSupportedATAPICommands)); > > for (Index =3D 0; (Index < ArrayLen) && (CompareMem (&gSupportedATAPICo= mmands[Index], &gEndTable, sizeof >(SCSI_COMMAND_SET)) !=3D 0); Index++) { > >@@ -1995,7 +1995,7 @@ Returns: > UINT8 ArrayLen; > > OpCode =3D (UINT8 *) (Packet->Cdb); >- ArrayLen =3D (UINT8) (sizeof (gSupportedATAPICommands) / sizeof (gSuppo= rtedATAPICommands[0])); >+ ArrayLen =3D (UINT8) (ARRAY_SIZE (gSupportedATAPICommands)); > > for (Index =3D 0; (Index < ArrayLen) && (CompareMem (&gSupportedATAPICo= mmands[Index], &gEndTable, sizeof >(SCSI_COMMAND_SET)) !=3D 0); Index++) { > >-- >2.9.2 >