Skip to contentSkip to conversation

C99 designated initializers for drivers/char

PATCH New Art Haas 1 participant 1 message Nov 5, 2002

Subsystems (5)
lore
Share & tools
lore

Art Haas

author
#0 lore raw

PATCH 1/1 C99 designated initializers for drivers/char

Hi.

Here's a big patch that switches drivers/char to use C99 designated initializers. The patch is against 2.5.46.

Art Haas

drivers/char/acquirewdt.c renamed from drivers/char/acquirewdt.c.old +6 -6
@@ -186,12 +186,12 @@
  
  
 static struct file_operations acq_fops = {
-	owner:		THIS_MODULE,
-	read:		acq_read,
-	write:		acq_write,
-	ioctl:		acq_ioctl,
-	open:		acq_open,
-	release:	acq_close,
+	.owner		= THIS_MODULE,
+	.read		= acq_read,
+	.write		= acq_write,
+	.ioctl		= acq_ioctl,
+	.open		= acq_open,
+	.release	= acq_close,
 };
 
 static struct miscdevice acq_miscdev=
drivers/char/advantechwdt.c renamed from drivers/char/advantechwdt.c.old +6 -6
@@ -200,12 +200,12 @@
  */
  
 static struct file_operations advwdt_fops = {
-	owner:		THIS_MODULE,
-	read:		advwdt_read,
-	write:		advwdt_write,
-	ioctl:		advwdt_ioctl,
-	open:		advwdt_open,
-	release:	advwdt_close,
+	.owner		= THIS_MODULE,
+	.read		= advwdt_read,
+	.write		= advwdt_write,
+	.ioctl		= advwdt_ioctl,
+	.open		= advwdt_open,
+	.release	= advwdt_close,
 };
 
 static struct miscdevice advwdt_miscdev = {
drivers/char/amd768_rng.c renamed from drivers/char/amd768_rng.c.old +4 -4
@@ -167,10 +167,10 @@
 
 
 static struct file_operations rng_chrdev_ops = {
-	owner:		THIS_MODULE,
-	open:		rng_dev_open,
-	release:	rng_dev_release,
-	read:		rng_dev_read,
+	.owner		= THIS_MODULE,
+	.open		= rng_dev_open,
+	.release	= rng_dev_release,
+	.read		= rng_dev_read,
 };
 
 
drivers/char/applicom.c renamed from drivers/char/applicom.c.old +5 -5
@@ -119,11 +119,11 @@
 static void ac_interrupt(int, void *, struct pt_regs *);
 
 static struct file_operations ac_fops = {
-	owner:THIS_MODULE,
-	llseek:no_llseek,
-	read:ac_read,
-	write:ac_write,
-	ioctl:ac_ioctl,
+	.owner = THIS_MODULE,
+	.llseek = no_llseek,
+	.read = ac_read,
+	.write = ac_write,
+	.ioctl = ac_ioctl,
 };
 
 static struct miscdevice ac_miscdev = {
drivers/char/busmouse.c renamed from drivers/char/busmouse.c.old +7 -7
@@ -336,13 +336,13 @@
 
 struct file_operations busmouse_fops=
 {
-	owner:		THIS_MODULE,
-	read:		busmouse_read,
-	write:		busmouse_write,
-	poll:		busmouse_poll,
-	open:		busmouse_open,
-	release:	busmouse_release,
-	fasync:		busmouse_fasync,
+	.owner		= THIS_MODULE,
+	.read		= busmouse_read,
+	.write		= busmouse_write,
+	.poll		= busmouse_poll,
+	.open		= busmouse_open,
+	.release	= busmouse_release,
+	.fasync		= busmouse_fasync,
 };
 
 /**
drivers/char/cyclades.c renamed from drivers/char/cyclades.c.old +1 -1
@@ -884,7 +884,7 @@
 
 static int cyz_timeron = 0;
 static struct timer_list cyz_timerlist = {
-    function: cyz_poll
+    .function = cyz_poll
 };
 #else /* CONFIG_CYZ_INTR */
 static void cyz_rx_restart(unsigned long);
drivers/char/ds1620.c renamed from drivers/char/ds1620.c.old +3 -3
@@ -337,9 +337,9 @@
 #endif
 
 static struct file_operations ds1620_fops = {
-	owner:		THIS_MODULE,
-	read:		ds1620_read,
-	ioctl:		ds1620_ioctl,
+	.owner		= THIS_MODULE,
+	.read		= ds1620_read,
+	.ioctl		= ds1620_ioctl,
 };
 
 static struct miscdevice ds1620_miscdev = {
drivers/char/dsp56k.c renamed from drivers/char/dsp56k.c.old +6 -6
@@ -488,12 +488,12 @@
 }
 
 static struct file_operations dsp56k_fops = {
-	owner:		THIS_MODULE,
-	read:		dsp56k_read,
-	write:		dsp56k_write,
-	ioctl:		dsp56k_ioctl,
-	open:		dsp56k_open,
-	release:	dsp56k_release,
+	.owner		= THIS_MODULE,
+	.read		= dsp56k_read,
+	.write		= dsp56k_write,
+	.ioctl		= dsp56k_ioctl,
+	.open		= dsp56k_open,
+	.release	= dsp56k_release,
 };
 
 
drivers/char/dtlk.c renamed from drivers/char/dtlk.c.old +7 -7
@@ -98,13 +98,13 @@
 
 static struct file_operations dtlk_fops =
 {
-	owner:		THIS_MODULE,
-	read:		dtlk_read,
-	write:		dtlk_write,
-	poll:		dtlk_poll,
-	ioctl:		dtlk_ioctl,
-	open:		dtlk_open,
-	release:	dtlk_release,
+	.owner		= THIS_MODULE,
+	.read		= dtlk_read,
+	.write		= dtlk_write,
+	.poll		= dtlk_poll,
+	.ioctl		= dtlk_ioctl,
+	.open		= dtlk_open,
+	.release	= dtlk_release,
 };
 
 /* local prototypes */
drivers/char/dz.c renamed from drivers/char/dz.c.old +6 -6
@@ -1601,12 +1601,12 @@
 }
 
 static struct console dz_sercons = {
-    name:	"ttyS",
-    write:	dz_console_print,
-    device:	dz_console_device,
-    setup:	dz_console_setup,
-    flags:	CON_CONSDEV | CON_PRINTBUFFER,
-    index:	CONSOLE_LINE,
+    .name	= "ttyS",
+    .write	= dz_console_print,
+    .device	= dz_console_device,
+    .setup	= dz_console_setup,
+    .flags	= CON_CONSDEV | CON_PRINTBUFFER,
+    .index	= CONSOLE_LINE,
 };
 
 void __init dz_serial_console_init(void)
drivers/char/efirtc.c renamed from drivers/char/efirtc.c.old +4 -4
@@ -282,10 +282,10 @@
  */
 
 static struct file_operations efi_rtc_fops = {
-	owner:		THIS_MODULE,
-	ioctl:		efi_rtc_ioctl,
-	open:		efi_rtc_open,
-	release:	efi_rtc_close,
+	.owner		= THIS_MODULE,
+	.ioctl		= efi_rtc_ioctl,
+	.open		= efi_rtc_open,
+	.release	= efi_rtc_close,
 };
 
 static struct miscdevice efi_rtc_dev=
drivers/char/eurotechwdt.c renamed from drivers/char/eurotechwdt.c.old +6 -6
@@ -388,12 +388,12 @@
  
  
 static struct file_operations eurwdt_fops = {
-        owner:          THIS_MODULE,
-        llseek:         no_llseek,
-        write:          eurwdt_write,
-        ioctl:          eurwdt_ioctl,
-        open:           eurwdt_open,
-        release:        eurwdt_release,
+        .owner          = THIS_MODULE,
+        .llseek         = no_llseek,
+        .write          = eurwdt_write,
+        .ioctl          = eurwdt_ioctl,
+        .open           = eurwdt_open,
+        .release        = eurwdt_release,
 };
 
 static struct miscdevice eurwdt_miscdev =
drivers/char/hp_psaux.c renamed from drivers/char/hp_psaux.c.old +14 -14
@@ -370,18 +370,18 @@
 }
 
 static struct file_operations psaux_fops = {
-	read:		read_aux,
-	write:		write_aux,
-	poll:		aux_poll,
-	open:		open_aux,
-	release:	release_aux,
-	fasync:		fasync_aux,
+	.read		= read_aux,
+	.write		= write_aux,
+	.poll		= aux_poll,
+	.open		= open_aux,
+	.release	= release_aux,
+	.fasync		= fasync_aux,
 };
 
 static struct miscdevice psaux_mouse = {
-	minor:		PSMOUSE_MINOR,
-	name:		"psaux",
-	fops:		&psaux_fops,
+	.minor		= PSMOUSE_MINOR,
+	.name		= "psaux",
+	.fops		= &psaux_fops,
 };
 
 #endif /* CONFIG_PSMOUSE */
@@ -452,12 +452,12 @@
 extern int pckbd_translate(unsigned char, unsigned char *, char);
 
 static struct kbd_ops gsc_ps2_kbd_ops = {
-	translate:	pckbd_translate,
-	init_hw:	lasi_ps2_init_hw,
-	leds:		lasikbd_leds,
+	.translate	= pckbd_translate,
+	.init_hw	= lasi_ps2_init_hw,
+	.leds		= lasikbd_leds,
 #ifdef CONFIG_MAGIC_SYSRQ
-	sysrq_key:	0x54,
-	sysrq_xlate:	hp_ps2kbd_sysrq_xlate,
+	.sysrq_key	= 0x54,
+	.sysrq_xlate	= hp_ps2kbd_sysrq_xlate,
 #endif
 };
 
drivers/char/hvc_console.c renamed from drivers/char/hvc_console.c.old +6 -6
@@ -340,12 +340,12 @@
 }
 
 struct console hvc_con_driver = {
-	name:		"hvc",
-	write:		hvc_console_print,
-	device:		hvc_console_device,
-	setup:		hvc_console_setup,
-	flags:		CON_PRINTBUFFER,
-	index:		-1,
+	.name		= "hvc",
+	.write		= hvc_console_print,
+	.device		= hvc_console_device,
+	.setup		= hvc_console_setup,
+	.flags		= CON_PRINTBUFFER,
+	.index		= -1,
 };
 
 int __init hvc_console_init(void)
drivers/char/i810-tco.c renamed from drivers/char/i810-tco.c.old +11 -11
@@ -244,9 +244,9 @@
 	int options, retval = -EINVAL;
 
 	static struct watchdog_info ident = {
-		options:		WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING,
-		firmware_version:	0,
-		identity:		"i810 TCO timer",
+		.options		= WDIOF_SETTIMEOUT | WDIOF_KEEPALIVEPING,
+		.firmware_version	= 0,
+		.identity		= "i810 TCO timer",
 	};
 	switch (cmd) {
 		default:
@@ -371,17 +371,17 @@
 }
 
 static struct file_operations i810tco_fops = {
-	owner:		THIS_MODULE,
-	write:		i810tco_write,
-	ioctl:		i810tco_ioctl,
-	open:		i810tco_open,
-	release:	i810tco_release,
+	.owner		= THIS_MODULE,
+	.write		= i810tco_write,
+	.ioctl		= i810tco_ioctl,
+	.open		= i810tco_open,
+	.release	= i810tco_release,
 };
 
 static struct miscdevice i810tco_miscdev = {
-	minor:		WATCHDOG_MINOR,
-	name:		"watchdog",
-	fops:		&i810tco_fops,
+	.minor		= WATCHDOG_MINOR,
+	.name		= "watchdog",
+	.fops		= &i810tco_fops,
 };
 
 static int __init watchdog_init (void)
drivers/char/i810_rng.c renamed from drivers/char/i810_rng.c.old +4 -4
@@ -255,10 +255,10 @@
 
 
 static struct file_operations rng_chrdev_ops = {
-	owner:		THIS_MODULE,
-	open:		rng_dev_open,
-	release:	rng_dev_release,
-	read:		rng_dev_read,
+	.owner		= THIS_MODULE,
+	.open		= rng_dev_open,
+	.release	= rng_dev_release,
+	.read		= rng_dev_read,
 };
 
 
drivers/char/i8k.c renamed from drivers/char/i8k.c.old +2 -2
@@ -82,8 +82,8 @@
 		     unsigned long);
 
 static struct file_operations i8k_fops = {
-    read:	i8k_read,
-    ioctl:	i8k_ioctl,
+    .read	= i8k_read,
+    .ioctl	= i8k_ioctl,
 };
 
 typedef struct {
drivers/char/ib700wdt.c renamed from drivers/char/ib700wdt.c.old +6 -6
@@ -239,12 +239,12 @@
  */
 
 static struct file_operations ibwdt_fops = {
-	owner:		THIS_MODULE,
-	read:		ibwdt_read,
-	write:		ibwdt_write,
-	ioctl:		ibwdt_ioctl,
-	open:		ibwdt_open,
-	release:	ibwdt_close,
+	.owner		= THIS_MODULE,
+	.read		= ibwdt_read,
+	.write		= ibwdt_write,
+	.ioctl		= ibwdt_ioctl,
+	.open		= ibwdt_open,
+	.release	= ibwdt_close,
 };
 
 static struct miscdevice ibwdt_miscdev = {
drivers/char/ip2main.c renamed from drivers/char/ip2main.c.old +6 -6
@@ -334,11 +334,11 @@
  * download the loadware to the boards.
  */
 static struct file_operations ip2_ipl = {
-	owner:		THIS_MODULE,
-	read:		ip2_ipl_read,
-	write:		ip2_ipl_write,
-	ioctl:		ip2_ipl_ioctl,
-	open:		ip2_ipl_open,
+	.owner		= THIS_MODULE,
+	.read		= ip2_ipl_read,
+	.write		= ip2_ipl_write,
+	.ioctl		= ip2_ipl_ioctl,
+	.open		= ip2_ipl_open,
 }; 
 
 static unsigned long irq_counter = 0;
@@ -352,7 +352,7 @@
  * selected, the board is serviced periodically to see if anything needs doing.
  */
 #define  POLL_TIMEOUT   (jiffies + 1)
-static struct timer_list PollTimer = { function: ip2_poll };
+static struct timer_list PollTimer = { .function = ip2_poll };
 static char  TimerOn;
 
 #ifdef IP2DEBUG_TRACE
drivers/char/isicom.c renamed from drivers/char/isicom.c.old +2 -2
@@ -113,8 +113,8 @@
  */
 
 static struct file_operations ISILoad_fops = {
-	owner:		THIS_MODULE,
-	ioctl:		ISILoad_ioctl,
+	.owner		= THIS_MODULE,
+	.ioctl		= ISILoad_ioctl,
 };
 
 struct miscdevice isiloader_device = {
drivers/char/istallion.c renamed from drivers/char/istallion.c.old +7 -7
@@ -213,8 +213,8 @@
  *	at 9600 baud, 8 data bits, no parity, 1 stop bit.
  */
 static struct termios		stli_deftermios = {
-	c_cflag:	(B9600 | CS8 | CREAD | HUPCL | CLOCAL),
-	c_cc:		INIT_C_CC,
+	.c_cflag	= (B9600 | CS8 | CREAD | HUPCL | CLOCAL),
+	.c_cc		= INIT_C_CC,
 };
 
 /*
@@ -783,10 +783,10 @@
  *	board. This is also a very useful debugging tool.
  */
 static struct file_operations	stli_fsiomem = {
-	owner:		THIS_MODULE,
-	read:		stli_memread,
-	write:		stli_memwrite,
-	ioctl:		stli_memioctl,
+	.owner		= THIS_MODULE,
+	.read		= stli_memread,
+	.write		= stli_memwrite,
+	.ioctl		= stli_memioctl,
 };
 
 /*****************************************************************************/
@@ -798,7 +798,7 @@
  *	not increase character latency by much either...
  */
 static struct timer_list	stli_timerlist = {
-	function: stli_poll
+	.function = stli_poll
 };
 
 static int	stli_timeron;
drivers/char/ite_gpio.c renamed from drivers/char/ite_gpio.c.old +4 -4
@@ -373,10 +373,10 @@
 
 static struct file_operations ite_gpio_fops =
 {
-	owner:		THIS_MODULE,
-	ioctl:		ite_gpio_ioctl,
-	open:		ite_gpio_open,
-	release:	ite_gpio_release,
+	.owner		= THIS_MODULE,
+	.ioctl		= ite_gpio_ioctl,
+	.open		= ite_gpio_open,
+	.release	= ite_gpio_release,
 };
 
 /* GPIO_MINOR in include/linux/miscdevice.h */
drivers/char/keyboard.c renamed from drivers/char/keyboard.c.old +10 -10
@@ -233,7 +233,7 @@
 	}
 }
 
-static struct timer_list kd_mksound_timer = { function: kd_nosound };
+static struct timer_list kd_mksound_timer = { .function = kd_nosound };
 
 void kd_mksound(unsigned int hz, unsigned int ticks)
 {
@@ -1171,13 +1171,13 @@
 
 static struct input_device_id kbd_ids[] = {
 	{
-                flags: INPUT_DEVICE_ID_MATCH_EVBIT,
-                evbit: { BIT(EV_KEY) },
+                .flags = INPUT_DEVICE_ID_MATCH_EVBIT,
+                .evbit = { BIT(EV_KEY) },
         },
 	
 	{
-                flags: INPUT_DEVICE_ID_MATCH_EVBIT,
-                evbit: { BIT(EV_SND) },
+                .flags = INPUT_DEVICE_ID_MATCH_EVBIT,
+                .evbit = { BIT(EV_SND) },
         },	
 
 	{ },    /* Terminating entry */
@@ -1186,11 +1186,11 @@
 MODULE_DEVICE_TABLE(input, kbd_ids);
 
 static struct input_handler kbd_handler = {
-	event:		kbd_event,
-	connect:	kbd_connect,
-	disconnect:	kbd_disconnect,
-	name:		"kbd",
-	id_table:	kbd_ids,
+	.event		= kbd_event,
+	.connect	= kbd_connect,
+	.disconnect	= kbd_disconnect,
+	.name		= "kbd",
+	.id_table	= kbd_ids,
 };
 
 int __init kbd_init(void)
drivers/char/lp.c renamed from drivers/char/lp.c.old +10 -10
@@ -660,13 +660,13 @@
 }
 
 static struct file_operations lp_fops = {
-	owner:		THIS_MODULE,
-	write:		lp_write,
-	ioctl:		lp_ioctl,
-	open:		lp_open,
-	release:	lp_release,
+	.owner		= THIS_MODULE,
+	.write		= lp_write,
+	.ioctl		= lp_ioctl,
+	.open		= lp_open,
+	.release	= lp_release,
 #ifdef CONFIG_PARPORT_1284
-	read:		lp_read,
+	.read		= lp_read,
 #endif
 };
 
@@ -741,10 +741,10 @@
 }
 
 static struct console lpcons = {
-	name:		"lp",
-	write:		lp_console_write,
-	device:		lp_console_device,
-	flags:		CON_PRINTBUFFER,
+	.name		= "lp",
+	.write		= lp_console_write,
+	.device		= lp_console_device,
+	.flags		= CON_PRINTBUFFER,
 };
 
 #endif /* console on line printer */
drivers/char/machzwd.c renamed from drivers/char/machzwd.c.old +9 -9
@@ -117,9 +117,9 @@
 #define PFX "machzwd"
 
 static struct watchdog_info zf_info = {
-	options:		WDIOF_KEEPALIVEPING, 
-	firmware_version:	1, 
-	identity:		"ZF-Logic watchdog"
+	.options		= WDIOF_KEEPALIVEPING, 
+	.firmware_version	= 1, 
+	.identity		= "ZF-Logic watchdog"
 };
 
 
@@ -449,12 +449,12 @@
 
 
 static struct file_operations zf_fops = {
-	owner:          THIS_MODULE,
-	read:           zf_read,
-	write:          zf_write,
-	ioctl:          zf_ioctl,
-	open:           zf_open,
-	release:        zf_close,
+	.owner          = THIS_MODULE,
+	.read           = zf_read,
+	.write          = zf_write,
+	.ioctl          = zf_ioctl,
+	.open           = zf_open,
+	.release        = zf_close,
 };
 
 static struct miscdevice zf_miscdev = {
drivers/char/mem.c renamed from drivers/char/mem.c.old +25 -25

79 lines not on this page · raw message

drivers/char/misc.c renamed from drivers/char/misc.c.old +2 -2
@@ -146,8 +146,8 @@
 }
 
 static struct file_operations misc_fops = {
-	owner:		THIS_MODULE,
-	open:		misc_open,
+	.owner		= THIS_MODULE,
+	.open		= misc_open,
 };
 
 
drivers/char/mixcomwd.c renamed from drivers/char/mixcomwd.c.old +5 -5
@@ -177,11 +177,11 @@
 
 static struct file_operations mixcomwd_fops=
 {
-	owner:		THIS_MODULE,
-	write:		mixcomwd_write,
-	ioctl:		mixcomwd_ioctl,
-	open:		mixcomwd_open,
-	release:	mixcomwd_release,
+	.owner		= THIS_MODULE,
+	.write		= mixcomwd_write,
+	.ioctl		= mixcomwd_ioctl,
+	.open		= mixcomwd_open,
+	.release	= mixcomwd_release,
 };
 
 static struct miscdevice mixcomwd_miscdev=
drivers/char/nvram.c renamed from drivers/char/nvram.c.old +7 -7
@@ -438,13 +438,13 @@
 #endif /* CONFIG_PROC_FS */
 
 static struct file_operations nvram_fops = {
-	owner:		THIS_MODULE,
-	llseek:		nvram_llseek,
-	read:		nvram_read,
-	write:		nvram_write,
-	ioctl:		nvram_ioctl,
-	open:		nvram_open,
-	release:	nvram_release,
+	.owner		= THIS_MODULE,
+	.llseek		= nvram_llseek,
+	.read		= nvram_read,
+	.write		= nvram_write,
+	.ioctl		= nvram_ioctl,
+	.open		= nvram_open,
+	.release	= nvram_release,
 };
 
 static struct miscdevice nvram_dev = {
drivers/char/nwbutton.c renamed from drivers/char/nwbutton.c.old +2 -2
@@ -183,8 +183,8 @@
  */
 
 static struct file_operations button_fops = {
-	owner:		THIS_MODULE,
-	read:		button_read,
+	.owner		= THIS_MODULE,
+	.read		= button_read,
 };
 
 /* 
drivers/char/nwflash.c renamed from drivers/char/nwflash.c.old +5 -5
@@ -652,11 +652,11 @@
 
 static struct file_operations flash_fops =
 {
-	owner:		THIS_MODULE,
-	llseek:		flash_llseek,
-	read:		flash_read,
-	write:		flash_write,
-	ioctl:		flash_ioctl,
+	.owner		= THIS_MODULE,
+	.llseek		= flash_llseek,
+	.read		= flash_read,
+	.write		= flash_write,
+	.ioctl		= flash_ioctl,
 };
 
 static struct miscdevice flash_miscdev =
drivers/char/pcwd.c renamed from drivers/char/pcwd.c.old +6 -6
@@ -540,12 +540,12 @@
 }
 
 static struct file_operations pcwd_fops = {
-	owner:		THIS_MODULE,
-	read:		pcwd_read,
-	write:		pcwd_write,
-	ioctl:		pcwd_ioctl,
-	open:		pcwd_open,
-	release:	pcwd_close,
+	.owner		= THIS_MODULE,
+	.read		= pcwd_read,
+	.write		= pcwd_write,
+	.ioctl		= pcwd_ioctl,
+	.open		= pcwd_open,
+	.release	= pcwd_close,
 };
 
 static struct miscdevice pcwd_miscdev = {
drivers/char/ppdev.c renamed from drivers/char/ppdev.c.old +8 -8
@@ -739,14 +739,14 @@
 }
 
 static struct file_operations pp_fops = {
-	owner:		THIS_MODULE,
-	llseek:		no_llseek,
-	read:		pp_read,
-	write:		pp_write,
-	poll:		pp_poll,
-	ioctl:		pp_ioctl,
-	open:		pp_open,
-	release:	pp_release,
+	.owner		= THIS_MODULE,
+	.llseek		= no_llseek,
+	.read		= pp_read,
+	.write		= pp_write,
+	.poll		= pp_poll,
+	.ioctl		= pp_ioctl,
+	.open		= pp_open,
+	.release	= pp_release,
 };
 
 static devfs_handle_t devfs_handle;
drivers/char/qtronix.c renamed from drivers/char/qtronix.c.old +6 -6
@@ -568,12 +568,12 @@
 }
 
 struct file_operations psaux_fops = {
-	read:		read_aux,
-	write:		write_aux,
-	poll:		aux_poll,
-	open:		open_aux,
-	release:	release_aux,
-	fasync:		fasync_aux,
+	.read		= read_aux,
+	.write		= write_aux,
+	.poll		= aux_poll,
+	.open		= open_aux,
+	.release	= release_aux,
+	.fasync		= fasync_aux,
 };
 
 /*
drivers/char/random.c renamed from drivers/char/random.c.old +7 -7
@@ -1674,16 +1674,16 @@
 }
 
 struct file_operations random_fops = {
-	read:		random_read,
-	write:		random_write,
-	poll:		random_poll,
-	ioctl:		random_ioctl,
+	.read		= random_read,
+	.write		= random_write,
+	.poll		= random_poll,
+	.ioctl		= random_ioctl,
 };
 
 struct file_operations urandom_fops = {
-	read:		urandom_read,
-	write:		random_write,
-	ioctl:		random_ioctl,
+	.read		= urandom_read,
+	.write		= random_write,
+	.ioctl		= random_ioctl,
 };
 
 /***************************************************************
drivers/char/riscom8.c renamed from drivers/char/riscom8.c.old +4 -4
@@ -102,16 +102,16 @@
 
 static struct riscom_board rc_board[RC_NBOARD] =  {
 	{
-		base:	RC_IOBASE1,
+		.base	= RC_IOBASE1,
 	},
 	{
-		base:	RC_IOBASE2,
+		.base	= RC_IOBASE2,
 	},
 	{
-		base:	RC_IOBASE3,
+		.base	= RC_IOBASE3,
 	},
 	{
-		base:	RC_IOBASE4,
+		.base	= RC_IOBASE4,
 	},
 };
 
drivers/char/rtc.c renamed from drivers/char/rtc.c.old +8 -8
@@ -775,16 +775,16 @@
  */
 
 static struct file_operations rtc_fops = {
-	owner:		THIS_MODULE,
-	llseek:		no_llseek,
-	read:		rtc_read,
+	.owner		= THIS_MODULE,
+	.llseek		= no_llseek,
+	.read		= rtc_read,
 #if RTC_IRQ
-	poll:		rtc_poll,
+	.poll		= rtc_poll,
 #endif
-	ioctl:		rtc_ioctl,
-	open:		rtc_open,
-	release:	rtc_release,
-	fasync:		rtc_fasync,
+	.ioctl		= rtc_ioctl,
+	.open		= rtc_open,
+	.release	= rtc_release,
+	.fasync		= rtc_fasync,
 };
 
 static struct miscdevice rtc_dev=
drivers/char/sbc60xxwdt.c renamed from drivers/char/sbc60xxwdt.c.old +7 -7
@@ -262,13 +262,13 @@
 }
 
 static struct file_operations wdt_fops = {
-	owner:		THIS_MODULE,
-	llseek:		no_llseek,
-	read:		fop_read,
-	write:		fop_write,
-	open:		fop_open,
-	release:	fop_close,
-	ioctl:		fop_ioctl
+	.owner		= THIS_MODULE,
+	.llseek		= no_llseek,
+	.read		= fop_read,
+	.write		= fop_write,
+	.open		= fop_open,
+	.release	= fop_close,
+	.ioctl		= fop_ioctl
 };
 
 static struct miscdevice wdt_miscdev = {
drivers/char/scx200_wdt.c renamed from drivers/char/scx200_wdt.c.old +1 -1
@@ -128,7 +128,7 @@
 
 static struct notifier_block scx200_wdt_notifier =
 {
-        notifier_call: scx200_wdt_notify_sys
+        .notifier_call = scx200_wdt_notify_sys
 };
 
 static ssize_t scx200_wdt_write(struct file *file, const char *data, 
drivers/char/serial167.c renamed from drivers/char/serial167.c.old +6 -6
@@ -2827,12 +2827,12 @@
 
 
 static struct console sercons = {
-	name:		"ttyS",
-	write:		serial167_console_write,
-	device:		serial167_console_device,
-	setup:		serial167_console_setup,
-	flags:		CON_PRINTBUFFER,
-	index:		-1,
+	.name		= "ttyS",
+	.write		= serial167_console_write,
+	.device		= serial167_console_device,
+	.setup		= serial167_console_setup,
+	.flags		= CON_PRINTBUFFER,
+	.index		= -1,
 };
 
 
drivers/char/serial_tx3912.c renamed from drivers/char/serial_tx3912.c.old +16 -16
@@ -48,16 +48,16 @@
  * Used by generic serial driver to access hardware
  */
 static struct real_driver rs_real_driver = { 
-	disable_tx_interrupts: rs_disable_tx_interrupts, 
-	enable_tx_interrupts:  rs_enable_tx_interrupts, 
-	disable_rx_interrupts: rs_disable_rx_interrupts, 
-	enable_rx_interrupts:  rs_enable_rx_interrupts, 
-	get_CD:                rs_get_CD, 
-	shutdown_port:         rs_shutdown_port,  
-	set_real_termios:      rs_set_real_termios,  
-	chars_in_buffer:       rs_chars_in_buffer, 
-	close:                 rs_close, 
-	hungup:                rs_hungup,
+	.disable_tx_interrupts = rs_disable_tx_interrupts, 
+	.enable_tx_interrupts  = rs_enable_tx_interrupts, 
+	.disable_rx_interrupts = rs_disable_rx_interrupts, 
+	.enable_rx_interrupts  = rs_enable_rx_interrupts, 
+	.get_CD                = rs_get_CD, 
+	.shutdown_port         = rs_shutdown_port,  
+	.set_real_termios      = rs_set_real_termios,  
+	.chars_in_buffer       = rs_chars_in_buffer, 
+	.close                 = rs_close, 
+	.hungup                = rs_hungup,
 }; 
 
 /*
@@ -1046,12 +1046,12 @@
 }
 
 static struct console sercons = {
-	name:     "ttyS",
-	write:    serial_console_write,
-	device:   serial_console_device,
-	setup:    serial_console_setup,
-	flags:    CON_PRINTBUFFER,
-	index:    -1
+	.name     = "ttyS",
+	.write    = serial_console_write,
+	.device   = serial_console_device,
+	.setup    = serial_console_setup,
+	.flags    = CON_PRINTBUFFER,
+	.index    = -1
 };
 
 void __init tx3912_console_init(void)
drivers/char/sh-sci.c renamed from drivers/char/sh-sci.c.old +6 -6
@@ -1259,12 +1259,12 @@
 }
 
 static struct console sercons = {
-	name:		"ttySC",
-	write:		serial_console_write,
-	device:		serial_console_device,
-	setup:		serial_console_setup,
-	flags:		CON_PRINTBUFFER,
-	index:		-1,
+	.name		= "ttySC",
+	.write		= serial_console_write,
+	.device		= serial_console_device,
+	.setup		= serial_console_setup,
+	.flags		= CON_PRINTBUFFER,
+	.index		= -1,
 };
 
 /*
drivers/char/shwdt.c renamed from drivers/char/shwdt.c.old +6 -6
@@ -325,12 +325,12 @@
 }
 
 static struct file_operations sh_wdt_fops = {
-	owner:		THIS_MODULE,
-	read:		sh_wdt_read,
-	write:		sh_wdt_write,
-	ioctl:		sh_wdt_ioctl,
-	open:		sh_wdt_open,
-	release:	sh_wdt_close,
+	.owner		= THIS_MODULE,
+	.read		= sh_wdt_read,
+	.write		= sh_wdt_write,
+	.ioctl		= sh_wdt_ioctl,
+	.open		= sh_wdt_open,
+	.release	= sh_wdt_close,
 };
 
 static struct watchdog_info sh_wdt_info = {
drivers/char/softdog.c renamed from drivers/char/softdog.c.old +10 -10
@@ -68,7 +68,7 @@
 static void watchdog_fire(unsigned long);
 
 static struct timer_list watchdog_ticktock = {
-	function:	watchdog_fire,
+	.function	= watchdog_fire,
 };
 static int timer_alive;
 
@@ -140,7 +140,7 @@
 	unsigned int cmd, unsigned long arg)
 {
 	static struct watchdog_info ident = {
-		identity: "Software Watchdog",
+		.identity = "Software Watchdog",
 	};
 	switch (cmd) {
 		default:
@@ -159,17 +159,17 @@
 }
 
 static struct file_operations softdog_fops = {
-	owner:		THIS_MODULE,
-	write:		softdog_write,
-	ioctl:		softdog_ioctl,
-	open:		softdog_open,
-	release:	softdog_release,
+	.owner		= THIS_MODULE,
+	.write		= softdog_write,
+	.ioctl		= softdog_ioctl,
+	.open		= softdog_open,
+	.release	= softdog_release,
 };
 
 static struct miscdevice softdog_miscdev = {
-	minor:		WATCHDOG_MINOR,
-	name:		"watchdog",
-	fops:		&softdog_fops,
+	.minor		= WATCHDOG_MINOR,
+	.name		= "watchdog",
+	.fops		= &softdog_fops,
 };
 
 static char banner[] __initdata = KERN_INFO "Software Watchdog Timer: 0.06, soft_margin: %d sec, nowayout: %d\n";
drivers/char/sonypi.c renamed from drivers/char/sonypi.c.old +7 -7
@@ -613,13 +613,13 @@
 }
 
 static struct file_operations sonypi_misc_fops = {
-	owner:		THIS_MODULE,
-	read:		sonypi_misc_read,
-	poll:		sonypi_misc_poll,
-	open:		sonypi_misc_open,
-	release:	sonypi_misc_release,
-	fasync: 	sonypi_misc_fasync,
-	ioctl:		sonypi_misc_ioctl,
+	.owner		= THIS_MODULE,
+	.read		= sonypi_misc_read,
+	.poll		= sonypi_misc_poll,
+	.open		= sonypi_misc_open,
+	.release	= sonypi_misc_release,
+	.fasync 	= sonypi_misc_fasync,
+	.ioctl		= sonypi_misc_ioctl,
 };
 
 struct miscdevice sonypi_misc_device = {
drivers/char/stallion.c renamed from drivers/char/stallion.c.old +4 -4
@@ -170,8 +170,8 @@
  *	at 9600, 8 data bits, 1 stop bit.
  */
 static struct termios		stl_deftermios = {
-	c_cflag:	(B9600 | CS8 | CREAD | HUPCL | CLOCAL),
-	c_cc:		INIT_C_CC,
+	.c_cflag	= (B9600 | CS8 | CREAD | HUPCL | CLOCAL),
+	.c_cc		= INIT_C_CC,
 };
 
 /*
@@ -745,8 +745,8 @@
  *	to get at port stats - only not using the port device itself.
  */
 static struct file_operations	stl_fsiomem = {
-	owner:		THIS_MODULE,
-	ioctl:		stl_memioctl,
+	.owner		= THIS_MODULE,
+	.ioctl		= stl_memioctl,
 };
 
 /*****************************************************************************/
drivers/char/sx.c renamed from drivers/char/sx.c.old +2 -2
@@ -419,8 +419,8 @@
  */
 
 static struct file_operations sx_fw_fops = {
-	owner:		THIS_MODULE,
-	ioctl:		sx_fw_ioctl,
+	.owner		= THIS_MODULE,
+	.ioctl		= sx_fw_ioctl,
 };
 
 static struct miscdevice sx_fw_device = {
drivers/char/synclink.c renamed from drivers/char/synclink.c.old +4 -4
@@ -932,10 +932,10 @@
 MODULE_LICENSE("GPL");
 
 static struct pci_driver synclink_pci_driver = {
-	name:		"synclink",
-	id_table:	synclink_pci_tbl,
-	probe:		synclink_init_one,
-	remove:		__devexit_p(synclink_remove_one),
+	.name		= "synclink",
+	.id_table	= synclink_pci_tbl,
+	.probe		= synclink_init_one,
+	.remove		= __devexit_p(synclink_remove_one),
 };
 
 static struct tty_driver serial_driver, callout_driver;
drivers/char/synclinkmp.c renamed from drivers/char/synclinkmp.c.old +4 -4
@@ -517,10 +517,10 @@
 MODULE_LICENSE("GPL");
 
 static struct pci_driver synclinkmp_pci_driver = {
-	name:		"synclinkmp",
-	id_table:	synclinkmp_pci_tbl,
-	probe:		synclinkmp_init_one,
-	remove:		__devexit_p(synclinkmp_remove_one),
+	.name		= "synclinkmp",
+	.id_table	= synclinkmp_pci_tbl,
+	.probe		= synclinkmp_init_one,
+	.remove		= __devexit_p(synclinkmp_remove_one),
 };
 
 
drivers/char/sysrq.c renamed from drivers/char/sysrq.c.old +36 -36

142 lines not on this page · raw message

drivers/char/tipar.c renamed from drivers/char/tipar.c.old +7 -7
@@ -381,13 +381,13 @@
 /* ----- kernel module registering ------------------------------------ */
 
 static struct file_operations tipar_fops = {
-	owner:THIS_MODULE,
-	llseek:no_llseek,
-	read:tipar_read,
-	write:tipar_write,
-	ioctl:tipar_ioctl,
-	open:tipar_open,
-	release:tipar_close,
+	.owner = THIS_MODULE,
+	.llseek = no_llseek,
+	.read = tipar_read,
+	.write = tipar_write,
+	.ioctl = tipar_ioctl,
+	.open = tipar_open,
+	.release = tipar_close,
 };
 
 /* --- initialisation code ------------------------------------- */
drivers/char/toshiba.c renamed from drivers/char/toshiba.c.old +2 -2
@@ -91,8 +91,8 @@
 
 
 static struct file_operations tosh_fops = {
-	owner:		THIS_MODULE,
-	ioctl:		tosh_ioctl,
+	.owner		= THIS_MODULE,
+	.ioctl		= tosh_ioctl,
 };
 
 static struct miscdevice tosh_device = {
drivers/char/tpqic02.c renamed from drivers/char/tpqic02.c.old +7 -7
@@ -2565,13 +2565,13 @@
 
 /* These are (most) of the interface functions: */
 static struct file_operations qic02_tape_fops = {
-	owner:THIS_MODULE,
-	llseek:no_llseek,
-	read:qic02_do_tape_read,
-	write:qic02_do_tape_write,
-	ioctl:qic02_do_tape_ioctl,
-	open:qic02_tape_open,
-	release:qic02_tape_release,
+	.owner = THIS_MODULE,
+	.llseek = no_llseek,
+	.read = qic02_do_tape_read,
+	.write = qic02_do_tape_write,
+	.ioctl = qic02_do_tape_ioctl,
+	.open = qic02_tape_open,
+	.release = qic02_tape_release,
 };
 
 
drivers/char/tty_io.c renamed from drivers/char/tty_io.c.old +14 -14
@@ -404,23 +404,23 @@
 }
 
 static struct file_operations tty_fops = {
-	llseek:		no_llseek,
-	read:		tty_read,
-	write:		tty_write,
-	poll:		tty_poll,
-	ioctl:		tty_ioctl,
-	open:		tty_open,
-	release:	tty_release,
-	fasync:		tty_fasync,
+	.llseek		= no_llseek,
+	.read		= tty_read,
+	.write		= tty_write,
+	.poll		= tty_poll,
+	.ioctl		= tty_ioctl,
+	.open		= tty_open,
+	.release	= tty_release,
+	.fasync		= tty_fasync,
 };
 
 static struct file_operations hung_up_tty_fops = {
-	llseek:		no_llseek,
-	read:		hung_up_tty_read,
-	write:		hung_up_tty_write,
-	poll:		hung_up_tty_poll,
-	ioctl:		hung_up_tty_ioctl,
-	release:	tty_release,
+	.llseek		= no_llseek,
+	.read		= hung_up_tty_read,
+	.write		= hung_up_tty_write,
+	.poll		= hung_up_tty_poll,
+	.ioctl		= hung_up_tty_ioctl,
+	.release	= tty_release,
 };
 
 /*
drivers/char/vc_screen.c renamed from drivers/char/vc_screen.c.old +4 -4
@@ -464,10 +464,10 @@
 }
 
 static struct file_operations vcs_fops = {
-	llseek:		vcs_lseek,
-	read:		vcs_read,
-	write:		vcs_write,
-	open:		vcs_open,
+	.llseek		= vcs_lseek,
+	.read		= vcs_read,
+	.write		= vcs_write,
+	.open		= vcs_open,
 };
 
 static devfs_handle_t devfs_handle;
drivers/char/vme_scc.c renamed from drivers/char/vme_scc.c.old +6 -6
@@ -1094,12 +1094,12 @@
 
 
 static struct console sercons = {
-	name:		"ttyS",
-	write:		scc_console_write,
-	device:		scc_console_device,
-	setup:		scc_console_setup,
-	flags:		CON_PRINTBUFFER,
-	index:		-1,
+	.name		= "ttyS",
+	.write		= scc_console_write,
+	.device		= scc_console_device,
+	.setup		= scc_console_setup,
+	.flags		= CON_PRINTBUFFER,
+	.index		= -1,
 };
 
 
drivers/char/vt.c renamed from drivers/char/vt.c.old +6 -6
@@ -2172,12 +2172,12 @@
 }
 
 struct console vt_console_driver = {
-	name:		"tty",
-	write:		vt_console_print,
-	device:		vt_console_device,
-	unblank:	unblank_screen,
-	flags:		CON_PRINTBUFFER,
-	index:		-1,
+	.name		= "tty",
+	.write		= vt_console_print,
+	.device		= vt_console_device,
+	.unblank	= unblank_screen,
+	.flags		= CON_PRINTBUFFER,
+	.index		= -1,
 };
 #endif
 
drivers/char/w83877f_wdt.c renamed from drivers/char/w83877f_wdt.c.old +7 -7
@@ -269,13 +269,13 @@
 }
 
 static struct file_operations wdt_fops = {
-	owner:		THIS_MODULE,
-	llseek:		no_llseek,
-	read:		fop_read,
-	write:		fop_write,
-	open:		fop_open,
-	release:	fop_close,
-	ioctl:		fop_ioctl
+	.owner		= THIS_MODULE,
+	.llseek		= no_llseek,
+	.read		= fop_read,
+	.write		= fop_write,
+	.open		= fop_open,
+	.release	= fop_close,
+	.ioctl		= fop_ioctl
 };
 
 static struct miscdevice wdt_miscdev = {
drivers/char/wdt.c renamed from drivers/char/wdt.c.old +7 -7
@@ -438,13 +438,13 @@
  
  
 static struct file_operations wdt_fops = {
-	owner:		THIS_MODULE,
-	llseek:		no_llseek,
-	read:		wdt_read,
-	write:		wdt_write,
-	ioctl:		wdt_ioctl,
-	open:		wdt_open,
-	release:	wdt_release,
+	.owner		= THIS_MODULE,
+	.llseek		= no_llseek,
+	.read		= wdt_read,
+	.write		= wdt_write,
+	.ioctl		= wdt_ioctl,
+	.open		= wdt_open,
+	.release	= wdt_release,
 };
 
 static struct miscdevice wdt_miscdev=
drivers/char/wdt285.c renamed from drivers/char/wdt285.c.old +5 -5
@@ -150,11 +150,11 @@
 
 static struct file_operations watchdog_fops=
 {
-	owner:		THIS_MODULE,
-	write:		watchdog_write,
-	ioctl:		watchdog_ioctl,
-	open:		watchdog_open,
-	release:	watchdog_release,
+	.owner		= THIS_MODULE,
+	.write		= watchdog_write,
+	.ioctl		= watchdog_ioctl,
+	.open		= watchdog_open,
+	.release	= watchdog_release,
 };
 
 static struct miscdevice watchdog_miscdev=
drivers/char/wdt977.c renamed from drivers/char/wdt977.c.old +5 -5
@@ -311,11 +311,11 @@
 
 static struct file_operations wdt977_fops=
 {
-	owner:		THIS_MODULE,
-	write:		wdt977_write,
-	ioctl:		wdt977_ioctl,
-	open:		wdt977_open,
-	release:	wdt977_release,
+	.owner		= THIS_MODULE,
+	.write		= wdt977_write,
+	.ioctl		= wdt977_ioctl,
+	.open		= wdt977_open,
+	.release	= wdt977_release,
 };
 
 static struct miscdevice wdt977_miscdev=
drivers/char/wdt_pci.c renamed from drivers/char/wdt_pci.c.old +11 -11
@@ -472,13 +472,13 @@
  
  
 static struct file_operations wdtpci_fops = {
-	owner:		THIS_MODULE,
-	llseek:		no_llseek,
-	read:		wdtpci_read,
-	write:		wdtpci_write,
-	ioctl:		wdtpci_ioctl,
-	open:		wdtpci_open,
-	release:	wdtpci_release,
+	.owner		= THIS_MODULE,
+	.llseek		= no_llseek,
+	.read		= wdtpci_read,
+	.write		= wdtpci_write,
+	.ioctl		= wdtpci_ioctl,
+	.open		= wdtpci_open,
+	.release	= wdtpci_release,
 };
 
 static struct miscdevice wdtpci_miscdev=
@@ -601,10 +601,10 @@
 
 
 static struct pci_driver wdtpci_driver = {
-	name:		"wdt-pci",
-	id_table:	wdtpci_pci_tbl,
-	probe:		wdtpci_init_one,
-	remove:		__devexit_p(wdtpci_remove_one),
+	.name		= "wdt-pci",
+	.id_table	= wdtpci_pci_tbl,
+	.probe		= wdtpci_init_one,
+	.remove		= __devexit_p(wdtpci_remove_one),
 };
 
 
Signature · 3 lines
They that can give up essential liberty to obtain a little temporary safety
deserve neither liberty nor safety.
 -- Benjamin Franklin, Historical Review of Pennsylvania, 1759