android kernel和标准linux kernel的区别

将从google 官网(http://code.google.com/p/android/downloads/list )下载的AndroidLinux Kernel 和标准的Linux 2.6.25 版本的Kernel 比较,Android 系统的Kernel 主要增加如下内容“

1. 基于 ARM 架构增加 Gold-Fish 平台 , 相应增加的目录如下 :
kernel/arch/arm/mach-goldfish
kernel/include/asm-arm/arch-goldfish

Gold-Fish 平台采用的是 ARM926T CPU 作为 BaseBand 处理器 , CPU 主频至少为 200MHZ. 而要流畅运行Android 系统的CPU 主频至少要在400MHZ 以上,也就是说如果你要上Android 系统,最好是选用基于ARM11 及以上平台进行开发。

2. 增加了 yaffs2 FLASH 文件系统 , 增加的目录为 :kernel/fs/yaffs2
实际上, Android 包经过编译后生成的 system.img ramdisk.img 文件就 yaffs2 格式的包 .

3. 增加了 Android 的相关 Driver, 相应目录为 :
kernel/drivers/android

主要分为 :
Android IPC 系统 : Binder
Android 日志系统 : Logger
Android 电源管理 : Power
Android 闹钟管理 : Alarm
Android 内存控制台 : Ram_console
Android 时钟控制的 gpio: Timed_gpio

4. 增加了 switch 处理 , 相应的目录为 :kernel/drivers/switch/

5. 增加了一种新的共享内存处理方式 , 相应增加的文件为 :kernel/mm/ashmem.c

6. 其他为 Linux-2.6.25 内核所做的补丁等等,例如 BlueTooth,

另外 GoldFish 平台相关的驱动文件如下 :

1. 字符输出设备 :
kernel/drivers/char/goldfish_tty.c

2. 图象显示设备 : (Frame Buffer)
kernel/drivers/video/goldfishfb.c

3. 键盘输入设备 :
kernel/drivers/input/keyboard/goldfish_events.c

4. RTC 设备 : (Real Time Clock)
kernel/drivers/rtc/rtc-goldfish.c

5. USB Device 设备 :
kernel/drivers/usb/gadget/android_adb.c

6. SD 卡设备 :
kernel/drivers/mmc/host/goldfish.c

7. FLASH 设备 :
kernel/drivers/mtd/devices/goldfish_nand.c
kernel/drivers/mtd/devices/goldfish_nand_reg.h

8. LED 设备 :
kernel/drivers/leds/ledtrig-sleep.c

9. 电源设备 :
kernel/drivers/power/goldfish_battery.c

10. 音频设备 :
kernel/arch/arm/mach-goldfish/audio.c

11. 电源管理 :
kernel/arch/arm/mach-goldfish/pm.c

12. 时钟管理 :
kernel/arch/arm/mach-goldfish/timer.c

下面一段摘自http://www.kandroid.org/android_pdk/intro_source_code.html

Linux Kernel

The Android Linux kernel includes enhancements to the Linux 2.6 kernel that provide additional drivers to support the Android platform, including:

  • Binder: an OpenBinder-based driver to facilitate inter-process communication (IPC) in the Android platform.
  • Android Power Management: a light weight power management driver built on top of standard Linux power management but optimized for embedded systems.
  • Low Memory Killer: Based on hints from the userspace, the low memory killer can kill off processes to free up memory as necessary. It is designed to provide more flexibility than the Out Of Memory (OOM) killer in the standard kernel.
  • Logger: A light weight logging device used to capture system, radio, logdata, etc.
  • USB Gadget: Uses the USB function framework.
  • Android/PMEM: The PMEM (physical memory) driver is used to provide contiguous physical memory regions to userspace libraries that interact with the digital signal processor (DSP) and other hardware that cannot cope with scatter-gather.
  • Android Alarm: A driver which provides timers that can wake the device up from sleep and a monotonic timebase that runs while the device is asleep.

Look for Android-specific enhancements in the following directories:

  • /drivers/android
  • /drivers/misc
  • /include/linux

 

你可能感兴趣的:(7_Android)