From b0dd81086156edd2bdf966813660b7224e66b407 Mon Sep 17 00:00:00 2001 From: klu2 Date: Mon, 1 Dec 2008 05:55:58 +0000 Subject: Code scrub for GenericBdsLib library instance. git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@6786 6f19259b-4bc3-4df7-8a09-765794883524 --- MdeModulePkg/Library/GenericBdsLib/DevicePath.c | 42 ------------------------- 1 file changed, 42 deletions(-) (limited to 'MdeModulePkg/Library/GenericBdsLib/DevicePath.c') diff --git a/MdeModulePkg/Library/GenericBdsLib/DevicePath.c b/MdeModulePkg/Library/GenericBdsLib/DevicePath.c index 421bba0..478dfd8 100644 --- a/MdeModulePkg/Library/GenericBdsLib/DevicePath.c +++ b/MdeModulePkg/Library/GenericBdsLib/DevicePath.c @@ -1492,45 +1492,3 @@ Done: Str.str[Str.len] = 0; return Str.str; } - -/** - Function creates a device path data structure that identically matches the - device path passed in. - - @param DevPath A pointer to a device path data structure. - - @return The new copy of DevPath is created to identically match the input. - @return Otherwise, NULL is returned. - -**/ -EFI_DEVICE_PATH_PROTOCOL * -LibDuplicateDevicePathInstance ( - IN EFI_DEVICE_PATH_PROTOCOL *DevPath - ) -{ - EFI_DEVICE_PATH_PROTOCOL *NewDevPath; - EFI_DEVICE_PATH_PROTOCOL *DevicePathInst; - EFI_DEVICE_PATH_PROTOCOL *Temp; - UINTN Size; - - // - // get the size of an instance from the input - // - Temp = DevPath; - DevicePathInst = GetNextDevicePathInstance (&Temp, &Size); - - // - // Make a copy - // - NewDevPath = NULL; - if (Size != 0) { - NewDevPath = AllocateZeroPool (Size); - ASSERT (NewDevPath != NULL); - } - - if (NewDevPath != NULL) { - CopyMem (NewDevPath, DevicePathInst, Size); - } - - return NewDevPath; -} -- cgit v1.1