Recently, I have spent 3 working days on porting Android to our PXA270 HW platform
Brief Condition:
HW:
PXA270 with PCI and IDE support
SW:
Linux 2.6.21 source code with our own driver (for PCI & IDE)
Linux 2.6.23 source code with android patch
Method:
1. porting customized driver from 2.6.21 to 2.6.23
2. porting android patch to 2.6.21
First of all, I must to explain what Android Kernel require.
1. EABI support
config:
CONFIG_AEABI=y
2. Thumb support
config:
CONFIG_ARM_THUMB=y
3. OpenBinder (from PalmSource)
file:
drivers/binder, include/linux/binder*
config: CONFIG_BINDER
4. Android Special Device
file:
drivers/android, include/linux/android*
config:
CONFIG_ANDROID_POWER
CONFIG_ANDROID_POWER_STAT
CONFIG_ANDROID_LOGGER
It looks like porting android patch into 2.6.21 is more simple. Therefore, I decide to use the second method. After porting drivers/android/*, EABI and Thumb. I can see a red-dot on the screen. Then I start to porting the openbinder to get into the Android desktop.
There are a lot of web pages talking about porting the Android binary into ARM platform. The steps is copy system/, data/, etc/, /init. And Writing a startup script to start Android. You can find these information in http://benno.id.au/blog/, http://nemustech.blogspot.com/2007/12/android-porting-to-real-target-hw.html. After I do all of this, the android still block in
clock_gettime(CLOCK_MONOTONIC, {127, 101400000}) = 0clock_gettime(CLOCK_MONOTONIC, {127, 103070000}) = 0clock_gettime(CLOCK_MONOTONIC, {127, 104026000}) = 0futex(0x134ac, FUTEX_WAIT, -1, {4, 997000000}) = 0Finally, I found that my rootfs is jffs2, but jffs2 can't support mmap and /init will be failed. I put everything into the IDE hard disk and format as ext2 and BINGO!!!!!Here is a very useful reference discuss.
阅读(1478) | 评论(0) | 转发(0) |