diff --git a/src/disk/hdc_esdi_at.c b/src/disk/hdc_esdi_at.c index fb9ef7479..7ac6b42d2 100644 --- a/src/disk/hdc_esdi_at.c +++ b/src/disk/hdc_esdi_at.c @@ -843,7 +843,6 @@ wd1007vse1_available(void) return(rom_present(BIOS_FILE)); } - const device_t esdi_at_wd1007vse1_device = { .name = "Western Digital WD1007V-SE1 (ESDI)", .internal_name = "esdi_at", diff --git a/src/disk/hdc_esdi_mca.c b/src/disk/hdc_esdi_mca.c index d3c2b9e88..3c29a9265 100644 --- a/src/disk/hdc_esdi_mca.c +++ b/src/disk/hdc_esdi_mca.c @@ -1178,7 +1178,6 @@ esdi_available(void) return(rom_present(BIOS_FILE_L) && rom_present(BIOS_FILE_H)); } - const device_t esdi_ps2_device = { .name = "IBM PS/2 ESDI Fixed Disk Adapter (MCA)", .internal_name = "esdi_mca", diff --git a/src/disk/hdc_ide.c b/src/disk/hdc_ide.c index d0ca2c84e..eaa61e94f 100644 --- a/src/disk/hdc_ide.c +++ b/src/disk/hdc_ide.c @@ -3062,7 +3062,6 @@ ide_close(void *priv) } } - const device_t ide_isa_device = { .name = "ISA PC/AT IDE Controller", .internal_name = "ide_isa", @@ -3150,42 +3149,54 @@ const device_t ide_pci_2ch_device = { // clang-format off static const device_config_t ide_ter_config[] = { { - "irq", "IRQ", CONFIG_SELECTION, "", 10, "", { 0 }, - { - { "Plug and Play", -1 }, - { "IRQ 2", 2 }, - { "IRQ 3", 3 }, - { "IRQ 4", 4 }, - { "IRQ 5", 5 }, - { "IRQ 7", 7 }, - { "IRQ 9", 9 }, - { "IRQ 10", 10 }, - { "IRQ 11", 11 }, - { "IRQ 12", 12 }, - { "" } + .name = "irq", + .description = "IRQ", + .type = CONFIG_SELECTION, + .default_string = "", + .default_int = 10, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "Plug and Play", .value = -1 }, + { .description = "IRQ 2", .value = 2 }, + { .description = "IRQ 3", .value = 3 }, + { .description = "IRQ 4", .value = 4 }, + { .description = "IRQ 5", .value = 5 }, + { .description = "IRQ 7", .value = 7 }, + { .description = "IRQ 9", .value = 9 }, + { .description = "IRQ 10", .value = 10 }, + { .description = "IRQ 11", .value = 11 }, + { .description = "IRQ 12", .value = 12 }, + { .description = "" } } }, - { "", "", -1 } + { .name = "", .description = "", .type = CONFIG_END } }; static const device_config_t ide_qua_config[] = { { - "irq", "IRQ", CONFIG_SELECTION, "", 11, "", { 0 }, - { - { "Plug and Play", -1 }, - { "IRQ 2", 2 }, - { "IRQ 3", 3 }, - { "IRQ 4", 4 }, - { "IRQ 5", 5 }, - { "IRQ 7", 7 }, - { "IRQ 9", 9 }, - { "IRQ 10", 10 }, - { "IRQ 11", 11 }, - { "IRQ 12", 12 }, - { "" } + .name = "irq", + .description = "IRQ", + .type = CONFIG_SELECTION, + .default_string = "", + .default_int = 11, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "Plug and Play", .value = -1 }, + { .description = "IRQ 2", .value = 2 }, + { .description = "IRQ 3", .value = 3 }, + { .description = "IRQ 4", .value = 4 }, + { .description = "IRQ 5", .value = 5 }, + { .description = "IRQ 7", .value = 7 }, + { .description = "IRQ 9", .value = 9 }, + { .description = "IRQ 10", .value = 10 }, + { .description = "IRQ 11", .value = 11 }, + { .description = "IRQ 12", .value = 12 }, + { .description = "" } } }, - { "", "", -1 } + { .name = "", .description = "", .type = CONFIG_END } }; // clang-format on diff --git a/src/disk/hdc_ide_cmd640.c b/src/disk/hdc_ide_cmd640.c index dec8fac18..79c6e4f97 100644 --- a/src/disk/hdc_ide_cmd640.c +++ b/src/disk/hdc_ide_cmd640.c @@ -491,7 +491,6 @@ cmd640_init(const device_t *info) return dev; } - const device_t ide_cmd640_vlb_device = { .name = "CMD PCI-0640B VLB", .internal_name = "ide_cmd640_vlb", diff --git a/src/disk/hdc_ide_cmd646.c b/src/disk/hdc_ide_cmd646.c index 960a07b16..da721f3b6 100644 --- a/src/disk/hdc_ide_cmd646.c +++ b/src/disk/hdc_ide_cmd646.c @@ -406,7 +406,6 @@ cmd646_init(const device_t *info) return dev; } - const device_t ide_cmd646_device = { .name = "CMD PCI-0646", .internal_name = "ide_cmd646", diff --git a/src/disk/hdc_ide_opti611.c b/src/disk/hdc_ide_opti611.c index e53971768..2cbf8e1a2 100644 --- a/src/disk/hdc_ide_opti611.c +++ b/src/disk/hdc_ide_opti611.c @@ -311,7 +311,6 @@ opti611_init(const device_t *info) return dev; } - const device_t ide_opti611_vlb_device = { .name = "OPTi 82C611/82C611A VLB", .internal_name = "ide_opti611_vlb", diff --git a/src/disk/hdc_ide_sff8038i.c b/src/disk/hdc_ide_sff8038i.c index 7caecc37d..f15cc6dcb 100644 --- a/src/disk/hdc_ide_sff8038i.c +++ b/src/disk/hdc_ide_sff8038i.c @@ -584,7 +584,6 @@ static void return dev; } - const device_t sff8038i_device = { .name = "SFF-8038i IDE Bus Master", diff --git a/src/disk/hdc_st506_at.c b/src/disk/hdc_st506_at.c index c510f5319..066c30c15 100644 --- a/src/disk/hdc_st506_at.c +++ b/src/disk/hdc_st506_at.c @@ -767,7 +767,6 @@ mfm_close(void *priv) ui_sb_update_icon(SB_HDD|HDD_BUS_MFM, 0); } - const device_t st506_at_wd1003_device = { .name = "WD1003 AT MFM/RLL Controller", .internal_name = "st506_at", diff --git a/src/disk/hdc_st506_xt.c b/src/disk/hdc_st506_xt.c index 4a4bb3395..9f582398b 100644 --- a/src/disk/hdc_st506_xt.c +++ b/src/disk/hdc_st506_xt.c @@ -1638,122 +1638,194 @@ wd1004a_27x_available(void) // clang-format off static const device_config_t dtc_config[] = { { - "bios_addr", "BIOS address", CONFIG_HEX20, "", 0xc8000, "", { 0 }, - { - { "Disabled", 0x00000 }, - { "C800H", 0xc8000 }, - { "CA00H", 0xca000 }, - { "D800H", 0xd8000 }, - { "F400H", 0xf4000 }, - { "" } + .name = "bios_addr", + .description = "BIOS address", + .type = CONFIG_HEX20, + .default_string = "", + .default_int = 0xc8000, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "Disabled", .value = 0x00000 }, + { .description = "C800H", .value = 0xc8000 }, + { .description = "CA00H", .value = 0xca000 }, + { .description = "D800H", .value = 0xd8000 }, + { .description = "F400H", .value = 0xf4000 }, + { .description = "" } } }, - { "", "", -1 } + { .name = "", .description = "", .type = CONFIG_END } }; static const device_config_t st11_config[] = { { - "base", "Address", CONFIG_HEX16, "", 0x0320, "", { 0 }, - { - { "320H", 0x0320 }, - { "324H", 0x0324 }, - { "328H", 0x0328 }, - { "32CH", 0x032c }, - { "" } + .name = "base", + .description = "Address", + .type = CONFIG_HEX16, + .default_string = "", + .default_int = 0x0320, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "320H", .value = 0x0320 }, + { .description = "324H", .value = 0x0324 }, + { .description = "328H", .value = 0x0328 }, + { .description = "32CH", .value = 0x032c }, + { .description = "" } } }, { - "irq", "IRQ", CONFIG_SELECTION, "", 5, "", { 0 }, - { - { "IRQ 2", 2 }, - { "IRQ 5", 5 }, - { "" } + .name = "irq", + .description = "IRQ", + .type = CONFIG_SELECTION, + .default_string = "", + .default_int = 5, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "IRQ 2", .value = 2 }, + { .description = "IRQ 5", .value = 5 }, + { .description = "" } } }, { - "bios_addr", "BIOS address", CONFIG_HEX20, "", 0xc8000, "", { 0 }, - { - { "Disabled", 0x00000 }, - { "C800H", 0xc8000 }, - { "D000H", 0xd0000 }, - { "D800H", 0xd8000 }, - { "E000H", 0xe0000 }, - { "" } + .name = "bios_addr", + .description = "BIOS address", + .type = CONFIG_HEX20, + .default_string = "", + .default_int = 0xc8000, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "Disabled", .value = 0x00000 }, + { .description = "C800H", .value = 0xc8000 }, + { .description = "D000H", .value = 0xd0000 }, + { .description = "D800H", .value = 0xd8000 }, + { .description = "E000H", .value = 0xe0000 }, + { .description = "" } } }, { - "revision", "Board Revision", CONFIG_SELECTION, "", 19, "", { 0 }, - { - { "Rev. 05 (v1.7)", 5 }, - { "Rev. 19 (v2.0)", 19 }, - { "" } + .name = "revision", + .description = "Board Revision", + .type = CONFIG_SELECTION, + .default_string = "", + .default_int = 19, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "Rev. 05 (v1.7)", .value = 5 }, + { .description = "Rev. 19 (v2.0)", .value = 19 }, + { .description = "" } } }, - { "", "", -1 } + { .name = "", .description = "", .type = CONFIG_END } }; static const device_config_t wd_config[] = { { - "bios_addr", "BIOS address", CONFIG_HEX20, "", 0xc8000, "", { 0 }, - { - { "Disabled", 0x00000 }, - { "C800H", 0xc8000 }, - { "" } + .name = "bios_addr", + .description = "BIOS address", + .type = CONFIG_HEX20, + .default_string = "", + .default_int = 0xc8000, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "Disabled", .value = 0x00000 }, + { .description = "C800H", .value = 0xc8000 }, + { .description = "" } } }, { - "base", "Address", CONFIG_HEX16, "", 0x0320, "", { 0 }, - { - { "320H", 0x0320 }, - { "324H", 0x0324 }, - { "" } + .name = "base", + .description = "Address", + .type = CONFIG_HEX16, + .default_string = "", + .default_int = 0x0320, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "320H", .value = 0x0320 }, + { .description = "324H", .value = 0x0324 }, + { .description = "" } } }, { - "irq", "IRQ", CONFIG_SELECTION, "", 5, "", { 0 }, - { - { "IRQ 2", 2 }, - { "IRQ 5", 5 }, - { "" } + .name = "irq", + .description = "IRQ", + .type = CONFIG_SELECTION, + .default_string = "", + .default_int = 5, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "IRQ 2", .value = 2 }, + { .description = "IRQ 5", .value = 5 }, + { .description = "" } } }, - { "", "", -1 } + { .name = "", .description = "", .type = CONFIG_END } }; static const device_config_t wd_rll_config[] = { { - "bios_addr", "BIOS address", CONFIG_HEX20, "", 0xc8000, "", { 0 }, - { - { "Disabled", 0x00000 }, - { "C800H", 0xc8000 }, - { "" } + .name = "bios_addr", + .description = "BIOS address", + .type = CONFIG_HEX20, + .default_string = "", + .default_int = 0xc8000, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "Disabled", .value = 0x00000 }, + { .description = "C800H", .value = 0xc8000 }, + { .description = "" } } }, { - "base", "Address", CONFIG_HEX16, "", 0x0320, "", { 0 }, - { - { "320H", 0x0320 }, - { "324H", 0x0324 }, - { "" } + .name = "base", + .description = "Address", + .type = CONFIG_HEX16, + .default_string = "", + .default_int = 0x0320, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "320H", .value = 0x0320 }, + { .description = "324H", .value = 0x0324 }, + { .description = "" } } }, { - "irq", "IRQ", CONFIG_SELECTION, "", 5, "", { 0 }, - { - { "IRQ 2", 2 }, - { "IRQ 5", 5 }, - { "" } + .name = "irq", + .description = "IRQ", + .type = CONFIG_SELECTION, + .default_string = "", + .default_int = 5, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "IRQ 2", .value = 2 }, + { .description = "IRQ 5", .value = 5 }, + { .description = "" } } }, { - "translate", "Translate 26 -> 17", CONFIG_SELECTION, "", 0, "", { 0 }, - { - { "Off", 0 }, - { "On", 1 }, - { "" } + .name = "translate", + .description = "Translate 26 -> 17", + .type = CONFIG_SELECTION, + .default_string = "", + .default_int = 0, + .file_filter = "", + .spinner = { 0 }, + .selection = { + { .description = "Off", .value = 0 }, + { .description = "On", .value = 1 }, + { .description = "" } } }, - { "", "", -1 } + { .name = "", .description = "", .type = CONFIG_END } }; static const device_config_t wd1004a_config[] = { @@ -1799,7 +1871,7 @@ static const device_config_t wd1004a_config[] = { { .description = "" } } }, - { .name = "", .description = "", .type = -1 } + { .name = "", .description = "", .type = CONFIG_END } }; static const device_config_t wd1004_rll_config[] = { @@ -1864,7 +1936,7 @@ static const device_config_t wd1004_rll_config[] = { { .description = "" } } }, - { .name = "", .description = "", .type = -1 } + { .name = "", .description = "", .type = CONFIG_END } }; // clang-format on diff --git a/src/disk/hdc_xta.c b/src/disk/hdc_xta.c index 754a4114a..ea92bcd59 100644 --- a/src/disk/hdc_xta.c +++ b/src/disk/hdc_xta.c @@ -1102,34 +1102,51 @@ xta_close(void *priv) free(dev); } - static const device_config_t wdxt150_config[] = { // clang-format off { - "base", "Address", CONFIG_HEX16, "", 0x0320, "", { 0 }, /*W2*/ - { - { "320H", 0x0320 }, - { "324H", 0x0324 }, - { "" } + .name = "base", + .description = "Address", + .type = CONFIG_HEX16, + .default_string = "", + .default_int = 0x0320, + .file_filter = "", + .spinner = { 0 }, /*W2*/ + .selection = { + { .description = "320H", .value = 0x0320 }, + { .description = "324H", .value = 0x0324 }, + { .description = "" } }, }, { - "irq", "IRQ", CONFIG_SELECTION, "", 5, "", { 0 }, /*W3*/ - { - { "IRQ 5", 5 }, - { "IRQ 4", 4 }, - { "" } + .name = "irq", + .description = "IRQ", + .type = CONFIG_SELECTION, + .default_string = "", + .default_int = 5, + .file_filter = "", + .spinner = { 0 }, /*W3*/ + .selection = { + { .description = "IRQ 5", .value = 5 }, + { .description = "IRQ 4", .value = 4 }, + { .description = "" } }, }, { - "bios_addr", "BIOS Address", CONFIG_HEX20, "", 0xc8000, "", { 0 }, /*W1*/ - { - { "C800H", 0xc8000 }, - { "CA00H", 0xca000 }, - { "" } + .name = "bios_addr", + .description = "BIOS Address", + .type = CONFIG_HEX20, + .default_string = "", + .default_int = 0xc8000, + .file_filter = "", + .spinner = { 0 }, /*W1*/ + .selection = { + { .description = "C800H", .value = 0xc8000 }, + { .description = "CA00H", .value = 0xca000 }, + { .description = "" } }, }, - { "", "", -1 } + { .name = "", .description = "", .type = CONFIG_END } // clang-format off }; diff --git a/src/disk/hdc_xtide.c b/src/disk/hdc_xtide.c index 51c8dbf4a..34805db2b 100644 --- a/src/disk/hdc_xtide.c +++ b/src/disk/hdc_xtide.c @@ -259,7 +259,6 @@ xtide_at_close(void *priv) free(xtide); } - const device_t xtide_device = { .name = "PC/XT XTIDE", .internal_name = "xtide",