Commit 7366f03f authored by Rusty Russell's avatar Rusty Russell Committed by Linus Torvalds

[PATCH] Designated initializers for i386

The old form of designated initializers are obsolete: we need to
replace them with the ISO C forms before 2.6.  Gcc has always supported
both forms anyway.
parent b0bb4b4b
...@@ -945,9 +945,9 @@ static void handle_poweroff (int key, struct pt_regs *pt_regs, ...@@ -945,9 +945,9 @@ static void handle_poweroff (int key, struct pt_regs *pt_regs,
} }
static struct sysrq_key_op sysrq_poweroff_op = { static struct sysrq_key_op sysrq_poweroff_op = {
handler: handle_poweroff, .handler = handle_poweroff,
help_msg: "Off", .help_msg = "Off",
action_msg: "Power Off\n" .action_msg = "Power Off\n"
}; };
...@@ -1840,12 +1840,12 @@ __setup("apm=", apm_setup); ...@@ -1840,12 +1840,12 @@ __setup("apm=", apm_setup);
#endif #endif
static struct file_operations apm_bios_fops = { static struct file_operations apm_bios_fops = {
owner: THIS_MODULE, .owner = THIS_MODULE,
read: do_read, .read = do_read,
poll: do_poll, .poll = do_poll,
ioctl: do_ioctl, .ioctl = do_ioctl,
open: do_open, .open = do_open,
release: do_release, .release = do_release,
}; };
static struct miscdevice apm_device = { static struct miscdevice apm_device = {
......
...@@ -307,7 +307,7 @@ static void do_mce_timer(void *data) ...@@ -307,7 +307,7 @@ static void do_mce_timer(void *data)
} }
static struct tq_struct mce_task = { static struct tq_struct mce_task = {
routine: do_mce_timer .routine = do_mce_timer
}; };
static void mce_timerfunc (unsigned long data) static void mce_timerfunc (unsigned long data)
......
...@@ -189,8 +189,8 @@ static unsigned int amd_size_cache(struct cpuinfo_x86 * c, unsigned int size) ...@@ -189,8 +189,8 @@ static unsigned int amd_size_cache(struct cpuinfo_x86 * c, unsigned int size)
} }
static struct cpu_dev amd_cpu_dev __initdata = { static struct cpu_dev amd_cpu_dev __initdata = {
c_vendor: "AMD", .c_vendor = "AMD",
c_ident: { "AuthenticAMD" }, .c_ident = { "AuthenticAMD" },
c_models: { c_models: {
{ X86_VENDOR_AMD, 4, { X86_VENDOR_AMD, 4,
{ {
...@@ -203,9 +203,9 @@ static struct cpu_dev amd_cpu_dev __initdata = { ...@@ -203,9 +203,9 @@ static struct cpu_dev amd_cpu_dev __initdata = {
} }
}, },
}, },
c_init: init_amd, .c_init = init_amd,
c_identify: amd_identify, .c_identify = amd_identify,
c_size_cache: amd_size_cache, .c_size_cache = amd_size_cache,
}; };
int __init amd_init_cpu(void) int __init amd_init_cpu(void)
......
...@@ -411,10 +411,10 @@ static unsigned int centaur_size_cache(struct cpuinfo_x86 * c, unsigned int size ...@@ -411,10 +411,10 @@ static unsigned int centaur_size_cache(struct cpuinfo_x86 * c, unsigned int size
} }
static struct cpu_dev centaur_cpu_dev __initdata = { static struct cpu_dev centaur_cpu_dev __initdata = {
c_vendor: "Centaur", .c_vendor = "Centaur",
c_ident: { "CentaurHauls" }, .c_ident = { "CentaurHauls" },
c_init: init_centaur, .c_init = init_centaur,
c_size_cache: centaur_size_cache, .c_size_cache = centaur_size_cache,
}; };
int __init centaur_init_cpu(void) int __init centaur_init_cpu(void)
......
...@@ -31,7 +31,7 @@ static void default_init(struct cpuinfo_x86 * c) ...@@ -31,7 +31,7 @@ static void default_init(struct cpuinfo_x86 * c)
} }
static struct cpu_dev default_cpu = { static struct cpu_dev default_cpu = {
c_init: default_init, .c_init = default_init,
}; };
static struct cpu_dev * this_cpu = &default_cpu; static struct cpu_dev * this_cpu = &default_cpu;
......
...@@ -322,10 +322,10 @@ static void cyrix_identify(struct cpuinfo_x86 * c) ...@@ -322,10 +322,10 @@ static void cyrix_identify(struct cpuinfo_x86 * c)
} }
static struct cpu_dev cyrix_cpu_dev __initdata = { static struct cpu_dev cyrix_cpu_dev __initdata = {
c_vendor: "Cyrix", .c_vendor = "Cyrix",
c_ident: { "CyrixInstead" }, .c_ident = { "CyrixInstead" },
c_init: init_cyrix, .c_init = init_cyrix,
c_identify: cyrix_identify, .c_identify = cyrix_identify,
}; };
int __init cyrix_init_cpu(void) int __init cyrix_init_cpu(void)
...@@ -337,10 +337,10 @@ int __init cyrix_init_cpu(void) ...@@ -337,10 +337,10 @@ int __init cyrix_init_cpu(void)
//early_arch_initcall(cyrix_init_cpu); //early_arch_initcall(cyrix_init_cpu);
static struct cpu_dev nsc_cpu_dev __initdata = { static struct cpu_dev nsc_cpu_dev __initdata = {
c_vendor: "NSC", .c_vendor = "NSC",
c_ident: { "Geode by NSC" }, .c_ident = { "Geode by NSC" },
c_init: init_cyrix, .c_init = init_cyrix,
c_identify: generic_identify, .c_identify = generic_identify,
}; };
int __init nsc_init_cpu(void) int __init nsc_init_cpu(void)
......
...@@ -327,8 +327,8 @@ static unsigned int intel_size_cache(struct cpuinfo_x86 * c, unsigned int size) ...@@ -327,8 +327,8 @@ static unsigned int intel_size_cache(struct cpuinfo_x86 * c, unsigned int size)
} }
static struct cpu_dev intel_cpu_dev __initdata = { static struct cpu_dev intel_cpu_dev __initdata = {
c_vendor: "Intel", .c_vendor = "Intel",
c_ident: { "GenuineIntel" }, .c_ident = { "GenuineIntel" },
c_models: { c_models: {
{ X86_VENDOR_INTEL, 4, { X86_VENDOR_INTEL, 4,
{ {
...@@ -375,9 +375,9 @@ static struct cpu_dev intel_cpu_dev __initdata = { ...@@ -375,9 +375,9 @@ static struct cpu_dev intel_cpu_dev __initdata = {
} }
}, },
}, },
c_init: init_intel, .c_init = init_intel,
c_identify: generic_identify, .c_identify = generic_identify,
c_size_cache: intel_size_cache, .c_size_cache = intel_size_cache,
}; };
__init int intel_cpu_init(void) __init int intel_cpu_init(void)
......
...@@ -42,13 +42,13 @@ static void nexgen_identify(struct cpuinfo_x86 * c) ...@@ -42,13 +42,13 @@ static void nexgen_identify(struct cpuinfo_x86 * c)
} }
static struct cpu_dev nexgen_cpu_dev __initdata = { static struct cpu_dev nexgen_cpu_dev __initdata = {
c_vendor: "Nexgen", .c_vendor = "Nexgen",
c_ident: { "NexGenDriven" }, .c_ident = { "NexGenDriven" },
c_models: { c_models: {
{ X86_VENDOR_NEXGEN,5, { [1] "Nx586" } }, { X86_VENDOR_NEXGEN,5, { [1] "Nx586" } },
}, },
c_init: init_nexgen, .c_init = init_nexgen,
c_identify: nexgen_identify, .c_identify = nexgen_identify,
}; };
int __init nexgen_init_cpu(void) int __init nexgen_init_cpu(void)
......
...@@ -119,8 +119,8 @@ static void c_stop(struct seq_file *m, void *v) ...@@ -119,8 +119,8 @@ static void c_stop(struct seq_file *m, void *v)
{ {
} }
struct seq_operations cpuinfo_op = { struct seq_operations cpuinfo_op = {
start: c_start, .start = c_start,
next: c_next, .next = c_next,
stop: c_stop, .stop = c_stop,
show: show_cpuinfo, .show = show_cpuinfo,
}; };
...@@ -29,8 +29,8 @@ static void __init init_rise(struct cpuinfo_x86 *c) ...@@ -29,8 +29,8 @@ static void __init init_rise(struct cpuinfo_x86 *c)
} }
static struct cpu_dev rise_cpu_dev __initdata = { static struct cpu_dev rise_cpu_dev __initdata = {
c_vendor: "Rise", .c_vendor = "Rise",
c_ident: { "RiseRiseRise" }, .c_ident = { "RiseRiseRise" },
c_models: { c_models: {
{ X86_VENDOR_RISE, 5, { X86_VENDOR_RISE, 5,
{ {
...@@ -41,7 +41,7 @@ static struct cpu_dev rise_cpu_dev __initdata = { ...@@ -41,7 +41,7 @@ static struct cpu_dev rise_cpu_dev __initdata = {
} }
}, },
}, },
c_init: init_rise, .c_init = init_rise,
}; };
int __init rise_init_cpu(void) int __init rise_init_cpu(void)
......
...@@ -80,10 +80,10 @@ static void transmeta_identify(struct cpuinfo_x86 * c) ...@@ -80,10 +80,10 @@ static void transmeta_identify(struct cpuinfo_x86 * c)
} }
static struct cpu_dev transmeta_cpu_dev __initdata = { static struct cpu_dev transmeta_cpu_dev __initdata = {
c_vendor: "Transmeta", .c_vendor = "Transmeta",
c_ident: { "GenuineTMx86", "TransmetaCPU" }, .c_ident = { "GenuineTMx86", "TransmetaCPU" },
c_init: init_transmeta, .c_init = init_transmeta,
c_identify: transmeta_identify, .c_identify = transmeta_identify,
}; };
int __init transmeta_init_cpu(void) int __init transmeta_init_cpu(void)
......
...@@ -11,8 +11,8 @@ static void __init init_umc(struct cpuinfo_x86 * c) ...@@ -11,8 +11,8 @@ static void __init init_umc(struct cpuinfo_x86 * c)
} }
static struct cpu_dev umc_cpu_dev __initdata = { static struct cpu_dev umc_cpu_dev __initdata = {
c_vendor: "UMC", .c_vendor = "UMC",
c_ident: { "UMC UMC UMC" }, .c_ident = { "UMC UMC UMC" },
c_models: { c_models: {
{ X86_VENDOR_UMC, 4, { X86_VENDOR_UMC, 4,
{ {
...@@ -21,7 +21,7 @@ static struct cpu_dev umc_cpu_dev __initdata = { ...@@ -21,7 +21,7 @@ static struct cpu_dev umc_cpu_dev __initdata = {
} }
}, },
}, },
c_init: init_umc, .c_init = init_umc,
}; };
int __init umc_init_cpu(void) int __init umc_init_cpu(void)
......
...@@ -146,10 +146,10 @@ static int cpuid_open(struct inode *inode, struct file *file) ...@@ -146,10 +146,10 @@ static int cpuid_open(struct inode *inode, struct file *file)
* File operations we support * File operations we support
*/ */
static struct file_operations cpuid_fops = { static struct file_operations cpuid_fops = {
owner: THIS_MODULE, .owner = THIS_MODULE,
llseek: cpuid_seek, .llseek = cpuid_seek,
read: cpuid_read, .read = cpuid_read,
open: cpuid_open, .open = cpuid_open,
}; };
int __init cpuid_init(void) int __init cpuid_init(void)
......
...@@ -247,13 +247,13 @@ static int i8259A_resume(struct device *dev, u32 level) ...@@ -247,13 +247,13 @@ static int i8259A_resume(struct device *dev, u32 level)
} }
static struct device_driver driver_i8259A = { static struct device_driver driver_i8259A = {
resume: i8259A_resume, .resume = i8259A_resume,
}; };
static struct device device_i8259A = { static struct device device_i8259A = {
name: "i8259A", .name = "i8259A",
bus_id: "0020", .bus_id = "0020",
driver: &driver_i8259A, .driver = &driver_i8259A,
}; };
static int __init init_8259A_devicefs(void) static int __init init_8259A_devicefs(void)
......
...@@ -109,17 +109,17 @@ static unsigned int mc_fsize; /* file size of /dev/cpu/microcode */ ...@@ -109,17 +109,17 @@ static unsigned int mc_fsize; /* file size of /dev/cpu/microcode */
/* we share file_operations between misc and devfs mechanisms */ /* we share file_operations between misc and devfs mechanisms */
static struct file_operations microcode_fops = { static struct file_operations microcode_fops = {
owner: THIS_MODULE, .owner = THIS_MODULE,
read: microcode_read, .read = microcode_read,
write: microcode_write, .write = microcode_write,
ioctl: microcode_ioctl, .ioctl = microcode_ioctl,
open: microcode_open, .open = microcode_open,
}; };
static struct miscdevice microcode_dev = { static struct miscdevice microcode_dev = {
minor: MICROCODE_MINOR, .minor = MICROCODE_MINOR,
name: "microcode", .name = "microcode",
fops: &microcode_fops, .fops = &microcode_fops,
}; };
static devfs_handle_t devfs_handle; static devfs_handle_t devfs_handle;
......
...@@ -246,11 +246,11 @@ static int msr_open(struct inode *inode, struct file *file) ...@@ -246,11 +246,11 @@ static int msr_open(struct inode *inode, struct file *file)
* File operations we support * File operations we support
*/ */
static struct file_operations msr_fops = { static struct file_operations msr_fops = {
owner: THIS_MODULE, .owner = THIS_MODULE,
llseek: msr_seek, .llseek = msr_seek,
read: msr_read, .read = msr_read,
write: msr_write, .write = msr_write,
open: msr_open, .open = msr_open,
}; };
int __init msr_init(void) int __init msr_init(void)
......
...@@ -1836,11 +1836,11 @@ static int mtrr_close (struct inode *ino, struct file *file) ...@@ -1836,11 +1836,11 @@ static int mtrr_close (struct inode *ino, struct file *file)
static struct file_operations mtrr_fops = static struct file_operations mtrr_fops =
{ {
owner: THIS_MODULE, .owner = THIS_MODULE,
read: mtrr_read, .read = mtrr_read,
write: mtrr_write, .write = mtrr_write,
ioctl: mtrr_ioctl, .ioctl = mtrr_ioctl,
release: mtrr_close, .release = mtrr_close,
}; };
# ifdef CONFIG_PROC_FS # ifdef CONFIG_PROC_FS
......
...@@ -639,8 +639,8 @@ static unsigned long __init calibrate_tsc(void) ...@@ -639,8 +639,8 @@ static unsigned long __init calibrate_tsc(void)
} }
static struct device device_i8253 = { static struct device device_i8253 = {
name: "i8253", .name = "i8253",
bus_id: "0040", .bus_id = "0040",
}; };
static int time_init_driverfs(void) static int time_init_driverfs(void)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment