1. Create a new kernel folder to store kernel files
[Email protected] ~]$ mkdir kernel
2. Enter the kernel, upload the compression and unzip the compressed file
[[Email protected] ~] $CD kernel
[Email protected] kernel]$ TAR-XJF linux-3.0.tar.bz2
3. Enter linux-3.0
CD linux-3.0
4. Modify makefile, configure CPU type and cross compiler (195,196 rows)
ARCH =arm.
Cross_compile? =/opt/buildroot-2012.08/arm926t/usr/bin/arm-linux-
Cross compiler path Everyone is not the same, everyone to change the path to their own, and in the configuration of cross-compiler path, do not add extra space, otherwise the compiler will not be found.
Add Zimage header production under the same file (559 lines later)
CP Arch/arm/boot/zimage. -F
.. /u-boot-2010.09.bak/tools/mkimage-a arm-o linux-t kernel-c none-a 30008000
-E 30008040-n "Linux Kernel"-D zimage Linux-s3c2440-kernel.bin
Rm-f Zimage
(-a specifies the architecture of the CPU
-o Specifies the operating system type, which can take the following values:
OpenBSD, NetBSD, FreeBSD, 4_4bsd, Linux, SVR4, Esix, Solaris, IRIX, SCO, Dell, NCR, LynxOS, VxWorks, PSOs, QNX, U-boot, Rtems, Artos
-t specifies the image type and can take the following values:
Standalone, kernel, RAMDisk, multi, firmware, script, filesystem
-C Specify image compression mode
-a specifies the image to load the address in memory, when the image is downloaded into memory, the address value specified by this parameter is downloaded when the image is made with mkimage.
-e Specifies the address of the entry point for the image run, which is the value specified by the-a parameter plus 0x40 (because there is a header with a mkimage added 0x40 bytes in front)
-n Specifies the image name
-d Specifies the source file to make the image
The segment is in front of the Linux-compiled kernel, plus a 64-byte header, allowing U-boot to boot the kernel
5. We use s3c2410 as the template to make the s3c2440 kernel.
Copy Arch/arm/configs/s3c2410_defconfig as a template for. config
[email protected] linux-3.0]$ sudo cp arch/arm/configs/s3c2410_defconfig.
Note "." is copied to the current directory
6.make Menuconfig
(If make Menuconfig is garbled or cannot delete the path for modification, then you did not execute the export term=vt100 before you executed Menuconfig)
Linux/arm 3.0.0 Kernel Configuration
General Setup--->
All m-> N (* represents compiled into the kernel, M is compiled into a module, n is not selected)
[*] Enable loadable Module Support--->
-*-Enable The block layer--->
[] Support for Large (2tb+) block devices and files
System Type--->
[*] mmu-based Paged Memory Management Support
ARM system Type (Samsung s3c2410, s3c2412, s3c2413, s3c2416, s3c2440, s3c
(X) Samsung s3c2410, s3c2412, s3c2413, s3c2416, s3c2440, s3c2442
s3c2440 and s3c2442 Machines--->
[*] SMDK2440
[*] SMDK2440 with s3c2440 CPU module (NEW)
Kernel Features--->
[*] Use the ARM EABI to compile the kernel
Boot Options--->
() Default Kernel command string
Consel=ttysac0,115200,init=/init
Userspace binary Formats--->
[*] Kernel Support for ELF binaries
-*-Networking Support--->
M-N
Device Drivers--->
< > Parallel Port Support--->
[*] Block Devices--->
<*> Network block Device support
(1024x768) Default number of RAM disks
(204800) Default RAM disk size (Kbytes)
The other, m->n.
SCSI Device Support--->
M->n
[*] Network Device Support--->
[*] Ethernet (100Mbit)--->
<*> DM9000 Support
[]wireless LAN Wireless card is not selected first
Input Device Support--->
Input device support] (including mouse keyboard touch screen (event interface)) *-->n (not supported only left the serial port)
Character Devices--->
Serial Drivers--->
<*> Samsung SoC Serial Support
[*] Support for console on Samsung SoC serial port
<*> Samsung s3c2440/s3c2442/s3c2416 Serial Port Support (NEW)
< > Hardware Random number Generator Core support
< > Hardware monitoring Support--->
<*> sound card support--->
< > Advanced Linux sound Architecture--->
[] Multifunction device Drivers--->
[] HID Devices--->
[*] USB Support--->
<*> USB Mass Storage Support
<*> USB Serial Converter Support--->
<*> USB FTDI Single port Serial Driver USB to serial port driver
<*> USB Prolific 2303 single Port Serial Driver PL2303 Drive
<*> USB winchiphead CH341 single Port Serial Driver
<*> Mmc/sd/sdio Card Support--->
<*> Secure Digital Host Controller Interface Support
File Systems--->
The first 4 systems generally do not use n
Cd-rom/dvd filesystems--->
< > ISO 9660 CDROM File system support
M-->n
DOS/FAT/NT filesystems--->
<M> MSDOS FS Support
<*> VFAT (Windows-95) FS Support
(437) Default codepage for FAT
(ASCII) Default Iocharset for FAT
<*> NTFS File System support
[] NTFS Debugging support (NEW)
[*] NTFS Write support
Pseudo filesystems---> Pseudo file system
[*] [Tmpfs POSIX Access Control Lists] takes a piece of memory out of the file system (lost power loss) and must be
[*] Miscellaneous filesystems--->
<*> journalling Flash File System v2 (JFFS2) support
[*] Network File Systems--->
<*> NFS Client Support
[Kernel hacking] do not select n
[Cryptographic API] Encryption related not select n
[Library routines] Dynamic library not selected
7. Modify the clock and serial port
Modify the clock initialization in the __init Smdk2440_map_io () function in arch/arm/mach-s3c2440/mach-smdk2440.c to 12MHz:
S3c24xx_init_clocks (12000000);
8. Set the DRIVERS/TTY/SERIAL/SAMSUNG.C as follows:
#define S3C24XX_SERIAL_NAME "TTYs"
Set the. Driver_name in the Uart_driver s3c24xx_uart_drv structure to the following
. driver_name = "TTYs",
8. Modify the Arch/arm/tools/mach-types to configure the machine_id as follows
s3c2440 arch_s3c2440 s3c2440 1999
mini2440 mach_mini2440 MINI2440 362
9. Start compiling: Make
After compiling, download the Linxurom-s3c2440.bin to the 30008000 address of the Development Board and start
linux-3.0 Kernel porting