/* * arch/arm/mach-pxa/include/mach/uncompress.h * * Author: Nicolas Pitre * Copyright: (C) 2001 MontaVista Software Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ #include <linux/serial_reg.h> #include <asm/mach-types.h> #define FFUART_BASE (0x40100000) #define BTUART_BASE (0x40200000) #define STUART_BASE (0x40700000) unsigned long uart_base; unsigned int uart_shift; unsigned int uart_is_pxa; static inline unsigned char uart_read(int offset) { return *(volatile unsigned char *)(uart_base + (offset << uart_shift)); } static inline void uart_write(unsigned char val, int offset) { *(volatile unsigned char *)(uart_base + (offset << uart_shift)) = val; } static inline int uart_is_enabled(void) { /* assume enabled by default for non-PXA uarts */ return uart_is_pxa ? uart_read(UART_IER) & UART_IER_UUE : 1; } static inline void putc(char c) { if (!uart_is_enabled()) return; while (!(uart_read(UART_LSR) & UART_LSR_THRE)) barrier(); uart_write(c, UART_TX); } /* * This does not append a newline */ static inline void flush(void) { } static inline void arch_decomp_setup(void) { /* initialize to default */ uart_base = FFUART_BASE; uart_shift = 2; uart_is_pxa = 1; if (machine_is_littleton() || machine_is_intelmote2() || machine_is_csb726() || machine_is_stargate2() || machine_is_cm_x300() || machine_is_balloon3()) uart_base = STUART_BASE; if (machine_is_arcom_zeus()) { uart_base = 0x10000000; /* nCS4 */ uart_shift = 1; uart_is_pxa = 0; } }
Name | Type | Size | Permission | Actions |
---|---|---|---|---|
addr-map.h | File | 1.41 KB | 0644 |
|
audio.h | File | 955 B | 0644 |
|
balloon3.h | File | 6.38 KB | 0644 |
|
bitfield.h | File | 2.81 KB | 0644 |
|
corgi.h | File | 4.72 KB | 0644 |
|
dma.h | File | 528 B | 0644 |
|
eseries-gpio.h | File | 1.85 KB | 0644 |
|
generic.h | File | 27 B | 0644 |
|
hardware.h | File | 6.68 KB | 0644 |
|
hx4700.h | File | 4.96 KB | 0644 |
|
io.h | File | 397 B | 0644 |
|
irqs.h | File | 4.94 KB | 0644 |
|
lubbock.h | File | 1.92 KB | 0644 |
|
magician.h | File | 4.24 KB | 0644 |
|
mainstone.h | File | 6.46 KB | 0644 |
|
mfp.h | File | 515 B | 0644 |
|
mtd-xip.h | File | 1.27 KB | 0644 |
|
palmld.h | File | 3 KB | 0644 |
|
palmtc.h | File | 2.47 KB | 0644 |
|
palmtx.h | File | 3.31 KB | 0644 |
|
poodle.h | File | 3.2 KB | 0644 |
|
pxa25x-udc.h | File | 0 B | 0644 |
|
pxa2xx-regs.h | File | 8.83 KB | 0644 |
|
pxa3xx-regs.h | File | 8.73 KB | 0644 |
|
regs-ac97.h | File | 4.47 KB | 0644 |
|
regs-lcd.h | File | 9 KB | 0644 |
|
regs-ost.h | File | 1.28 KB | 0644 |
|
regs-uart.h | File | 7.55 KB | 0644 |
|
reset.h | File | 717 B | 0644 |
|
smemc.h | File | 4.14 KB | 0644 |
|
spitz.h | File | 8.33 KB | 0644 |
|
tosa.h | File | 7.48 KB | 0644 |
|
trizeps4.h | File | 5.04 KB | 0644 |
|
uncompress.h | File | 1.62 KB | 0644 |
|
vpac270.h | File | 994 B | 0644 |
|
z2.h | File | 932 B | 0644 |
|