]> git.proxmox.com Git - mirror_edk2.git/commitdiff
1. Add comments in INF file to describe limitation.
authorxli24 <xli24@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 28 Jan 2010 08:29:35 +0000 (08:29 +0000)
committerxli24 <xli24@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 28 Jan 2010 08:29:35 +0000 (08:29 +0000)
2. Return EFI_UNSUPPORTED where reasonable.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9850 6f19259b-4bc3-4df7-8a09-765794883524

MdeModulePkg/Universal/LegacyRegion2Dxe/LegacyRegion2.c
MdeModulePkg/Universal/LegacyRegion2Dxe/LegacyRegion2Dxe.inf

index 9838fa8b8f10a0647090509989242435db916be3..0a9403b02332d389d5146ccf049d6115a70e507f 100644 (file)
@@ -7,7 +7,7 @@
   be used as a template driver for implementing the Legacy Region 2 Protocol on\r
   a platform that does support HW locking of the legacy memory regions.\r
 \r
   be used as a template driver for implementing the Legacy Region 2 Protocol on\r
   a platform that does support HW locking of the legacy memory regions.\r
 \r
-Copyright (c) 2009, Intel Corporation\r
+Copyright (c) 2009 - 2010, Intel Corporation\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
 All rights reserved. This program and the accompanying materials\r
 are licensed and made available under the terms and conditions of the BSD License\r
 which accompanies this distribution.  The full text of the license may be found at\r
@@ -149,9 +149,7 @@ LegacyRegion2BootLock (
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r
-  ASSERT (Granularity != NULL);\r
-  *Granularity = 0;\r
-  return EFI_SUCCESS;\r
+  return EFI_UNSUPPORTED;\r
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
@@ -199,7 +197,7 @@ LegacyRegion2Unlock (
   region. Each attribute may have a different granularity and the granularity may not be the same\r
   for all memory ranges in the legacy region.  \r
 \r
   region. Each attribute may have a different granularity and the granularity may not be the same\r
   for all memory ranges in the legacy region.  \r
 \r
-  @param  This[in]              Indicates the EFI_LEGACY_REGION_PROTOCOL instance.\r
+  @param  This[in]              Indicates the EFI_LEGACY_REGION2_PROTOCOL instance.\r
   @param  DescriptorCount[out]  The number of region descriptor entries returned in the Descriptor\r
                                 buffer.\r
   @param  Descriptor[out]       A pointer to a pointer used to return a buffer where the legacy\r
   @param  DescriptorCount[out]  The number of region descriptor entries returned in the Descriptor\r
                                 buffer.\r
   @param  Descriptor[out]       A pointer to a pointer used to return a buffer where the legacy\r
@@ -207,8 +205,8 @@ LegacyRegion2Unlock (
                                 DescriptorCount number of region descriptors.  This function will\r
                                 provide the memory for the buffer.\r
 \r
                                 DescriptorCount number of region descriptors.  This function will\r
                                 provide the memory for the buffer.\r
 \r
-  @retval EFI_SUCCESS           The region's attributes were successfully modified.\r
-  @retval EFI_INVALID_PARAMETER If Start or Length describe an address not in the Legacy Region.\r
+  @retval EFI_SUCCESS           The information structure was returned.\r
+  @retval EFI_UNSUPPORTED       This function is not supported.\r
 \r
 **/\r
 EFI_STATUS\r
 \r
 **/\r
 EFI_STATUS\r
@@ -219,13 +217,7 @@ LegacyRegionGetInfo (
   OUT EFI_LEGACY_REGION_DESCRIPTOR  **Descriptor\r
   )\r
 {\r
   OUT EFI_LEGACY_REGION_DESCRIPTOR  **Descriptor\r
   )\r
 {\r
-  ASSERT (DescriptorCount != NULL);\r
-  ASSERT (Descriptor != NULL);\r
-\r
-  *DescriptorCount = 0;\r
-  *Descriptor      = NULL;\r
-\r
-  return EFI_SUCCESS;\r
+  return EFI_UNSUPPORTED;\r
 }\r
 \r
 /**\r
 }\r
 \r
 /**\r
index 8c071fc9717877da2965f981825aef2ba8f01219..78667d7f681600b31ceec048bd0541f64f35ee96 100644 (file)
@@ -7,7 +7,11 @@
 #  be used as a template driver for implementing the Legacy Region 2 Protocol on\r
 #  a platform that does support HW locking of the legacy memory regions.\r
 #\r
 #  be used as a template driver for implementing the Legacy Region 2 Protocol on\r
 #  a platform that does support HW locking of the legacy memory regions.\r
 #\r
-# Copyright (c) 2009, Intel Corporation\r
+#  Note: This module does not fully comply with PI Specification of Legacy Region 2\r
+#  Protocol. For Lock/UnLock/Decode, EFI_SUCCESS is returned although the region's\r
+#  attributes were not actually modified.\r
+#\r
+# Copyright (c) 2009 - 2010, Intel Corporation\r
 # All rights reserved. This program and the accompanying materials\r
 # are licensed and made available under the terms and conditions of the BSD License\r
 # which accompanies this distribution.  The full text of the license may be found at\r
 # All rights reserved. This program and the accompanying materials\r
 # are licensed and made available under the terms and conditions of the BSD License\r
 # which accompanies this distribution.  The full text of the license may be found at\r