1. Fix issues comments
2. Fix Guid/protocol format

Cc: Ard Biesheuvel <ard.biesheu...@linaro.org>
Cc: Ruiyu Ni <ruiyu...@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Dandan Bi <dandan...@intel.com>
---
 .../Library/NonDiscoverableDeviceRegistrationLib.h |  4 +++-
 .../NonDiscoverableDeviceRegistrationLib.c         | 14 ++++++++++++--
 .../NonDiscoverableDeviceRegistrationLib.inf       | 22 ++++++++++++----------
 3 files changed, 27 insertions(+), 13 deletions(-)

diff --git 
a/MdeModulePkg/Include/Library/NonDiscoverableDeviceRegistrationLib.h 
b/MdeModulePkg/Include/Library/NonDiscoverableDeviceRegistrationLib.h
index 120d914..c2d9e48 100644
--- a/MdeModulePkg/Include/Library/NonDiscoverableDeviceRegistrationLib.h
+++ b/MdeModulePkg/Include/Library/NonDiscoverableDeviceRegistrationLib.h
@@ -30,21 +30,23 @@ typedef enum {
 } NON_DISCOVERABLE_DEVICE_TYPE;
 
 /**
   Register a non-discoverable MMIO device
 
-  @param[in]      DeviceType          The type of non-discoverable device
+  @param[in]      Type                The type of non-discoverable device
   @param[in]      DmaType             Whether the device is DMA coherent
   @param[in]      InitFunc            Initialization routine to be invoked when
                                       the device is enabled
   @param[in,out]  Handle              The handle onto which to install the
                                       non-discoverable device protocol.
                                       If Handle is NULL or *Handle is NULL, a
                                       new handle will be allocated.
   @param[in]      NumMmioResources    The number of UINTN base/size pairs that
                                       follow, each describing an MMIO region
                                       owned by the device
+  @param[in]  ...                     The variable argument list which 
contains the
+                                      info about MmioResources.
 
   @retval EFI_SUCCESS                 The registration succeeded.
   @retval Other                       The registration failed.
 
 **/
diff --git 
a/MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.c
 
b/MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.c
index 94cd946..6f46dfa 100644
--- 
a/MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.c
+++ 
b/MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.c
@@ -23,10 +23,18 @@
 #include <Library/UefiBootServicesTableLib.h>
 
 #include <Protocol/DevicePath.h>
 #include <Protocol/NonDiscoverableDevice.h>
 
+/**
+  Get Guid form the type of non-discoverable device.
+
+  @param[in]  Type    The type of non-discoverable device.
+
+  @retval   Return the Guid.
+
+**/
 STATIC
 CONST EFI_GUID *
 GetGuidFromType (
   IN  NON_DISCOVERABLE_DEVICE_TYPE  Type
   )
@@ -72,23 +80,25 @@ typedef struct {
   EFI_DEVICE_PATH_PROTOCOL            End;
 } NON_DISCOVERABLE_DEVICE_PATH;
 #pragma pack ()
 
 /**
-  Register a non-discoverable MMIO device
+  Register a non-discoverable MMIO device.
 
-  @param[in]      DeviceType          The type of non-discoverable device
+  @param[in]      Type                The type of non-discoverable device
   @param[in]      DmaType             Whether the device is DMA coherent
   @param[in]      InitFunc            Initialization routine to be invoked when
                                       the device is enabled
   @param[in,out]  Handle              The handle onto which to install the
                                       non-discoverable device protocol.
                                       If Handle is NULL or *Handle is NULL, a
                                       new handle will be allocated.
   @param[in]      NumMmioResources    The number of UINTN base/size pairs that
                                       follow, each describing an MMIO region
                                       owned by the device
+  @param[in]  ...                     The variable argument list which 
contains the
+                                      info about MmioResources.
 
   @retval EFI_SUCCESS                 The registration succeeded.
   @retval EFI_INVALID_PARAMETER       An invalid argument was given
   @retval Other                       The registration failed.
 
diff --git 
a/MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.inf
 
b/MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.inf
index ba32324..dfcf8dc 100644
--- 
a/MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.inf
+++ 
b/MdeModulePkg/Library/NonDiscoverableDeviceRegistrationLib/NonDiscoverableDeviceRegistrationLib.inf
@@ -1,6 +1,8 @@
 # @file
+# Component Description File for NonDiscoverableDeviceRegistrationLib.
+#
 # Copyright (c) 2016, Linaro, Ltd. All rights reserved.<BR>
 #
 # This program and the accompanying materials
 # are licensed and made available under the terms and conditions of the BSD 
License
 # which accompanies this distribution.  The full text of the license may be 
found at
@@ -30,17 +32,17 @@ [LibraryClasses]
   DebugLib
   DevicePathLib
   UefiBootServicesTableLib
 
 [Protocols]
-  gEdkiiNonDiscoverableDeviceProtocolGuid
+  gEdkiiNonDiscoverableDeviceProtocolGuid    ## PRODUCES
 
 [Guids]
-  gEdkiiNonDiscoverableAhciDeviceGuid
-  gEdkiiNonDiscoverableAmbaDeviceGuid
-  gEdkiiNonDiscoverableEhciDeviceGuid
-  gEdkiiNonDiscoverableNvmeDeviceGuid
-  gEdkiiNonDiscoverableOhciDeviceGuid
-  gEdkiiNonDiscoverableSdhciDeviceGuid
-  gEdkiiNonDiscoverableUfsDeviceGuid
-  gEdkiiNonDiscoverableUhciDeviceGuid
-  gEdkiiNonDiscoverableXhciDeviceGuid
+  gEdkiiNonDiscoverableAhciDeviceGuid    ## CONSUMES   ## GUID
+  gEdkiiNonDiscoverableAmbaDeviceGuid    ## CONSUMES   ## GUID
+  gEdkiiNonDiscoverableEhciDeviceGuid    ## CONSUMES   ## GUID
+  gEdkiiNonDiscoverableNvmeDeviceGuid    ## CONSUMES   ## GUID
+  gEdkiiNonDiscoverableOhciDeviceGuid    ## CONSUMES   ## GUID
+  gEdkiiNonDiscoverableSdhciDeviceGuid   ## CONSUMES   ## GUID
+  gEdkiiNonDiscoverableUfsDeviceGuid     ## CONSUMES   ## GUID
+  gEdkiiNonDiscoverableUhciDeviceGuid    ## CONSUMES   ## GUID
+  gEdkiiNonDiscoverableXhciDeviceGuid    ## CONSUMES   ## GUID
-- 
1.9.5.msysgit.1

_______________________________________________
edk2-devel mailing list
edk2-devel@lists.01.org
https://lists.01.org/mailman/listinfo/edk2-devel

Reply via email to