2010年6月29日 星期二

Using the Low Level debug on kernel

Using the Low Level debug
a) Enable the Low Level debug in the menuconfig
Kernel hacking --->
[*] Kernel low-level debugging functions

b) Add the code (the red lines) in the file kernel/printk.c
extern void printch(char c);
static void emit_log_char(char c)
{
LOG_BUF(log_end) = c;
log_end++;
if (log_end - log_start > log_buf_len)
log_start = log_end - log_buf_len;
if (log_end - con_start > log_buf_len)
con_start = log_end - log_buf_len;
if (logged_chars < log_buf_len)
logged_chars++;
printch(c);
}
c) Use the new kernel, then you can get the uart info.
Note: if it cannot work, please make sure in the file -- include/asm-arm/arch-pxa/debug-macro.S, there is the right map for UART registers.

2010年6月25日 星期五

Android adb config

vi ~/.android/adb_usb.ini
Add vendor ID to this file (I forget which one is for marvell):
0x403
0x18d1

Restart adb:
sudo ./adb kill-server
sudo ./adb devices

mount nfs

#mount -t nfs 192.168.100.120:/export /tftpboot/nfs