diff --git a/include/sys/efi_partition.h b/include/sys/efi_partition.h index 88bdfd2b1ca3..fbb58013e22a 100644 --- a/include/sys/efi_partition.h +++ b/include/sys/efi_partition.h @@ -370,7 +370,6 @@ extern int efi_rescan(int); extern void efi_free(struct dk_gpt *); extern int efi_type(int); extern void efi_err_check(struct dk_gpt *); -extern int efi_auto_sense(int fd, struct dk_gpt **); extern int efi_use_whole_disk(int fd); #endif diff --git a/lib/libefi/rdwr_efi.c b/lib/libefi/rdwr_efi.c index 1e022cc8eeaa..39b3509a5c4b 100644 --- a/lib/libefi/rdwr_efi.c +++ b/lib/libefi/rdwr_efi.c @@ -1692,57 +1692,3 @@ efi_err_check(struct dk_gpt *vtoc) "no reserved partition found\n"); } } - -/* - * We need to get information necessary to construct a *new* efi - * label type - */ -int -efi_auto_sense(int fd, struct dk_gpt **vtoc) -{ - - int i; - - /* - * Now build the default partition table - */ - if (efi_alloc_and_init(fd, EFI_NUMPAR, vtoc) != 0) { - if (efi_debug) { - (void) fprintf(stderr, "efi_alloc_and_init failed.\n"); - } - return (-1); - } - - for (i = 0; i < MIN((*vtoc)->efi_nparts, V_NUMPAR); i++) { - (*vtoc)->efi_parts[i].p_tag = default_vtoc_map[i].p_tag; - (*vtoc)->efi_parts[i].p_flag = default_vtoc_map[i].p_flag; - (*vtoc)->efi_parts[i].p_start = 0; - (*vtoc)->efi_parts[i].p_size = 0; - } - /* - * Make constants first - * and variable partitions later - */ - - /* root partition - s0 128 MB */ - (*vtoc)->efi_parts[0].p_start = 34; - (*vtoc)->efi_parts[0].p_size = 262144; - - /* partition - s1 128 MB */ - (*vtoc)->efi_parts[1].p_start = 262178; - (*vtoc)->efi_parts[1].p_size = 262144; - - /* partition -s2 is NOT the Backup disk */ - (*vtoc)->efi_parts[2].p_tag = V_UNASSIGNED; - - /* partition -s6 /usr partition - HOG */ - (*vtoc)->efi_parts[6].p_start = 524322; - (*vtoc)->efi_parts[6].p_size = (*vtoc)->efi_last_u_lba - 524322 - - (1024 * 16); - - /* efi reserved partition - s9 16K */ - (*vtoc)->efi_parts[8].p_start = (*vtoc)->efi_last_u_lba - (1024 * 16); - (*vtoc)->efi_parts[8].p_size = (1024 * 16); - (*vtoc)->efi_parts[8].p_tag = V_RESERVED; - return (0); -} diff --git a/lib/libzfs_core/libzfs_core.abi b/lib/libzfs_core/libzfs_core.abi index 8d7af37b7a0f..3d5bc55a4633 100644 --- a/lib/libzfs_core/libzfs_core.abi +++ b/lib/libzfs_core/libzfs_core.abi @@ -152,7 +152,6 @@ - @@ -374,48 +373,37 @@ - - - + + + - - + + - - + + - - - + + + - - + + - - + + - - - - - - - - - - - - - + + @@ -440,9 +428,9 @@ + + - - @@ -450,211 +438,207 @@ - - - + + + - + - + - + - + - + - + - - - + + + - - - + + + - + - + - + - + - + - + - + - + - + - + - + - + - - + + - - + + - + - + - + - - - - + + + + + + - - - - + + - - - - + + + + - - - - + + + + - - + + - + - - - - - - + + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + @@ -663,19 +647,19 @@ - - - - + + + + - - - + + + - + - + @@ -691,21 +675,21 @@ - + - - - + + + - - + + - - + + @@ -717,13 +701,13 @@ - + - + @@ -760,7 +744,7 @@ - + @@ -773,23 +757,23 @@ - + - + - - - + + + - + @@ -803,7 +787,7 @@ - + @@ -1046,7 +1030,7 @@ - + @@ -1098,18 +1082,18 @@ - + - + - + @@ -1204,7 +1188,7 @@ - + @@ -1228,17 +1212,17 @@ - - + + - + - + - + @@ -2092,7 +2076,7 @@ - + @@ -2151,13 +2135,13 @@ - - + + - - - + + + @@ -2167,7 +2151,7 @@ - + @@ -2184,21 +2168,21 @@ + - - + - + @@ -2209,7 +2193,7 @@ - + @@ -2221,16 +2205,16 @@ - + + - + - @@ -2239,81 +2223,81 @@ - + - + - + - + - - + + - + - + - + - + - + - + - + - - + + - - + + - + + + - - - + @@ -2322,32 +2306,32 @@ - + - + - - + + - - + + - - + + - + @@ -2363,17 +2347,17 @@ - - + + - + - + @@ -2390,28 +2374,28 @@ - + - - + + - - + + - + - - + + @@ -2419,56 +2403,56 @@ - - + + - + - - + + - + - - + + - + - + - + - + - + - + @@ -2477,9 +2461,9 @@ - + - + @@ -2493,12 +2477,12 @@ - + - - + + @@ -2512,14 +2496,14 @@ - - + + - - + + @@ -2528,13 +2512,13 @@ - + - + @@ -2544,8 +2528,8 @@ - - + + @@ -2553,16 +2537,16 @@ - + - + - - + + @@ -2570,38 +2554,38 @@ - + - + - + - + - + - + - + - + @@ -2610,37 +2594,37 @@ - - + + - + - + - + - + - + @@ -2656,7 +2640,7 @@ - + @@ -2664,23 +2648,23 @@ - - + + - + - + - + - + - - - + + + @@ -2689,12 +2673,12 @@ - - + + - + @@ -2703,10 +2687,10 @@ - + - + @@ -2737,16 +2721,16 @@ - + - + - + - + @@ -2761,10 +2745,10 @@ - + - + @@ -2844,52 +2828,62 @@ - - + + - - + + + + + + + + + + + + - - - + + + - - - - + + + + - - + + - - + + - - - + + + - - + + - - + + - - - + + + - - + + @@ -2919,7 +2913,7 @@ - + @@ -2928,12 +2922,12 @@ - + - + @@ -2941,8 +2935,8 @@ - - + + @@ -2968,12 +2962,12 @@ - + - - + + @@ -2984,19 +2978,19 @@ - + - - - + + + - + @@ -3015,87 +3009,87 @@ - - + + - - + + - + - - + + - + + - + + - - - + - - - + + + - - + + + - - + - + - - + + - - + + - - - + + + - - + + - + @@ -3107,19 +3101,19 @@ - + - + - + - + - + @@ -3175,7 +3169,7 @@ - + @@ -3215,13 +3209,13 @@ - + - + @@ -3253,13 +3247,13 @@ - + - + @@ -3331,7 +3325,7 @@ - + @@ -3378,7 +3372,7 @@ - + @@ -3419,7 +3413,7 @@ - + @@ -3435,37 +3429,37 @@ - + - + - + - + - + - + - + - + - + - + - + @@ -3510,7 +3504,7 @@ - + @@ -3530,20 +3524,20 @@ - - + + - + - + @@ -3563,7 +3557,7 @@ - + @@ -3581,8 +3575,8 @@ - - + + @@ -3618,7 +3612,7 @@ - + @@ -3630,58 +3624,58 @@ - + - - + + - + - + - + - + - + - + - + - + - + @@ -3697,7 +3691,7 @@ - + @@ -3705,9 +3699,9 @@ - - - + + + @@ -3726,17 +3720,17 @@ - + - + - - + + @@ -3764,7 +3758,7 @@ - + @@ -3794,7 +3788,7 @@ - + @@ -3806,18 +3800,18 @@ - - + + - - + + - - + + - + @@ -3829,39 +3823,39 @@ - - + + + - - - + + - + - + - - + + - - + + @@ -3869,24 +3863,24 @@ - - - + + + - - - + + + - - - + + + - + @@ -3902,9 +3896,9 @@ - + - + @@ -3915,7 +3909,7 @@ - + @@ -3951,39 +3945,39 @@ - - + + - - - - - - - - - - - + + + + + - - - - + + + + - + - - + + - + - - + + + + + + + + @@ -4046,7 +4040,7 @@ - + @@ -4054,13 +4048,13 @@ - + - +