disk: part_mac: Remove the Apple Partition Map driver
PATCH 1/1 disk: part_mac: Remove the Apple Partition Map driver
The Apple Partition Map predates Advanced Format media by two decades. Apple never extended the format to cover 4 Kn logical blocks, has since withdrawn its documentation, and has shipped GPT on its own systems for almost as long. There is therefore no specification left to follow for the one property that matters here: where a partition map entry lives when a block is not 512 bytes.
U-Boot's implementation reflects that. All three entry points read one block into a buffer sized after a 512-byte struct, so they smash the stack on any device with larger blocks, and part_test_mac() runs during partition probing on every block device. Sizing those buffers correctly is easy; deciding what the driver should then parse is not, and guessing at a layout Apple never defined helps nobody.
Nothing in tree depends on the driver either: it has no test, no documentation and no MAINTAINERS entry, and the sole reference to PART_TYPE_MAC is its own partition driver registration.
Drop it. Anyone who needs Apple Partition Map support for emulated hardware can bring it back along with a test.
---
CI passes all green:
https://git.u-boot-project.org/u-boot/contributors/alchark/u-boot/-/pipelines/1094
--- README | 1 - configs/M5253DEMO_defconfig | 1 - configs/bayleybay_defconfig | 1 - configs/chromebook_coral_defconfig | 2 - configs/chromebook_link_defconfig | 1 - configs/chromebook_samus_defconfig | 1 - configs/chromebook_samus_tpl_defconfig | 2 - configs/chromebox_panther_defconfig | 1 - configs/clearfog_gt_8k_defconfig | 1 - ...conga-qeval20-qa3-e3845-internal-uart_defconfig | 1 - configs/conga-qeval20-qa3-e3845_defconfig | 1 - configs/coreboot64-no-spl_defconfig | 1 - configs/coreboot64_defconfig | 2 - configs/coreboot_defconfig | 1 - configs/cougarcanyon2_defconfig | 1 - configs/crownbay_defconfig | 1 - configs/dfi-bt700-q7x-151_defconfig | 1 - configs/eDPU_defconfig | 1 - configs/efi-x86_app32_defconfig | 1 - configs/efi-x86_app64_defconfig | 1 - configs/efi-x86_payload32_defconfig | 1 - configs/efi-x86_payload64_defconfig | 1 - configs/galileo_defconfig | 1 - configs/minnowmax_defconfig | 1 - configs/mvebu_ac5_rd_defconfig | 1 - configs/mvebu_crb_cn9130_defconfig | 1 - configs/mvebu_db-88f3720_defconfig | 1 - configs/mvebu_db_armada8k_defconfig | 1 - configs/mvebu_db_cn9130_defconfig | 1 - configs/mvebu_espressobin-88f3720_defconfig | 1 - configs/mvebu_espressobin_ultra-88f3720_defconfig | 1 - configs/mvebu_mcbin-88f8040_defconfig | 1 - configs/mvebu_puzzle-m801-88f8040_defconfig | 1 - configs/qemu-x86_defconfig | 1 - configs/renesas_rza1.config | 1 - configs/sandbox64_defconfig | 1 - configs/sandbox_defconfig | 1 - configs/sandbox_flattree_defconfig | 1 - configs/sandbox_noinst_defconfig | 1 - configs/sandbox_spl_defconfig | 1 - configs/sandbox_vpl_defconfig | 2 - configs/som-db5800-som-6867_defconfig | 1 - configs/theadorable-x86-conga-qa3-e3845_defconfig | 1 - configs/theadorable-x86-dfi-bt700_defconfig | 1 - configs/turris_mox_defconfig | 1 - configs/uDPU_defconfig | 1 - configs/x250_defconfig | 1 - configs/x960_defconfig | 1 - disk/Kconfig | 14 -- disk/Makefile | 1 - disk/part.c | 3 +- disk/part_mac.c | 237 --------------------- disk/part_mac.h | 81 ------- include/part.h | 2 - 54 files changed, 1 insertion(+), 389 deletions(-)
README +0 -1
@@ -309,7 +309,6 @@ The following options need to be configured: - Partition Labels (disklabels) Supported: Zero or more of the following: - CONFIG_MAC_PARTITION Apple's MacOS partition table. CONFIG_ISO_PARTITION ISO partition table, used on CDROM etc. CONFIG_EFI_PARTITION GPT partition table, common when EFI is the bootloader. Note 2TB partition limit; see
configs/M5253DEMO_defconfig +0 -1
@@ -23,7 +23,6 @@ CONFIG_CMD_PING=y CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_FAT=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE_ETHADDR_ONCE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y CONFIG_USE_HOSTNAME=y
configs/bayleybay_defconfig +0 -1
@@ -44,7 +44,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/chromebook_coral_defconfig +0 -2
@@ -71,8 +71,6 @@ CONFIG_CMD_BOOTSTAGE=y CONFIG_CMD_TPM=y CONFIG_CMD_CBFS=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y -# CONFIG_SPL_MAC_PARTITION is not set # CONFIG_SPL_DOS_PARTITION is not set # CONFIG_SPL_EFI_PARTITION is not set CONFIG_OF_SPL_REMOVE_PROPS="clocks clock-names interrupt-parent interrupts linux-name acpi,name acpi,path u-boot,acpi-dsdt-order u-boot,acpi-ssdt-order"
configs/chromebook_link_defconfig +0 -1
@@ -50,7 +50,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/chromebook_samus_defconfig +0 -1
@@ -49,7 +49,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/chromebook_samus_tpl_defconfig +0 -2
@@ -65,8 +65,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y -# CONFIG_SPL_MAC_PARTITION is not set # CONFIG_SPL_DOS_PARTITION is not set CONFIG_ISO_PARTITION=y # CONFIG_SPL_EFI_PARTITION is not set
configs/chromebox_panther_defconfig +0 -1
@@ -41,7 +41,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/clearfog_gt_8k_defconfig +0 -1
@@ -38,7 +38,6 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/conga-qeval20-qa3-e3845-internal-uart_defconfig +0 -1
@@ -51,7 +51,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/conga-qeval20-qa3-e3845_defconfig +0 -1
@@ -47,7 +47,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/coreboot64-no-spl_defconfig +0 -1
@@ -30,7 +30,6 @@ CONFIG_BOOTP_BOOTFILESIZE=y CONFIG_CMD_TIME=y CONFIG_CMD_SOUND=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y CONFIG_USE_BOOTFILE=y
configs/coreboot64_defconfig +0 -2
@@ -34,8 +34,6 @@ CONFIG_BOOTP_BOOTFILESIZE=y CONFIG_CMD_TIME=y CONFIG_CMD_SOUND=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y -# CONFIG_SPL_MAC_PARTITION is not set # CONFIG_SPL_DOS_PARTITION is not set # CONFIG_SPL_EFI_PARTITION is not set CONFIG_ENV_OVERWRITE=y
configs/coreboot_defconfig +0 -1
@@ -34,7 +34,6 @@ CONFIG_CMD_TIME=y CONFIG_CMD_SOUND=y CONFIG_CMD_BOOTSTAGE=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y CONFIG_USE_BOOTFILE=y
configs/cougarcanyon2_defconfig +0 -1
@@ -37,7 +37,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/crownbay_defconfig +0 -1
@@ -40,7 +40,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/dfi-bt700-q7x-151_defconfig +0 -1
@@ -45,7 +45,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/eDPU_defconfig +0 -1
@@ -40,7 +40,6 @@ CONFIG_CMD_TFTPPUT=y CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/efi-x86_app32_defconfig +0 -1
@@ -28,7 +28,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_EFI_PARTITION=y CONFIG_OF_EMBED=y
configs/efi-x86_app64_defconfig +0 -1
@@ -32,7 +32,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_EFI_PARTITION=y CONFIG_OF_EMBED=y
configs/efi-x86_payload32_defconfig +0 -1
@@ -33,7 +33,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/efi-x86_payload64_defconfig +0 -1
@@ -26,7 +26,6 @@ CONFIG_CMD_USB=y CONFIG_BOOTP_BOOTFILESIZE=y CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_FAT=y CONFIG_ENV_FAT_INTERFACE="scsi"
configs/galileo_defconfig +0 -1
@@ -36,7 +36,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/minnowmax_defconfig +0 -1
@@ -50,7 +50,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/mvebu_ac5_rd_defconfig +0 -1
@@ -36,7 +36,6 @@ CONFIG_CMD_TIME=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_UBI=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_USE_GATEWAYIP=y
configs/mvebu_crb_cn9130_defconfig +0 -1
@@ -38,7 +38,6 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_MVEBU_MMC_BOOT=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_MMC=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/mvebu_db-88f3720_defconfig +0 -1
@@ -35,7 +35,6 @@ CONFIG_CMD_TFTPPUT=y CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/mvebu_db_armada8k_defconfig +0 -1
@@ -35,7 +35,6 @@ CONFIG_CMD_TFTPPUT=y CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/mvebu_db_cn9130_defconfig +0 -1
@@ -39,7 +39,6 @@ CONFIG_CMD_TFTPPUT=y CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/mvebu_espressobin-88f3720_defconfig +0 -1
@@ -43,7 +43,6 @@ CONFIG_CMD_BTRFS=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_SQUASHFS=y CONFIG_CMD_FS_UUID=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/mvebu_espressobin_ultra-88f3720_defconfig +0 -1
@@ -42,7 +42,6 @@ CONFIG_CMD_BTRFS=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_SQUASHFS=y CONFIG_CMD_FS_UUID=y -CONFIG_MAC_PARTITION=y CONFIG_OF_UPSTREAM=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y
configs/mvebu_mcbin-88f8040_defconfig +0 -1
@@ -38,7 +38,6 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/mvebu_puzzle-m801-88f8040_defconfig +0 -1
@@ -43,7 +43,6 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y CONFIG_ARP_TIMEOUT=200
configs/qemu-x86_defconfig +0 -1
@@ -39,7 +39,6 @@ CONFIG_CMD_EFIDEBUG=y CONFIG_CMD_TIME=y CONFIG_CMD_BOOTSTAGE=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_FAT=y CONFIG_ENV_FAT_INTERFACE="virtio"
configs/renesas_rza1.config +0 -1
@@ -29,7 +29,6 @@ CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y CONFIG_HUSH_PARSER=y CONFIG_LED=y CONFIG_LED_GPIO=y -CONFIG_MAC_PARTITION=y CONFIG_NET_RANDOM_ETHADDR=y CONFIG_NR_DRAM_BANKS=1 CONFIG_OF_CONTROL=y
configs/sandbox64_defconfig +0 -1
@@ -102,7 +102,6 @@ CONFIG_CMD_CRAMFS=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_MTDPARTS=y CONFIG_CMD_SPAWN=y -CONFIG_MAC_PARTITION=y CONFIG_AMIGA_PARTITION=y CONFIG_OF_LIVE=y CONFIG_ENV_IS_NOWHERE=y
configs/sandbox_defconfig +0 -1
@@ -153,7 +153,6 @@ CONFIG_CMD_SQUASHFS=y CONFIG_CMD_MTDPARTS=y CONFIG_CMD_STACKPROTECTOR_TEST=y CONFIG_CMD_SPAWN=y -CONFIG_MAC_PARTITION=y CONFIG_OF_LIVE=y CONFIG_DEVICE_TREE_INCLUDES="sandbox_scripts.dtsi" CONFIG_ENV_IS_NOWHERE=y
configs/sandbox_flattree_defconfig +0 -1
@@ -76,7 +76,6 @@ CONFIG_CMD_AES=y CONFIG_CMD_TPM=y CONFIG_CMD_TPM_TEST=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_AMIGA_PARTITION=y CONFIG_ENV_IS_NOWHERE=y CONFIG_ENV_IS_IN_FAT=y
configs/sandbox_noinst_defconfig +0 -1
@@ -112,7 +112,6 @@ CONFIG_CMD_TPM_TEST=y CONFIG_CMD_CBFS=y CONFIG_CMD_CRAMFS=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_AMIGA_PARTITION=y CONFIG_SPL_OF_CONTROL=y CONFIG_SPL_OF_PLATDATA=y
configs/sandbox_spl_defconfig +0 -1
@@ -90,7 +90,6 @@ CONFIG_CMD_TPM_TEST=y CONFIG_CMD_CBFS=y CONFIG_CMD_CRAMFS=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_AMIGA_PARTITION=y CONFIG_SPL_OF_CONTROL=y CONFIG_SPL_OF_PLATDATA=y
configs/sandbox_vpl_defconfig +0 -2
@@ -103,8 +103,6 @@ CONFIG_CMD_TPM_TEST=y CONFIG_CMD_CBFS=y CONFIG_CMD_CRAMFS=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y -# CONFIG_SPL_MAC_PARTITION is not set # CONFIG_SPL_DOS_PARTITION is not set # CONFIG_SPL_EFI_PARTITION is not set CONFIG_SPL_OF_CONTROL=y
configs/som-db5800-som-6867_defconfig +0 -1
@@ -45,7 +45,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/theadorable-x86-conga-qa3-e3845_defconfig +0 -1
@@ -45,7 +45,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_REDUNDANT=y
configs/theadorable-x86-dfi-bt700_defconfig +0 -1
@@ -43,7 +43,6 @@ CONFIG_CMD_EXT4=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_FAT=y CONFIG_CMD_FS_GENERIC=y -CONFIG_MAC_PARTITION=y CONFIG_ISO_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_REDUNDANT=y
configs/turris_mox_defconfig +0 -1
@@ -48,7 +48,6 @@ CONFIG_CMD_AES=y CONFIG_CMD_HASH=y CONFIG_CMD_BTRFS=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_OF_LIST="armada-3720-turris-mox armada-3720-ripe-atlas" CONFIG_ENV_OVERWRITE=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/uDPU_defconfig +0 -1
@@ -39,7 +39,6 @@ CONFIG_CMD_TFTPPUT=y CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/x250_defconfig +0 -1
@@ -41,7 +41,6 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_UBI=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
configs/x960_defconfig +0 -1
@@ -41,7 +41,6 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y CONFIG_CMD_EXT4_WRITE=y CONFIG_CMD_UBI=y -CONFIG_MAC_PARTITION=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_ENV_RELOC_GD_ENV_ADDR=y
disk/Kconfig +0 -14
@@ -6,7 +6,6 @@ config PARTITIONS help Partition Labels (disklabels) Supported: Zero or more of the following: - - CONFIG_MAC_PARTITION Apple's MacOS partition table. - CONFIG_DOS_PARTITION MS Dos partition table, traditional on the Intel architecture, USB sticks, etc. - CONFIG_ISO_PARTITION ISO partition table, used on CDROM etc.
@@ -36,19 +35,6 @@ config TPL_PARTITIONS partition table types shold be enabled separately. This adds a small amount of size to TPL, typically 500 bytes. -config MAC_PARTITION - bool "Enable Apple's MacOS partition table" - select PARTITIONS - help - Say Y here if you would like to use device under U-Boot which - were partitioned on a Macintosh. - -config SPL_MAC_PARTITION - bool "Enable Apple's MacOS partition table for SPL" - depends on SPL - default y if MAC_PARTITION - select SPL_PARTITIONS - config TEGRA_PARTITION bool "Enable Nvidia Tegra partition table" select PARTITIONS
disk/Makefile +0 -1
@@ -12,7 +12,6 @@ endif # Must have BLK or SPL_LEGACY_BLOCK to support partitions ifneq ($(CONFIG_$(PHASE_)BLK),$(CONFIG_SPL_LEGACY_BLOCK),) -obj-$(CONFIG_$(PHASE_)MAC_PARTITION) += part_mac.o obj-$(CONFIG_$(PHASE_)DOS_PARTITION) += part_dos.o obj-$(CONFIG_$(PHASE_)ISO_PARTITION) += part_iso.o obj-$(CONFIG_$(PHASE_)AMIGA_PARTITION) += part_amiga.o
disk/part.c +1 -2
@@ -312,8 +312,7 @@ void part_init(struct blk_desc *desc)static void print_part_header (const char *type,struct blk_desc *desc) { -#if CONFIG_IS_ENABLED(MAC_PARTITION) || \ - CONFIG_IS_ENABLED(DOS_PARTITION) || \ +#if CONFIG_IS_ENABLED(DOS_PARTITION) || \ CONFIG_IS_ENABLED(ISO_PARTITION) || \ CONFIG_IS_ENABLED(AMIGA_PARTITION) || \ CONFIG_IS_ENABLED(EFI_PARTITION) || \
disk/part_mac.c deleted +0 -237
237 lines not on this page · raw message
disk/part_mac.h deleted +0 -81
81 lines not on this page · raw message
include/part.h +0 -2
@@ -23,7 +23,6 @@ struct block_drvr {/* Part types */ #define PART_TYPE_UNKNOWN 0x00 -#define PART_TYPE_MAC 0x01#define PART_TYPE_DOS 0x02#define PART_TYPE_ISO 0x03#define PART_TYPE_AMIGA 0x04
@@ -34,7 +33,6 @@ struct block_drvr {/* maximum number of partition entries supported by search */ #define DOS_ENTRY_NUMBERS 8#define ISO_ENTRY_NUMBERS 64 -#define MAC_ENTRY_NUMBERS 64#define AMIGA_ENTRY_NUMBERS 8#define MTD_ENTRY_NUMBERS 64#define UBI_ENTRY_NUMBERS UBI_MAX_VOLUMES
---
base-commit: f252d228be2b2d180737ad0a851f91749273cbd9
change-id: 20260826-drop-part-mac-66df760b1d97
Best regards,
Signature · 1 line
Alexey Charkov <[email protected]>
Quoted 18 lines · Alexey Charkov
The Apple Partition Map predates Advanced Format media by two decades. Apple never extended the format to cover 4 Kn logical blocks, has since withdrawn its documentation, and has shipped GPT on its own systems for almost as long. There is therefore no specification left to follow for the one property that matters here: where a partition map entry lives when a block is not 512 bytes.
U-Boot's implementation reflects that. All three entry points read one block into a buffer sized after a 512-byte struct, so they smash the stack on any device with larger blocks, and
part_test_mac()runs during partition probing on every block device. Sizing those buffers correctly is easy; deciding what the driver should then parse is not, and guessing at a layout Apple never defined helps nobody.Nothing in tree depends on the driver either: it has no test, no documentation and no
MAINTAINERSentry, and the sole reference toPART_TYPE_MACis its own partition driver registration.
Quoted 7 lines
Drop it. Anyone who needs Apple Partition Map support for emulated hardware can bring it back along with a test.
Thank you. LGTM.
Quoted 18 lines · Alexey Charkov
The Apple Partition Map predates Advanced Format media by two decades. Apple never extended the format to cover 4 Kn logical blocks, has since withdrawn its documentation, and has shipped GPT on its own systems for almost as long. There is therefore no specification left to follow for the one property that matters here: where a partition map entry lives when a block is not 512 bytes.
U-Boot's implementation reflects that. All three entry points read one block into a buffer sized after a 512-byte struct, so they smash the stack on any device with larger blocks, and
part_test_mac()runs during partition probing on every block device. Sizing those buffers correctly is easy; deciding what the driver should then parse is not, and guessing at a layout Apple never defined helps nobody.Nothing in tree depends on the driver either: it has no test, no documentation and no
MAINTAINERSentry, and the sole reference toPART_TYPE_MACis its own partition driver registration.
Quoted 7 lines
Drop it. Anyone who needs Apple Partition Map support for emulated hardware can bring it back along with a test.
Signature · 1 line
Tom
Quoted 8 lines · Alexey Charkov
The Apple Partition Map predates Advanced Format media by two decades. Apple never extended the format to cover 4 Kn logical blocks, has since withdrawn its documentation, and has shipped GPT on its own systems for almost as long. There is therefore no specification left to follow for the one property that matters here: where a partition map entry lives when a block is not 512 bytes.
[...]
Applied to u-boot/next, thanks!
[1/1] disk: part_mac: Remove the Apple Partition Map driver
commit: acb09f16da3322098e54dcc75fe6458ed2d5bc23
Signature · 1 line
Tom