From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from userp2130.oracle.com (userp2130.oracle.com [156.151.31.86]) by mx.groups.io with SMTP id smtpd.web10.2420.1588171537538518590 for ; Wed, 29 Apr 2020 07:45:37 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@oracle.com header.s=corp-2020-01-29 header.b=yX6ghJdI; spf=pass (domain: oracle.com, ip: 156.151.31.86, mailfrom: liran.alon@oracle.com) Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 03TEiJQ2008817; Wed, 29 Apr 2020 14:45:34 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : to : cc : references : from : message-id : date : mime-version : in-reply-to : content-type : content-transfer-encoding; s=corp-2020-01-29; bh=mdYXQMzRRYHFRANMaJ5HhhPoKDYZlK8TCgpiPhzG/gI=; b=yX6ghJdImdUgBQwj4cst7+Z2N7UKs6ugQjE1zMrEdSBwityDW73r8T+DgMNMmfYSUVjT U7KmUVKATfDU/KIWrzmCjtiZnJB/h0yAMfgszAxoOmJWlBb6/oOD+0A2em4fxmXu41aC RgKqI7EnuCCMtqOD8s1aQDug7fka4Ch36kB7zXcLALQFoTX0qiIZqZt4/ev6xRdoHIj2 vg3yinXburD9QJXiPbMq/GcAWx15GH62vD2XF86m6Nsq36gqqLnRbjwpA6268rIK4YE8 Z5aUekgvTh5ilmBe+wUjFvp3qZIdnz2z6KWsLOdqW9+jKghI+8rBPL5FGANFHYVnLIZv IA== Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by userp2130.oracle.com with ESMTP id 30p01nvq65-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 29 Apr 2020 14:45:33 +0000 Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 03TEg6xk107555; Wed, 29 Apr 2020 14:45:33 GMT Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserp3030.oracle.com with ESMTP id 30mxrv80p4-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 29 Apr 2020 14:45:33 +0000 Received: from abhmp0014.oracle.com (abhmp0014.oracle.com [141.146.116.20]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 03TEjVYO001279; Wed, 29 Apr 2020 14:45:31 GMT Received: from [192.168.14.112] (/79.176.191.156) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 29 Apr 2020 07:45:31 -0700 Subject: Re: [edk2-devel] [PATCH v5 06/12] OvmfPkg/MptScsiDxe: Report targets and one LUN To: Laszlo Ersek , devel@edk2.groups.io, nikita.leshchenko@oracle.com Cc: aaron.young@oracle.com, Jordan Justen , Ard Biesheuvel References: <20200424175927.41210-1-nikita.leshchenko@oracle.com> <20200424175927.41210-7-nikita.leshchenko@oracle.com> <4f6278f1-f04d-ce38-38f6-8d45401d0bf1@redhat.com> From: "Liran Alon" Message-ID: Date: Wed, 29 Apr 2020 17:45:28 +0300 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9605 signatures=668686 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxscore=0 phishscore=0 suspectscore=0 mlxlogscore=999 malwarescore=0 bulkscore=0 spamscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2004290123 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9605 signatures=668686 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 bulkscore=0 spamscore=0 clxscore=1011 phishscore=0 mlxlogscore=999 adultscore=0 priorityscore=1501 mlxscore=0 suspectscore=0 malwarescore=0 lowpriorityscore=0 impostorscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2004290123 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US On 29/04/2020 16:39, Laszlo Ersek wrote: > On 04/29/20 15:38, Laszlo Ersek wrote: >> On 04/24/20 19:59, Nikita Leshenko wrote: >>> diff --git a/OvmfPkg/MptScsiDxe/MptScsiDxe.inf b/OvmfPkg/MptScsiDxe/MptScsiDxe.inf >>> index 9f7c98829ee1..4862ff9dd497 100644 >>> --- a/OvmfPkg/MptScsiDxe/MptScsiDxe.inf >>> +++ b/OvmfPkg/MptScsiDxe/MptScsiDxe.inf >>> @@ -24,6 +24,7 @@ [Packages] >>> OvmfPkg/OvmfPkg.dec >>> >>> [LibraryClasses] >>> + BaseMemoryLib >>> DebugLib >>> MemoryAllocationLib >>> UefiBootServicesTableLib >>> @@ -33,3 +34,6 @@ [LibraryClasses] >>> [Protocols] >>> gEfiExtScsiPassThruProtocolGuid ## BY_START >>> gEfiPciIoProtocolGuid ## TO_START >>> + >>> +[FixedPcd] >>> + gUefiOvmfPkgTokenSpaceGuid.PcdMptScsiMaxTargetLimit ## CONSUMES >>> diff --git a/OvmfPkg/OvmfPkg.dec b/OvmfPkg/OvmfPkg.dec >>> index 28030391cff2..2d09444bbb16 100644 >>> --- a/OvmfPkg/OvmfPkg.dec >>> +++ b/OvmfPkg/OvmfPkg.dec >>> @@ -163,6 +163,10 @@ [PcdsFixedAtBuild] >>> # polling loop iteration. >>> gUefiOvmfPkgTokenSpaceGuid.PcdPvScsiWaitForCmpStallInUsecs|5|UINT32|0x38 >>> >>> + ## Set the *inclusive* number of targets that MptScsi exposes for scan >>> + # by ScsiBusDxe. >>> + gUefiOvmfPkgTokenSpaceGuid.PcdMptScsiMaxTargetLimit|7|UINT8|0x39 >>> + >>> gUefiOvmfPkgTokenSpaceGuid.PcdOvmfFlashNvStorageEventLogBase|0x0|UINT32|0x8 >>> gUefiOvmfPkgTokenSpaceGuid.PcdOvmfFlashNvStorageEventLogSize|0x0|UINT32|0x9 >>> gUefiOvmfPkgTokenSpaceGuid.PcdOvmfFirmwareFdSize|0x0|UINT32|0xa >>> >> (1) should be #include'd in this patch, and PcdLib should be >> listed under [LibraryClasses]. >> >> On one hand, that's a minor wart. The driver (and the OVMF platform(s)) >> build OK at this stage, in practice. (I tested that.) So this, per se, >> does not justify a v6. >> >> On the other hand, even at the end of the series, the module does not >> spell out the PcdLib dependency (neither #include nor [LibraryClasses]). >> That's not so nice. >> >> But, I'll fix that up for you, if there's not going to be another reason >> for a v6. >> >> With (1) addressed (by you, or by me): >> >> Reviewed-by: Laszlo Ersek >> >> Thanks, >> Laszlo >> > ... BTW I missed the same in the PvScsiDxe driver :/ > > Liran, can you post a patch for that, please? > > Thanks, > Laszlo Sure. Will do. Quite surprised it builds successfully without it. BTW, VirtioScsi DXE driver also seems to be missing PcdLib dependency both in #include and [LibraryClasses] as-well. I can submit a patch for that as-well if you like. -Liran