public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Laszlo Ersek" <lersek@redhat.com>
To: devel@edk2.groups.io, nikita.leshchenko@oracle.com
Cc: liran.alon@oracle.com, aaron.young@oracle.com,
	Jordan Justen <jordan.l.justen@intel.com>,
	Ard Biesheuvel <ard.biesheuvel@arm.com>
Subject: Re: [edk2-devel] [PATCH v4 01/13] OvmfPkg/MptScsiDxe: Create empty driver
Date: Wed, 15 Apr 2020 08:31:44 +0200	[thread overview]
Message-ID: <a1340d16-6edf-bfd3-a5be-cfe592d462d1@redhat.com> (raw)
In-Reply-To: <20200414173813.7715-2-nikita.leshchenko@oracle.com>

On 04/14/20 19:38, Nikita Leshenko wrote:
> In preparation for implementing LSI Fusion MPT SCSI devices, create a
> basic scaffolding for a driver.
> 
> Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=2390
> Signed-off-by: Nikita Leshenko <nikita.leshchenko@oracle.com>
> Reviewed-by: Liran Alon <liran.alon@oracle.com>
> ---
>  Maintainers.txt                   |  3 ++-
>  OvmfPkg/MptScsiDxe/MptScsi.c      | 26 ++++++++++++++++++++++++++
>  OvmfPkg/MptScsiDxe/MptScsiDxe.inf | 26 ++++++++++++++++++++++++++
>  OvmfPkg/OvmfPkgIa32.dsc           |  4 ++++
>  OvmfPkg/OvmfPkgIa32.fdf           |  3 +++
>  OvmfPkg/OvmfPkgIa32X64.dsc        |  4 ++++
>  OvmfPkg/OvmfPkgIa32X64.fdf        |  3 +++
>  OvmfPkg/OvmfPkgX64.dsc            |  4 ++++
>  OvmfPkg/OvmfPkgX64.fdf            |  3 +++
>  9 files changed, 75 insertions(+), 1 deletion(-)
>  create mode 100644 OvmfPkg/MptScsiDxe/MptScsi.c
>  create mode 100644 OvmfPkg/MptScsiDxe/MptScsiDxe.inf
> 
> diff --git a/Maintainers.txt b/Maintainers.txt
> index 1733225722b6..01b5b8188158 100644
> --- a/Maintainers.txt
> +++ b/Maintainers.txt
> @@ -435,8 +435,9 @@ OvmfPkg: CSM modules
>  F: OvmfPkg/Csm/
>  R: David Woodhouse <dwmw2@infradead.org>
>  
> -OvmfPkg: PVSCSI driver
> +OvmfPkg: PVSCSI and MptScsi driver
>  F: OvmfPkg/PvScsiDxe/
> +F: OvmfPkg/MptScsiDxe/

(1) Please keep the "F:" lines sorted.

With that:

Reviewed-by: Laszlo Ersek <lersek@redhat.com>

Thanks
Laszlo

>  R: Liran Alon <liran.alon@oracle.com>
>  R: Nikita Leshenko <nikita.leshchenko@oracle.com>
>  
> diff --git a/OvmfPkg/MptScsiDxe/MptScsi.c b/OvmfPkg/MptScsiDxe/MptScsi.c
> new file mode 100644
> index 000000000000..c6c8142dfde6
> --- /dev/null
> +++ b/OvmfPkg/MptScsiDxe/MptScsi.c
> @@ -0,0 +1,26 @@
> +/** @file
> +
> +  This driver produces Extended SCSI Pass Thru Protocol instances for
> +  LSI Fusion MPT SCSI devices.
> +
> +  Copyright (C) 2020, Oracle and/or its affiliates.
> +
> +  SPDX-License-Identifier: BSD-2-Clause-Patent
> +
> +**/
> +
> +#include <Uefi/UefiSpec.h>
> +
> +//
> +// Entry Point
> +//
> +
> +EFI_STATUS
> +EFIAPI
> +MptScsiEntryPoint (
> +  IN EFI_HANDLE       ImageHandle,
> +  IN EFI_SYSTEM_TABLE *SystemTable
> +  )
> +{
> +  return EFI_UNSUPPORTED;
> +}
> diff --git a/OvmfPkg/MptScsiDxe/MptScsiDxe.inf b/OvmfPkg/MptScsiDxe/MptScsiDxe.inf
> new file mode 100644
> index 000000000000..b4006a7c2d97
> --- /dev/null
> +++ b/OvmfPkg/MptScsiDxe/MptScsiDxe.inf
> @@ -0,0 +1,26 @@
> +## @file
> +# This driver produces Extended SCSI Pass Thru Protocol instances for
> +# LSI Fusion MPT SCSI devices.
> +#
> +# Copyright (C) 2020, Oracle and/or its affiliates.
> +#
> +# SPDX-License-Identifier: BSD-2-Clause-Patent
> +#
> +##
> +
> +[Defines]
> +  INF_VERSION                    = 1.29
> +  BASE_NAME                      = MptScsiDxe
> +  FILE_GUID                      = 2B3DB5DD-B315-4961-8454-0AFF3C811B19
> +  MODULE_TYPE                    = UEFI_DRIVER
> +  VERSION_STRING                 = 1.0
> +  ENTRY_POINT                    = MptScsiEntryPoint
> +
> +[Sources]
> +  MptScsi.c
> +
> +[Packages]
> +  MdePkg/MdePkg.dec
> +
> +[LibraryClasses]
> +  UefiDriverEntryPoint
> diff --git a/OvmfPkg/OvmfPkgIa32.dsc b/OvmfPkg/OvmfPkgIa32.dsc
> index cbc5f0e583bc..158a5e9f39bd 100644
> --- a/OvmfPkg/OvmfPkgIa32.dsc
> +++ b/OvmfPkg/OvmfPkgIa32.dsc
> @@ -49,6 +49,7 @@ [Defines]
>    # Device drivers
>    #
>    DEFINE PVSCSI_ENABLE           = TRUE
> +  DEFINE MPT_SCSI_ENABLE         = TRUE
>  
>    #
>    # Flash size selection. Setting FD_SIZE_IN_KB on the command line directly to
> @@ -744,6 +745,9 @@ [Components]
>    OvmfPkg/XenPvBlkDxe/XenPvBlkDxe.inf
>  !if $(PVSCSI_ENABLE) == TRUE
>    OvmfPkg/PvScsiDxe/PvScsiDxe.inf
> +!endif
> +!if $(MPT_SCSI_ENABLE) == TRUE
> +  OvmfPkg/MptScsiDxe/MptScsiDxe.inf
>  !endif
>    MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
>    MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
> diff --git a/OvmfPkg/OvmfPkgIa32.fdf b/OvmfPkg/OvmfPkgIa32.fdf
> index 8e43f4264ecc..fd81b6fa8bed 100644
> --- a/OvmfPkg/OvmfPkgIa32.fdf
> +++ b/OvmfPkg/OvmfPkgIa32.fdf
> @@ -233,6 +233,9 @@ [FV.DXEFV]
>  !if $(PVSCSI_ENABLE) == TRUE
>  INF  OvmfPkg/PvScsiDxe/PvScsiDxe.inf
>  !endif
> +!if $(MPT_SCSI_ENABLE) == TRUE
> +INF  OvmfPkg/MptScsiDxe/MptScsiDxe.inf
> +!endif
>  
>  !if $(SECURE_BOOT_ENABLE) == TRUE
>    INF  SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
> diff --git a/OvmfPkg/OvmfPkgIa32X64.dsc b/OvmfPkg/OvmfPkgIa32X64.dsc
> index 6d69cc6cb56f..a6c5a1d9d050 100644
> --- a/OvmfPkg/OvmfPkgIa32X64.dsc
> +++ b/OvmfPkg/OvmfPkgIa32X64.dsc
> @@ -48,6 +48,7 @@ [Defines]
>    # Device drivers
>    #
>    DEFINE PVSCSI_ENABLE           = TRUE
> +  DEFINE MPT_SCSI_ENABLE         = TRUE
>  
>    #
>    # Flash size selection. Setting FD_SIZE_IN_KB on the command line directly to
> @@ -756,6 +757,9 @@ [Components.X64]
>    OvmfPkg/XenPvBlkDxe/XenPvBlkDxe.inf
>  !if $(PVSCSI_ENABLE) == TRUE
>    OvmfPkg/PvScsiDxe/PvScsiDxe.inf
> +!endif
> +!if $(MPT_SCSI_ENABLE) == TRUE
> +  OvmfPkg/MptScsiDxe/MptScsiDxe.inf
>  !endif
>    MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
>    MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
> diff --git a/OvmfPkg/OvmfPkgIa32X64.fdf b/OvmfPkg/OvmfPkgIa32X64.fdf
> index 25af9fbed48a..f71134a65931 100644
> --- a/OvmfPkg/OvmfPkgIa32X64.fdf
> +++ b/OvmfPkg/OvmfPkgIa32X64.fdf
> @@ -234,6 +234,9 @@ [FV.DXEFV]
>  !if $(PVSCSI_ENABLE) == TRUE
>  INF  OvmfPkg/PvScsiDxe/PvScsiDxe.inf
>  !endif
> +!if $(MPT_SCSI_ENABLE) == TRUE
> +INF  OvmfPkg/MptScsiDxe/MptScsiDxe.inf
> +!endif
>  
>  !if $(SECURE_BOOT_ENABLE) == TRUE
>    INF  SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
> diff --git a/OvmfPkg/OvmfPkgX64.dsc b/OvmfPkg/OvmfPkgX64.dsc
> index 5ad4f461ce52..9aa8dd9e5fe1 100644
> --- a/OvmfPkg/OvmfPkgX64.dsc
> +++ b/OvmfPkg/OvmfPkgX64.dsc
> @@ -48,6 +48,7 @@ [Defines]
>    # Device drivers
>    #
>    DEFINE PVSCSI_ENABLE           = TRUE
> +  DEFINE MPT_SCSI_ENABLE         = TRUE
>  
>    #
>    # Flash size selection. Setting FD_SIZE_IN_KB on the command line directly to
> @@ -754,6 +755,9 @@ [Components]
>    OvmfPkg/XenPvBlkDxe/XenPvBlkDxe.inf
>  !if $(PVSCSI_ENABLE) == TRUE
>    OvmfPkg/PvScsiDxe/PvScsiDxe.inf
> +!endif
> +!if $(MPT_SCSI_ENABLE) == TRUE
> +  OvmfPkg/MptScsiDxe/MptScsiDxe.inf
>  !endif
>    MdeModulePkg/Universal/WatchdogTimerDxe/WatchdogTimer.inf
>    MdeModulePkg/Universal/MonotonicCounterRuntimeDxe/MonotonicCounterRuntimeDxe.inf
> diff --git a/OvmfPkg/OvmfPkgX64.fdf b/OvmfPkg/OvmfPkgX64.fdf
> index 25af9fbed48a..f71134a65931 100644
> --- a/OvmfPkg/OvmfPkgX64.fdf
> +++ b/OvmfPkg/OvmfPkgX64.fdf
> @@ -234,6 +234,9 @@ [FV.DXEFV]
>  !if $(PVSCSI_ENABLE) == TRUE
>  INF  OvmfPkg/PvScsiDxe/PvScsiDxe.inf
>  !endif
> +!if $(MPT_SCSI_ENABLE) == TRUE
> +INF  OvmfPkg/MptScsiDxe/MptScsiDxe.inf
> +!endif
>  
>  !if $(SECURE_BOOT_ENABLE) == TRUE
>    INF  SecurityPkg/VariableAuthenticated/SecureBootConfigDxe/SecureBootConfigDxe.inf
> 


  reply	other threads:[~2020-04-15  6:31 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-14 17:38 [PATCH v4 00/13] OvmfPkg: Support booting from Fusion-MPT SCSI controllers Nikita Leshenko
2020-04-14 17:38 ` [PATCH v4 01/13] OvmfPkg/MptScsiDxe: Create empty driver Nikita Leshenko
2020-04-15  6:31   ` Laszlo Ersek [this message]
2020-04-14 17:38 ` [PATCH v4 02/13] OvmfPkg/MptScsiDxe: Install DriverBinding Protocol Nikita Leshenko
2020-04-14 17:38 ` [PATCH v4 03/13] OvmfPkg/MptScsiDxe: Report name of driver Nikita Leshenko
2020-04-14 17:38 ` [PATCH v4 04/13] OvmfPkg/MptScsiDxe: Probe PCI devices and look for MptScsi Nikita Leshenko
2020-04-14 17:38 ` [PATCH v4 05/13] OvmfPkg/MptScsiDxe: Install stubbed EXT_SCSI_PASS_THRU Nikita Leshenko
2020-04-15  6:54   ` [edk2-devel] " Laszlo Ersek
2020-04-14 17:38 ` [PATCH v4 06/13] OvmfPkg/MptScsiDxe: Report one Target and one LUN Nikita Leshenko
2020-04-14 17:38 ` [PATCH v4 07/13] OvmfPkg/MptScsiDxe: Build and decode DevicePath Nikita Leshenko
2020-04-15 12:03   ` [edk2-devel] " Laszlo Ersek
2020-04-14 17:38 ` [PATCH v4 08/13] OvmfPkg/MptScsiDxe: Open PciIo protocol for later use Nikita Leshenko
2020-04-16  8:05   ` [edk2-devel] " Laszlo Ersek
2020-04-14 17:38 ` [PATCH v4 09/13] OvmfPkg/MptScsiDxe: Set and restore PCI attributes Nikita Leshenko
2020-04-16  8:11   ` [edk2-devel] " Laszlo Ersek
2020-04-14 17:38 ` [PATCH v4 10/13] OvmfPkg/MptScsiDxe: Initialize hardware Nikita Leshenko
2020-04-16  9:53   ` [edk2-devel] " Laszlo Ersek
2020-04-16 16:00     ` Nikita Leshenko
2020-04-20 11:58       ` Laszlo Ersek
2020-04-20 14:10   ` Laszlo Ersek
2020-04-14 17:38 ` [PATCH v4 11/13] OvmfPkg/MptScsiDxe: Implement the PassThru method Nikita Leshenko
2020-04-20 17:30   ` [edk2-devel] " Laszlo Ersek
2020-04-24 17:03     ` Nikita Leshenko
2020-04-14 17:38 ` [PATCH v4 12/13] OvmfPkg/MptScsiDxe: Report multiple targets Nikita Leshenko
2020-04-20 18:31   ` [edk2-devel] " Laszlo Ersek
2020-04-14 17:38 ` [PATCH v4 13/13] OvmfPkg/MptScsiDxe: Reset device on ExitBootServices() Nikita Leshenko
2020-04-20 19:02   ` [edk2-devel] " Laszlo Ersek

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a1340d16-6edf-bfd3-a5be-cfe592d462d1@redhat.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox