diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/serial/serial.c | 19 | ||||
-rw-r--r-- | drivers/serial/serial_pxa.c | 16 | ||||
-rw-r--r-- | drivers/serial/serial_s3c24x0.c | 18 | ||||
-rw-r--r-- | drivers/serial/serial_s5p.c | 19 | ||||
-rw-r--r-- | drivers/serial/serial_xuartlite.c | 19 |
5 files changed, 47 insertions, 44 deletions
diff --git a/drivers/serial/serial.c b/drivers/serial/serial.c index b10bab7..9d92dee 100644 --- a/drivers/serial/serial.c +++ b/drivers/serial/serial.c @@ -106,15 +106,16 @@ static NS16550_t serial_ports[4] = { serial_puts_dev(port, s);} /* Serial device descriptor */ -#define INIT_ESERIAL_STRUCTURE(port, name) {\ - name,\ - eserial##port##_init,\ - NULL,\ - eserial##port##_setbrg,\ - eserial##port##_getc,\ - eserial##port##_tstc,\ - eserial##port##_putc,\ - eserial##port##_puts, } +#define INIT_ESERIAL_STRUCTURE(port, __name) { \ + .name = __name, \ + .start = eserial##port##_init, \ + .stop = NULL, \ + .setbrg = eserial##port##_setbrg, \ + .getc = eserial##port##_getc, \ + .tstc = eserial##port##_tstc, \ + .putc = eserial##port##_putc, \ + .puts = eserial##port##_puts, \ +} #endif /* CONFIG_SERIAL_MULTI */ diff --git a/drivers/serial/serial_pxa.c b/drivers/serial/serial_pxa.c index a9976d7..97e3f36 100644 --- a/drivers/serial/serial_pxa.c +++ b/drivers/serial/serial_pxa.c @@ -269,14 +269,14 @@ void pxa_puts_dev(unsigned int uart_index, const char *s) #define pxa_uart_desc(uart) \ struct serial_device serial_##uart##_device = \ { \ - "serial_"#uart, \ - uart##_init, \ - NULL, \ - uart##_setbrg, \ - uart##_getc, \ - uart##_tstc, \ - uart##_putc, \ - uart##_puts, \ + .name = "serial_"#uart, \ + .start = uart##_init, \ + .stop = NULL, \ + .setbrg = uart##_setbrg, \ + .getc = uart##_getc, \ + .tstc = uart##_tstc, \ + .putc = uart##_putc, \ + .puts = uart##_puts, \ }; #define pxa_uart_multi(uart, UART) \ diff --git a/drivers/serial/serial_s3c24x0.c b/drivers/serial/serial_s3c24x0.c index 12bcdd3..fa6aac0 100644 --- a/drivers/serial/serial_s3c24x0.c +++ b/drivers/serial/serial_s3c24x0.c @@ -69,15 +69,15 @@ DECLARE_GLOBAL_DATA_PTR; serial_puts_dev(port, s); \ } -#define INIT_S3C_SERIAL_STRUCTURE(port, name) { \ - name, \ - s3serial##port##_init, \ - NULL,\ - s3serial##port##_setbrg, \ - s3serial##port##_getc, \ - s3serial##port##_tstc, \ - s3serial##port##_putc, \ - s3serial##port##_puts, \ +#define INIT_S3C_SERIAL_STRUCTURE(port, __name) { \ + .name = __name, \ + .start = s3serial##port##_init, \ + .stop = NULL, \ + .setbrg = s3serial##port##_setbrg, \ + .getc = s3serial##port##_getc, \ + .tstc = s3serial##port##_tstc, \ + .putc = s3serial##port##_putc, \ + .puts = s3serial##port##_puts, \ } #endif /* CONFIG_SERIAL_MULTI */ diff --git a/drivers/serial/serial_s5p.c b/drivers/serial/serial_s5p.c index 6819bb0..43cbc4f 100644 --- a/drivers/serial/serial_s5p.c +++ b/drivers/serial/serial_s5p.c @@ -183,15 +183,16 @@ int s5p_serial##port##_tstc(void) { return serial_tstc_dev(port); } \ void s5p_serial##port##_putc(const char c) { serial_putc_dev(c, port); } \ void s5p_serial##port##_puts(const char *s) { serial_puts_dev(s, port); } -#define INIT_S5P_SERIAL_STRUCTURE(port, name) { \ - name, \ - s5p_serial##port##_init, \ - NULL, \ - s5p_serial##port##_setbrg, \ - s5p_serial##port##_getc, \ - s5p_serial##port##_tstc, \ - s5p_serial##port##_putc, \ - s5p_serial##port##_puts, } +#define INIT_S5P_SERIAL_STRUCTURE(port, __name) { \ + .name = __name, \ + .start = s5p_serial##port##_init, \ + .stop = NULL, \ + .setbrg = s5p_serial##port##_setbrg, \ + .getc = s5p_serial##port##_getc, \ + .tstc = s5p_serial##port##_tstc, \ + .putc = s5p_serial##port##_putc, \ + .puts = s5p_serial##port##_puts, \ +} DECLARE_S5P_SERIAL_FUNCTIONS(0); struct serial_device s5p_serial0_device = diff --git a/drivers/serial/serial_xuartlite.c b/drivers/serial/serial_xuartlite.c index 2bdb68b..b3bb066 100644 --- a/drivers/serial/serial_xuartlite.c +++ b/drivers/serial/serial_xuartlite.c @@ -144,15 +144,16 @@ int serial_tstc(void) { uartlite_serial_puts(s, port); } /* Serial device descriptor */ -#define INIT_ESERIAL_STRUCTURE(port, name) {\ - name,\ - userial##port##_init,\ - NULL,\ - userial##port##_setbrg,\ - userial##port##_getc,\ - userial##port##_tstc,\ - userial##port##_putc,\ - userial##port##_puts, } +#define INIT_ESERIAL_STRUCTURE(port, __name) { \ + .name = __name, \ + .start = userial##port##_init, \ + .stop = NULL, \ + .setbrg = userial##port##_setbrg, \ + .getc = userial##port##_getc, \ + .tstc = userial##port##_tstc, \ + .putc = userial##port##_putc, \ + .puts = userial##port##_puts, \ +} DECLARE_ESERIAL_FUNCTIONS(0); struct serial_device uartlite_serial0_device = |