diff options
author | Alexey Zaytsev <alexey.zaytsev@gmail.com> | 2010-12-11 08:18:49 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2010-12-12 09:26:50 +0100 |
commit | adcebd48f6a4387354a099a3c20daac560e635dd (patch) | |
tree | d18d53f0519b86ba8e040bf93b286d4c112cc596 /arch/arm/mach-versatile/include/mach/debug_ll.h | |
parent | cebd35e4e89f35bd79409d68fdc92c53d6ea23e1 (diff) | |
download | barebox-adcebd48f6a4387354a099a3c20daac560e635dd.tar.gz barebox-adcebd48f6a4387354a099a3c20daac560e635dd.tar.xz |
Add basic support from ARM Versatile/PB
tested with qemu only
qemu-system-arm -M versatilepb -monitor null -kernel barebox -net nic -net user -tftp "<uImage-path>/" -serial stdio
add -nographic if you do not want the lcd via sdl
Signed-off-by: Alexey Zaytsev <alexey.zaytsev@gmail.com>
update:
- use default env
- move arm_timer.h as in the kernel
- add nor flash support
- udpate defconfig
- fix copyright copy from linux
- fix ARCH_TEXT_BASE
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-versatile/include/mach/debug_ll.h')
-rw-r--r-- | arch/arm/mach-versatile/include/mach/debug_ll.h | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/arch/arm/mach-versatile/include/mach/debug_ll.h b/arch/arm/mach-versatile/include/mach/debug_ll.h new file mode 100644 index 0000000000..514fcfb1a0 --- /dev/null +++ b/arch/arm/mach-versatile/include/mach/debug_ll.h @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2010 B Labs Ltd + * Author: Alexey Zaytsev <alexey.zaytsev@gmail.com> + * + * barebox is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * barebox is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with barebox. If not, see <http://www.gnu.org/licenses/>. + */ + +#ifndef __MACH_DEBUG_LL_H__ +#define __MACH_DEBUG_LL_H__ + +#include <linux/amba/serial.h> +#include <asm/io.h> + +static inline void putc(char c) +{ + /* Wait until there is space in the FIFO */ + while (readl(0x101F1000 + UART01x_FR) & UART01x_FR_TXFF); + + /* Send the character */ + writel(c, 0x101F1000 + UART01x_DR); + + /* Wait to make sure it hits the line, in case we die too soon. */ + while (readl(0x101F1000 + UART01x_FR) & UART01x_FR_TXFF); +} + +#endif |