Commit 6f79387d authored by Art Haas's avatar Art Haas Committed by James Bottomley

[PATCH] C99 struct initializers for kernel files

parent 6be13f9a
...@@ -32,11 +32,12 @@ static u_long ident_map[32] = { ...@@ -32,11 +32,12 @@ static u_long ident_map[32] = {
}; };
struct exec_domain default_exec_domain = { struct exec_domain default_exec_domain = {
"Linux", /* name */ .name = "Linux", /* name */
default_handler, /* lcall7 causes a seg fault. */ .handler = default_handler, /* lcall7 causes a seg fault. */
0, 0, /* PER_LINUX personality. */ .pers_low = 0, /* PER_LINUX personality. */
ident_map, /* Identity map signals. */ .pers_high = 0, /* PER_LINUX personality. */
ident_map, /* - both ways. */ .signal_map = ident_map, /* Identity map signals. */
.signal_invmap = ident_map, /* - both ways. */
}; };
...@@ -247,24 +248,65 @@ u_int abi_traceflg; ...@@ -247,24 +248,65 @@ u_int abi_traceflg;
int abi_fake_utsname; int abi_fake_utsname;
static struct ctl_table abi_table[] = { static struct ctl_table abi_table[] = {
{ABI_DEFHANDLER_COFF, "defhandler_coff", &abi_defhandler_coff, {
sizeof(int), 0644, NULL, &proc_doulongvec_minmax}, .ctl_name = ABI_DEFHANDLER_COFF,
{ABI_DEFHANDLER_ELF, "defhandler_elf", &abi_defhandler_elf, .procname = "defhandler_coff",
sizeof(int), 0644, NULL, &proc_doulongvec_minmax}, .data = &abi_defhandler_coff,
{ABI_DEFHANDLER_LCALL7, "defhandler_lcall7", &abi_defhandler_lcall7, .maxlen = sizeof(int),
sizeof(int), 0644, NULL, &proc_doulongvec_minmax}, .mode = 0644,
{ABI_DEFHANDLER_LIBCSO, "defhandler_libcso", &abi_defhandler_libcso, .proc_handler = &proc_doulongvec_minmax,
sizeof(int), 0644, NULL, &proc_doulongvec_minmax}, },
{ABI_TRACE, "trace", &abi_traceflg, {
sizeof(u_int), 0644, NULL, &proc_dointvec}, .ctl_name = ABI_DEFHANDLER_ELF,
{ABI_FAKE_UTSNAME, "fake_utsname", &abi_fake_utsname, .procname = "defhandler_elf",
sizeof(int), 0644, NULL, &proc_dointvec}, .data = &abi_defhandler_elf,
{0} .maxlen = sizeof(int),
.mode = 0644,
.proc_handler = &proc_doulongvec_minmax,
},
{
.ctl_name = ABI_DEFHANDLER_LCALL7,
.procname = "defhandler_lcall7",
.data = &abi_defhandler_lcall7,
.maxlen = sizeof(int),
.mode = 0644,
.proc_handler = &proc_doulongvec_minmax,
},
{
.ctl_name = ABI_DEFHANDLER_LIBCSO,
.procname = "defhandler_libcso",
.data = &abi_defhandler_libcso,
.maxlen = sizeof(int),
.mode = 0644,
.proc_handler = &proc_doulongvec_minmax,
},
{
.ctl_name = ABI_TRACE,
.procname = "trace",
.data = &abi_traceflg,
.maxlen = sizeof(u_int),
.mode = 0644,
.proc_handler = &proc_dointvec,
},
{
.ctl_name = ABI_FAKE_UTSNAME,
.procname = "fake_utsname",
.data = &abi_fake_utsname,
.maxlen = sizeof(int),
.mode = 0644,
.proc_handler = &proc_dointvec,
},
{ .ctl_name = 0 }
}; };
static struct ctl_table abi_root_table[] = { static struct ctl_table abi_root_table[] = {
{CTL_ABI, "abi", NULL, 0, 0555, abi_table}, {
{0} .ctl_name = CTL_ABI,
.procname = "abi",
.mode = 0555,
.child = abi_table,
},
{ .ctl_name = 0 }
}; };
static int __init static int __init
......
...@@ -20,8 +20,19 @@ ...@@ -20,8 +20,19 @@
#include <asm/io.h> #include <asm/io.h>
struct resource ioport_resource = { "PCI IO", 0x0000, IO_SPACE_LIMIT, IORESOURCE_IO }; struct resource ioport_resource = {
struct resource iomem_resource = { "PCI mem", 0UL, ~0UL, IORESOURCE_MEM }; .name = "PCI IO",
.start = 0x0000,
.end = IO_SPACE_LIMIT,
.flags = IORESOURCE_IO,
};
struct resource iomem_resource = {
.name = "PCI mem",
.start = 0UL,
.end = ~0UL,
.flags = IORESOURCE_MEM,
};
static rwlock_t resource_lock = RW_LOCK_UNLOCKED; static rwlock_t resource_lock = RW_LOCK_UNLOCKED;
......
This diff is collapsed.
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