ide: make 'extra' field in struct ide_port_info u8
PATCH 10/18 ide: make 'extra' field in struct ide_port_info u8
The maximum value used currently for 'extra' field in struct ide_port_info is 240.
Make 'extra' u8 so it packs nicely together with enablebits[] and 'chipset' fields (ide_pci_enablebit_t is 3 bytes and hwif_chipset_t is 1 byte).
Signed-off-by Bartlomiej Zolnierkiewicz <[email protected]>
--- include/linux/ide.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/ide.h +1 -1
@@ -1111,7 +1111,7 @@ struct ide_port_info {void (*fixup)(ide_hwif_t *);ide_pci_enablebit_t enablebits[2 ];hwif_chipset_t chipset; -unsigned int extra; +u8 extra;u32 host_flags;u8 pio_mask;u8 swdma_mask;
Quoted 2 lines · Bartlomiej Zolnierkiewicz
The maximum value used currently for 'extra' field in struct
ide_port_infois 240.
It just can't exceed 240 (256 - 16).
Quoted 4 lines
Make 'extra' u8 so it packs nicely together with enablebits[] and 'chipset' fields (
ide_pci_enablebit_tis 3 bytes andhwif_chipset_tis 1 byte).Signed-off-by Bartlomiej Zolnierkiewicz <[email protected]>
Acked-by Sergei Shtylyov <[email protected]>
MBR, Sergei