]> git.proxmox.com Git - mirror_edk2.git/commitdiff
MdeModulePkg RamDiskDxe: Uninstall DEVICE_PATH_PROTOCOL with correct param
authorHao Wu <hao.a.wu@intel.com>
Tue, 8 Mar 2016 01:35:14 +0000 (09:35 +0800)
committerHao Wu <hao.a.wu@intel.com>
Wed, 23 Mar 2016 05:38:10 +0000 (13:38 +0800)
Previously, the code uninstalls the DEVICE_PATH_PROTOCOL with the device
path given by caller of the 'RamDiskUnregister' function. The given device
path might be different from the one used to install the
DEVICE_PATH_PROTOCOL.

Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Hao Wu <hao.a.wu@intel.com>
Reviewed-by: Feng Tian <feng.tian@intel.com>
MdeModulePkg/Universal/Disk/RamDiskDxe/RamDiskProtocol.c

index b53709b493cd623d97282080e09ea18952a8eefe..6d97994b5c4e74bb22dfb1d023a63f663314a9f4 100644 (file)
@@ -324,7 +324,7 @@ RamDiskUnregister (
                &gEfiBlockIo2ProtocolGuid,\r
                &PrivateData->BlockIo2,\r
                &gEfiDevicePathProtocolGuid,\r
-               DevicePath,\r
+               (EFI_DEVICE_PATH_PROTOCOL *) PrivateData->DevicePath,\r
                NULL\r
                );\r
 \r