diff options
Diffstat (limited to 'arch/ppc/boot/common')
| -rw-r--r-- | arch/ppc/boot/common/ns16550.c | 8 | ||||
| -rw-r--r-- | arch/ppc/boot/common/util.S | 2 |
2 files changed, 6 insertions, 4 deletions
diff --git a/arch/ppc/boot/common/ns16550.c b/arch/ppc/boot/common/ns16550.c index 9017c547a6f6..26818bbb6cff 100644 --- a/arch/ppc/boot/common/ns16550.c +++ b/arch/ppc/boot/common/ns16550.c | |||
| @@ -23,7 +23,7 @@ static int shift; | |||
| 23 | 23 | ||
| 24 | unsigned long serial_init(int chan, void *ignored) | 24 | unsigned long serial_init(int chan, void *ignored) |
| 25 | { | 25 | { |
| 26 | unsigned long com_port; | 26 | unsigned long com_port, base_baud; |
| 27 | unsigned char lcr, dlm; | 27 | unsigned char lcr, dlm; |
| 28 | 28 | ||
| 29 | /* We need to find out which type io we're expecting. If it's | 29 | /* We need to find out which type io we're expecting. If it's |
| @@ -43,6 +43,8 @@ unsigned long serial_init(int chan, void *ignored) | |||
| 43 | 43 | ||
| 44 | /* How far apart the registers are. */ | 44 | /* How far apart the registers are. */ |
| 45 | shift = rs_table[chan].iomem_reg_shift; | 45 | shift = rs_table[chan].iomem_reg_shift; |
| 46 | /* Base baud.. */ | ||
| 47 | base_baud = rs_table[chan].baud_base; | ||
| 46 | 48 | ||
| 47 | /* save the LCR */ | 49 | /* save the LCR */ |
| 48 | lcr = inb(com_port + (UART_LCR << shift)); | 50 | lcr = inb(com_port + (UART_LCR << shift)); |
| @@ -62,9 +64,9 @@ unsigned long serial_init(int chan, void *ignored) | |||
| 62 | else { | 64 | else { |
| 63 | /* Input clock. */ | 65 | /* Input clock. */ |
| 64 | outb(com_port + (UART_DLL << shift), | 66 | outb(com_port + (UART_DLL << shift), |
| 65 | (BASE_BAUD / SERIAL_BAUD) & 0xFF); | 67 | (base_baud / SERIAL_BAUD) & 0xFF); |
| 66 | outb(com_port + (UART_DLM << shift), | 68 | outb(com_port + (UART_DLM << shift), |
| 67 | (BASE_BAUD / SERIAL_BAUD) >> 8); | 69 | (base_baud / SERIAL_BAUD) >> 8); |
| 68 | /* 8 data, 1 stop, no parity */ | 70 | /* 8 data, 1 stop, no parity */ |
| 69 | outb(com_port + (UART_LCR << shift), 0x03); | 71 | outb(com_port + (UART_LCR << shift), 0x03); |
| 70 | /* RTS/DTR */ | 72 | /* RTS/DTR */ |
diff --git a/arch/ppc/boot/common/util.S b/arch/ppc/boot/common/util.S index 47e641455bc5..c96c9f80521e 100644 --- a/arch/ppc/boot/common/util.S +++ b/arch/ppc/boot/common/util.S | |||
| @@ -252,7 +252,7 @@ _GLOBAL(flush_instruction_cache) | |||
| 252 | 1: dcbf r0,r3 # Flush the data cache | 252 | 1: dcbf r0,r3 # Flush the data cache |
| 253 | icbi r0,r3 # Invalidate the instruction cache | 253 | icbi r0,r3 # Invalidate the instruction cache |
| 254 | addi r3,r3,0x10 # Increment by one cache line | 254 | addi r3,r3,0x10 # Increment by one cache line |
| 255 | cmplwi cr0,r3,r4 # Are we at the end yet? | 255 | cmplw cr0,r3,r4 # Are we at the end yet? |
| 256 | blt 1b # No, keep flushing and invalidating | 256 | blt 1b # No, keep flushing and invalidating |
| 257 | #else | 257 | #else |
| 258 | /* Enable, invalidate and then disable the L1 icache/dcache. */ | 258 | /* Enable, invalidate and then disable the L1 icache/dcache. */ |
