Changeset 3375 in MondoRescue for branches/3.2/mondo/src
- Timestamp:
- Apr 27, 2015, 4:25:30 PM (10 years ago)
- Location:
- branches/3.2/mondo/src/common
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.2/mondo/src/common/libmondo-devices.c
r3374 r3375 2104 2104 2105 2105 2106 /** 2107 * Return the type of boot of the system (UEFI, EFI or BIOS) 2108 */ 2109 t_boot mr_boot_type() { 2110 2111 t_boot ret = BIOS; 2112 FILE *fd = NULL; 2113 2114 #ifdef __IA64__ 2115 ret = EFI; 2116 #endif 2117 /* Try to detect whether we are in fact in UEFI mode */ 2118 /* TODO: find the right trigger */ 2119 fd = fopen("/sys/module/efi", "r"); 2120 if (fd != NULL) { 2121 ret = UEFI; 2122 } 2123 return(ret); 2124 } 2106 2125 2107 2126 … … 2642 2661 } 2643 2662 bkpinfo->boot_loader = i; 2663 bkpinfo->boot_type = mr_boot_type(); 2664 /* TODO: Chcek consisytency of boot type and boot loader */ 2644 2665 2645 2666 if (bkpinfo->include_paths) { -
branches/3.2/mondo/src/common/libmondo-tools.c
r3373 r3375 830 830 bkpinfo->use_obdr = FALSE; 831 831 bkpinfo->restore_mode = interactive; 832 bkpinfo->boot_type = BIOS; 832 833 } 833 834 -
branches/3.2/mondo/src/common/mondostructures.h
r3373 r3375 181 181 udev ///< Back up to another unsupported device; just send a stream of bytes. 182 182 } t_bkptype; 183 184 /** 185 * A type of boot 186 */ 187 typedef enum { 188 BIOS, /// System uses Legacy Boot mode (aka BIOS) 189 EFI, /// System uses EFI Boot mode 190 UEFI, /// System uses UEFI Boot mode 191 } t_boot; 183 192 184 193 /** … … 639 648 */ 640 649 t_restore_mode restore_mode; 650 651 /** 652 * The type of boot of our ssytem 653 */ 654 t_boot boot_type; 655 641 656 }; 642 657
Note:
See TracChangeset
for help on using the changeset viewer.