]> git.proxmox.com Git - mirror_edk2.git/blobdiff - MdeModulePkg/Core/PiSmmCore/Locate.c
MdeModulePkg: Replace BSD License with BSD+Patent License
[mirror_edk2.git] / MdeModulePkg / Core / PiSmmCore / Locate.c
index 00b2c892e7493e0e30bdcf341ac39b50a0a494e9..85c6873fafe2b5808e06aa681a4a7fa0478de7fd 100644 (file)
@@ -1,14 +1,8 @@
 /** @file\r
   Locate handle functions\r
 \r
-  Copyright (c) 2009 - 2010, Intel Corporation.  All rights reserved.<BR>\r
-  This program and the accompanying materials are licensed and made available \r
-  under the terms and conditions of the BSD License which accompanies this \r
-  distribution.  The full text of the license may be found at        \r
-  http://opensource.org/licenses/bsd-license.php                                            \r
-\r
-  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     \r
-  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             \r
+  Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>\r
+  SPDX-License-Identifier: BSD-2-Clause-Patent\r
 \r
 **/\r
 \r
@@ -205,14 +199,10 @@ SmmLocateProtocol (
   PROTOCOL_NOTIFY         *ProtNotify;\r
   IHANDLE                 *Handle;\r
 \r
-  if (Interface == NULL) {\r
+  if ((Interface == NULL) || (Protocol == NULL)) {\r
     return EFI_INVALID_PARAMETER;\r
   }\r
 \r
-  if (Protocol == NULL) {\r
-    return EFI_NOT_FOUND;\r
-  }\r
-\r
   *Interface = NULL;\r
   Status = EFI_SUCCESS;\r
 \r
@@ -430,7 +420,7 @@ SmmLocateHandle (
   @retval EFI_NOT_FOUND          No handles match the search.\r
   @retval EFI_OUT_OF_RESOURCES   There is not enough pool memory to store the\r
                                  matching results.\r
-  @retval EFI_INVALID_PARAMETER  One or more paramters are not valid.\r
+  @retval EFI_INVALID_PARAMETER  One or more parameters are not valid.\r
 \r
 **/\r
 EFI_STATUS\r