staging: panel: Use designated initializers
authorMariusz Gorski <marius.gorski@gmail.com>
Wed, 29 Oct 2014 22:32:30 +0000 (23:32 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 29 Oct 2014 23:28:17 +0000 (16:28 -0700)
Fix "warning: missing initializer [-Wmissing-field-initializers]"
by using designated struct initializers.

Signed-off-by: Mariusz Gorski <marius.gorski@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/panel/panel.c

index 6d1a320..98556ce 100644 (file)
@@ -1375,9 +1375,9 @@ static const struct file_operations lcd_fops = {
 };
 
 static struct miscdevice lcd_dev = {
-       LCD_MINOR,
-       "lcd",
-       &lcd_fops
+       .minor  = LCD_MINOR,
+       .name   = "lcd",
+       .fops   = &lcd_fops,
 };
 
 /* public function usable from the kernel for any purpose */
@@ -1652,9 +1652,9 @@ static const struct file_operations keypad_fops = {
 };
 
 static struct miscdevice keypad_dev = {
-       KEYPAD_MINOR,
-       "keypad",
-       &keypad_fops
+       .minor  = KEYPAD_MINOR,
+       .name   = "keypad",
+       .fops   = &keypad_fops,
 };
 
 static void keypad_send_key(const char *string, int max_len)