]> pilppa.org Git - familiar-h63xx-build.git/blob - org.handhelds.familiar/packages/linux/linux-wrt-2.4.30/019-drivers_char_serial_c
OE tree imported from monotone branch org.openembedded.oz354fam083 at revision 8b12e3...
[familiar-h63xx-build.git] / org.handhelds.familiar / packages / linux / linux-wrt-2.4.30 / 019-drivers_char_serial_c
1 --- linux-mips-cvs/drivers/char/serial.c        2004-12-27 05:13:43.000000000 +0100
2 +++ linux-broadcom/drivers/char/serial.c        2005-01-31 13:13:14.000000000 +0100
3 @@ -444,6 +444,10 @@
4                 return inb(info->port+1);
5  #endif
6         case SERIAL_IO_MEM:
7 +#ifdef CONFIG_BCM4310
8 +               readb((unsigned long) info->iomem_base +
9 +                               (UART_SCR<<info->iomem_reg_shift));
10 +#endif
11                 return readb((unsigned long) info->iomem_base +
12                              (offset<<info->iomem_reg_shift));
13         default:
14 @@ -464,6 +468,9 @@
15         case SERIAL_IO_MEM:
16                 writeb(value, (unsigned long) info->iomem_base +
17                               (offset<<info->iomem_reg_shift));
18 +#ifdef CONFIG_BCM4704
19 +               *((volatile unsigned int *) KSEG1ADDR(0x18000000));
20 +#endif
21                 break;
22         default:
23                 outb(value, info->port+offset);
24 @@ -5996,6 +6003,13 @@
25          *      Divisor, bytesize and parity
26          */
27         state = rs_table + co->index;
28 +       /*
29 +        * Safe guard: state structure must have been initialized
30 +        */
31 +       if (state->iomem_base == NULL) {
32 +               printk("!unable to setup serial console!\n");
33 +               return -1;
34 +       }
35         if (doflow)
36                 state->flags |= ASYNC_CONS_FLOW;
37         info = &async_sercons;