Linux
在執行 utuLinux 的 ARM S3C2440 上無法打開初始控制台
我嘗試將 NFS 文件系統安裝到目標板 ARM s3C2440。我已經啟動了 NFS 服務和 portmap 服務。伺服器作業系統為 Ubuntu 10.04。我使用 minicom 與目標板通信。在伺服器的終端中,我輸入了命令:
showmount -e
Export list for android-desktop: /utuLinux2.6.24/s3c2440_recover *
所以NFS服務的配置是對的。Ubuntu上的目錄
/utuLinux2.6.24/s3c2440_recover
是我要掛載到目標板s3c2440的目錄。板上的作業系統是utuLinux。我打開了 ARM 板,在 utu-bootloader 提示符下,我bootargs
在啟動前設置了環境變數:
$setenv bootargs 'console=ttySAC0 root=/dev/nfs nfsroot=192.168.2.107:/utuLinux2.6.24/s3c2440_recover ip=192.168.2.213:192.168.2.1:192.168.2.1:255.255.255.0:www.yctek.com:eth0:off
$boot
但是在啟動時出現錯誤:
utu-bootloader=>>>setenv bootargs 'console=ttySAC0 root=/dev/nfs nfsroot=192.168.2.107:/utuLinux2.6.24/s3c2440_recover ip=192.168.2.213:192.168.2.1:192.168.' utu-bootloader=>>>boot NAND read: device 0 offset 0x60000, size 0x200000 Reading data from 0x25fe00 -- 100% complete. 2097152 bytes read: OK ## Booting image at 32000000 ... Image Name: Linux-2.6.24.4 Created: 2008-12-07 16:50:12 UTC Image Type: ARM Linux Kernel Image (uncompressed) Data Size: 1959328 Bytes = 1.9 MB Load Address: 30008000 Entry Point: 30008000 Verifying Checksum ... OK OK Starting kernel ... Uncompressing Linux.......................................................................................................................................... Linux version 2.6.24.4 (lili@lili-desktop) (gcc version 3.4.1) #121 Mon Dec 8 00:50:06 CST 2008 CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=c0007177 Machine: UTU2440 Memory policy: ECC disabled, Data cache writeback CPU S3C2440A (id 0x32440001) S3C244X: core 405.000 MHz, memory 101.250 MHz, peripheral 50.625 MHz S3C24XX Clocks, (c) 2004 Simtec Electronics CLOCK: Slow mode (1.500 MHz), fast, MPLL on, UPLL on CPU0: D VIVT write-back cache CPU0: I cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets CPU0: D cache: 16384 bytes, associativity 64, 32 byte lines, 8 sets Built 1 zonelists in Zone order, mobility grouping on. Total pages: 16256 Kernel command line: console=ttySAC0 root=/dev/nfs nfsroot=192.168.2.107:/utuLinux2.6.24/s3c2440_recover ip=192.168.2.213:192.168.2.1:192.168.2.1:255.255.25f irq: clearing pending ext status 00000300 irq: clearing subpending status 00000003 irq: clearing subpending status 00000002 PID hash table entries: 256 (order: 8, 1024 bytes) timer tcon=00500000, tcnt a4ca, tcfg 00000200,00000000, usec 00001e57 Console: colour dummy device 80x30 console [ttySAC0] enabled Dentry cache hash table entries: 8192 (order: 3, 32768 bytes) Inode-cache hash table entries: 4096 (order: 2, 16384 bytes) Memory: 64MB = 64MB total Memory: 60160KB available (3556K code, 727K data, 472K init) SLUB: Genslabs=11, HWalign=32, Order=0-1, MinObjects=4, CPUs=1, Nodes=1 Mount-cache hash table entries: 512 CPU: Testing write buffer coherency: ok net_namespace: 64 bytes NET: Registered protocol family 16 S3C2440: Initialising architecture S3C2440: IRQ Support S3C2440: Clock Support, DVS off S3C24XX DMA Driver, (c) 2003-2004,2006 Simtec Electronics DMA channel 0 at c4800000, irq 33 DMA channel 1 at c4800040, irq 34 DMA channel 2 at c4800080, irq 35 DMA channel 3 at c48000c0, irq 36 SCSI subsystem initialized usbcore: registered new interface driver usbfs usbcore: registered new interface driver hub usbcore: registered new device driver usb NET: Registered protocol family 2 IP route cache hash table entries: 1024 (order: 0, 4096 bytes) TCP established hash table entries: 2048 (order: 2, 16384 bytes) TCP bind hash table entries: 2048 (order: 1, 8192 bytes) TCP: Hash tables configured (established 2048 bind 2048) TCP reno registered NetWinder Floating Point Emulator V0.97 (double precision) NTFS driver 2.1.29 [Flags: R/W]. fuse init (API version 7.9) yaffs Dec 8 2008 00:45:24 Installing. io scheduler noop registered io scheduler cfq registered (default) Console: switching to colour frame buffer device 100x30 fb0: s3c2410fb frame buffer device GPIO L3 bus interface for S3C2440, installed utu2440 LED Driver v1.00 s3c2440-uart.0: s3c2410_serial0 at MMIO 0x50000000 (irq = 70) is a S3C2440 s3c2440-uart.1: s3c2410_serial1 at MMIO 0x50004000 (irq = 73) is a S3C2440 s3c2440-uart.2: s3c2410_serial2 at MMIO 0x50008000 (irq = 76) is a S3C2440 loop: module loaded nbd: registered device at major 43 dm9000 Ethernet Driver eth0: dm9000 at c4802300,c4804304 IRQ 53 MAC: 00:12:34:56:80:49 Linux video capture interface: v2.00 em28xx v4l2 driver version 0.0.1 loaded usbcore: registered new interface driver em28xx usbcore: registered new interface driver gspca drivers/media/video/gspca/gspca_core.c: gspca driver 00.60.00 registered et61x251: V4L2 driver for ET61X[12]51 PC Camera Controllers v1:1.09 usbcore: registered new interface driver et61x251 zc0301: V4L2 driver for ZC0301[P] Image Processor and Control Chip v1:1.10 usbcore: registered new interface driver zc0301 videodev: "vivi" has no release callback. Please fix your driver for proper sysfs support, see http://lwn.net/Articles/36850/ Video Technology Magazine Virtual Video Capture Board (Load status: 0) Driver 'sd' needs updating - please use bus_type methods S3C24XX NAND Driver, (c) 2004 Simtec Electronics s3c2440-nand s3c2440-nand: Tacls=1, 9ns Twrph0=4 39ns, Twrph1=1 9ns NAND device: Manufacturer ID: 0xec, Chip ID: 0x76 (Samsung NAND 64MiB 3,3V 8-bit) Scanning device for bad blocks Bad eraseblock 972 at 0x00f30000 Bad eraseblock 3615 at 0x0387c000 Creating 3 MTD partitions on "NAND 64MiB 3,3V 8-bit": 0x00000000-0x00060000 : "bootloader" 0x00060000-0x00260000 : "kernel" 0x00260000-0x03ffc000 : "root" s3c2410-ohci s3c2410-ohci: S3C24XX OHCI s3c2410-ohci s3c2410-ohci: new USB bus registered, assigned bus number 1 s3c2410-ohci s3c2410-ohci: irq 42, io mem 0x49000000 usb usb1: configuration #1 chosen from 1 choice hub 1-0:1.0: USB hub found hub 1-0:1.0: 2 ports detected Initializing USB Mass Storage driver... usb 1-1: new full speed USB device using s3c2410-ohci and address 2 usb 1-1: configuration #1 chosen from 1 choice hub 1-1:1.0: USB hub found hub 1-1:1.0: 4 ports detected usbcore: registered new interface driver usb-storage USB Mass Storage support registered. usbcore: registered new interface driver libusual mice: PS/2 mouse device common for all mice Initial utulinux 2440 Buttons driver! Todo: mknod c /dev/utu2440-buttons 252 0 s3c2440 TouchScreen successfully loaded input: s3c2440 TouchScreen as /devices/virtual/input/input0 S3C24XX RTC, (c) 2004,2006 Simtec Electronics s3c2410-rtc s3c2410-rtc: rtc disabled, re-enabling s3c2410-rtc s3c2410-rtc: rtc core: registered s3c as rtc0 i2c /dev entries driver s3c2440-i2c s3c2440-i2c: slave address 0x10 s3c2440-i2c s3c2440-i2c: bus frequency set to 98 KHz s3c2440-i2c s3c2440-i2c: i2c-0: S3C I2C adapter S3C2410 Watchdog Timer, (c) 2004 Simtec Electronics s3c2410-wdt s3c2410-wdt: watchdog inactive, reset disabled, irq enabled mapped channel 2 to 0 usbcore: registered new interface driver usbkbd drivers/hid/usbhid/usbkbd.c: :USB HID Boot Protocol keyboard driver usbcore: registered new interface driver usbmouse drivers/hid/usbhid/usbmouse.c: v1.6:USB HID Boot Protocol mouse driver We do iis iomap from here. mapped channel 10 to 2 mapped channel 9 to 1 Now we have successfully init dma resourse. UDA1341 audio driver for utu2440 has been initialized TCP cubic registered NET: Registered protocol family 1 NET: Registered protocol family 17 RPC: Registered udp transport module. RPC: Registered tcp transport module. s3c2410-rtc s3c2410-rtc: hctosys: invalid date/time eth0: link up, 10Mbps, half-duplex, lpa 0x0021 IP-Config: Complete: device=eth0, addr=192.168.2.213, mask=255.255.255.0, gw=192.168.2.1, host=www, domain=, nis-domain=yctek.com, bootserver=192.168.2.1, rootserver=192.168.2.107, rootpath= Looking up port of RPC 100003/2 on 192.168.2.107 Looking up port of RPC 100005/1 on 192.168.2.107 VFS: Mounted root (nfs filesystem). Freeing init memory: 472K Warning: unable to open an initial console. _ _ _ _ _ | |_ _ _ | | (_) _ __ _ _ __ __ | | | | | __| | | | | _____ | | | | | '_ \ | | | | \ \/ / | |_| | | |_ | |_| | |_____| | | | | | | | | | |_| | > < \__,_| \__| \__,_| |_| |_| |_| |_| \__,_| /_/\_\ http://www.utu.com.cn/utuLinux
如果它啟動成功,我可以輸入命令
mount /dev/mtdblock2 /mnt
,然後在目錄中/mnt
我可以看到 ARM 板的根目錄。但現在我無法控制控制台。我怎麼解決這個問題?
我無法訪問控制台,因為有關控制台的文件沒有寫入硬碟。我使用了命令
tar -xjvf utu-Linux2.6.24_for_utu2440_2008-10-08.tar.bz2 -C /utuLinux2.6.24/
發現
/dev/console
無法創建文件。所以我用sudo tar -xjvf utu-Linux2.6.24_for_utu2440_2008-10-08.tar.bz2 -C /utuLinux2.6.24/
並且文件被寫入磁碟。現在我可以訪問控制台了。