summaryrefslogtreecommitdiff
path: root/ShellPkg/Library/UefiShellDebug1CommandsLib
diff options
context:
space:
mode:
authorRuiyu Ni <ruiyu.ni@intel.com>2013-07-26 03:14:08 +0000
committerniruiyu <niruiyu@6f19259b-4bc3-4df7-8a09-765794883524>2013-07-26 03:14:08 +0000
commit863986b3c8e67736d361b68e293d01e6f92f825c (patch)
tree15cf067d949655c9defeeeaa78eeea6050845b64 /ShellPkg/Library/UefiShellDebug1CommandsLib
parent4d0a30a494599226450bf69ad9d6fc689f61712e (diff)
downloadedk2-platforms-863986b3c8e67736d361b68e293d01e6f92f825c.tar.xz
Update all the code to consume the ConvertDevicePathToText, ConvertDevicePathNodeToText, ConvertTextToDevicePath and ConvertTextToDeviceNode APIs in DevicePathLib.
Signed-off-by: Ruiyu Ni <ruiyu.ni@intel.com> Reviewed-by: Feng Tian <feng.tian@intel.com> Reviewed-by: Elvin Li <elvin.li@intel.com> Reviewed-by: Eric Dong <eric.dong@intel.com> Reviewed-by: Star Zeng <star.zeng@intel.com> Reviewed-by: Jaben Carsey <jaben.carsey@intel.com> Reviewed-by: Guo Dong <guo.dong@intel.com> git-svn-id: https://svn.code.sf.net/p/edk2/code/trunk/edk2@14505 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'ShellPkg/Library/UefiShellDebug1CommandsLib')
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c4
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/SetVar.c7
-rw-r--r--ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.h4
3 files changed, 5 insertions, 10 deletions
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c
index c26fad7b38..87f2383fad 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/Bcfg.c
@@ -1,7 +1,7 @@
/** @file
Main file for bcfg shell Debug1 function.
- Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2010 - 2013, Intel Corporation. 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
@@ -1052,7 +1052,7 @@ BcfgDisplayDumpDebug1(
if ((*(UINT16*)(Buffer+4)) != 0) {
DevPath = AllocateZeroPool(*(UINT16*)(Buffer+4));
CopyMem(DevPath, Buffer+6+StrSize((CHAR16*)(Buffer+6)), *(UINT16*)(Buffer+4));
- DevPathString = gDevPathToText->ConvertDevicePathToText(DevPath, TRUE, FALSE);
+ DevPathString = ConvertDevicePathToText(DevPath, TRUE, FALSE);
} else {
DevPath = NULL;
DevPathString = NULL;
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/SetVar.c b/ShellPkg/Library/UefiShellDebug1CommandsLib/SetVar.c
index 34eb6af8ac..8d26c9d93b 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/SetVar.c
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/SetVar.c
@@ -1,7 +1,7 @@
/** @file
Main file for SetVar shell Debug1 function.
- Copyright (c) 2010 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2010 - 2013, Intel Corporation. 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
@@ -49,7 +49,6 @@ ShellCommandRunSetVar (
UINTN Size;
UINTN LoopVar;
EFI_DEVICE_PATH_PROTOCOL *DevPath;
- EFI_DEVICE_PATH_FROM_TEXT_PROTOCOL *DevPathFromText;
ShellStatus = SHELL_SUCCESS;
Status = EFI_SUCCESS;
@@ -226,9 +225,7 @@ ShellCommandRunSetVar (
//
Data++;
Data++;
- Status = gBS->LocateProtocol(&gEfiDevicePathFromTextProtocolGuid, NULL, (VOID**)&DevPathFromText);
- ASSERT_EFI_ERROR(Status);
- DevPath = DevPathFromText->ConvertTextToDevicePath(Data);
+ DevPath = ConvertTextToDevicePath(Data);
if (DevPath == NULL) {
ShellPrintHiiEx(-1, -1, NULL, STRING_TOKEN (STR_SETVAR_ERROR_DPFT), gShellDebug1HiiHandle, Status);
ShellStatus = SHELL_INVALID_PARAMETER;
diff --git a/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.h b/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.h
index bbc539126b..d8755bfefc 100644
--- a/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.h
+++ b/ShellPkg/Library/UefiShellDebug1CommandsLib/UefiShellDebug1CommandsLib.h
@@ -1,7 +1,7 @@
/** @file
Main file for NULL named library for Profile1 shell command functions.
- Copyright (c) 2010 - 2011, Intel Corporation. All rights reserved.<BR>
+ Copyright (c) 2010 - 2013, Intel Corporation. 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
@@ -29,7 +29,6 @@
#include <Protocol/DevicePath.h>
#include <Protocol/LoadedImage.h>
#include <Protocol/UnicodeCollation.h>
-#include <Protocol/DevicePathToText.h>
#include <Protocol/DriverDiagnostics2.h>
#include <Protocol/DriverDiagnostics.h>
#include <Protocol/PlatformDriverOverride.h>
@@ -38,7 +37,6 @@
#include <Protocol/DriverSupportedEfiVersion.h>
#include <Protocol/DriverFamilyOverride.h>
#include <Protocol/DriverHealth.h>
-#include <Protocol/DevicePathFromText.h>
#include <Protocol/SimplePointer.h>
#include <Protocol/PciRootBridgeIo.h>