]> glassweightruler.freedombox.rocks Git - Ventoy.git/blobdiff - EDK2/edk2_mod/edk2-edk2-stable201911/MdeModulePkg/Application/Ventoy/Ventoy.h
Fix Windows boot issue when Ventoy is booted from rEFInd
[Ventoy.git] / EDK2 / edk2_mod / edk2-edk2-stable201911 / MdeModulePkg / Application / Ventoy / Ventoy.h
index 1e79467e2af20bfbf190c05091263021bcced629..947b8dc52adf97fd597bbaa7f045907e51daabf5 100644 (file)
@@ -344,6 +344,14 @@ typedef struct ventoy_system_wrapper
     EFI_LOCATE_DEVICE_PATH OriLocateDevicePath;
 } ventoy_system_wrapper;
 
+
+#define MAX_DRIVER_BIND_WRAPPER  64
+typedef struct DriverBindWrapper
+{
+    EFI_DRIVER_BINDING_PROTOCOL *DriverBinding;
+    EFI_DRIVER_BINDING_SUPPORTED pfOldSupport;
+}DRIVER_BIND_WRAPPER;
+
 #define ventoy_wrapper(bs, wrapper, func, newfunc) \
 {\
     wrapper.Ori##func = bs->func;\
@@ -351,6 +359,22 @@ typedef struct ventoy_system_wrapper
     bs->func = wrapper.New##func;\
 }
 
+
+#define VENTOY_GET_COMPONENT_NAME(Protocol, DriverName) \
+{\
+    DriverName = NULL;\
+    Status = Protocol->GetDriverName(Protocol, "en", &DriverName);\
+    if (EFI_ERROR(Status) || NULL == DriverName) \
+    {\
+        DriverName = NULL;\
+        Status = Protocol->GetDriverName(Protocol, "eng", &DriverName);\
+        if (EFI_ERROR(Status) || NULL == DriverName) \
+        {\
+            continue;\
+        }\
+    }\
+}
+
 extern BOOLEAN gDebugPrint;
 VOID EFIAPI VtoyDebug(IN CONST CHAR8  *Format, ...);
 EFI_STATUS EFIAPI ventoy_wrapper_system(VOID);
@@ -396,6 +420,8 @@ EFI_STATUS ventoy_hook_keyboard_stop(VOID);
 BOOLEAN ventoy_is_cdrom_dp_exist(VOID);
 EFI_STATUS ventoy_hook_1st_cdrom_start(VOID);
 EFI_STATUS ventoy_hook_1st_cdrom_stop(VOID);
+EFI_STATUS ventoy_disable_ex_filesystem(VOID);
+EFI_STATUS ventoy_enable_ex_filesystem(VOID);
 
 #endif