免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 4882 | 回复: 2
打印 上一主题 下一主题

Linux启动控制台问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2008-03-13 15:23 |只看该作者 |倒序浏览
本人用cross-3.3.2(arm-linux)交叉编译工具编译linux2.6.11内核
并交叉编译了busybox-1.2.1。制作了一个Ramdisk

系统开始启动正常。
最后加在根文件系统中的/sbin/init初始化文件时
控制台没有反应。
但是输入信息能回显,回车也有作用。
但不能进shell
望高手给予解答?
Starting kernel ...

arch number =193
arch param addres =0x30000100
the kernel =0x30008000
Uncompressing Linux................................................................ done, booting the kernel.
Linux version 2.6.11 (root@localhost.localdomain) (gcc version 3.3.2) #234 Wed Mar 12 20:23:36 CST 2008
CPU: ARM920Tid(wb) [41129200] revision 0 (ARMv4T)
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
Machine: SMDK2410
Memory policy: ECC disabled, Data cache writeback
CPU S3C2410A (id 0x32410002)
S3C2410: core 202.800 MHz, memory 101.400 MHz, peripheral 50.700 MHz
S3C2410 Clock control, (c) 2004 Simtec Electronics
Built 1 zonelists
Kernel command line: root=/dev/ram0 console=ttySAC0,115200 initrd=0x30800000,5M init=/sbin/init
irq: clearing pending ext status 00000200
irq: clearing subpending status 00000002
PID hash table entries: 256 (order: 8, 4096 bytes)
timer tcon=00500000, tcnt a509, tcfg 00000200,00000000, usec 00001e4c
Console: colour dummy device 80x30
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory: 32MB = 32MB total
Memory: 25216KB available (1632K code, 322K data, 92K init)
Mount-cache hash table entries: 512 (order: 0, 4096 bytes)
CPU: Testing write buffer coherency: ok
checking if image is initramfs...it isn't (no cpio magic); looks like an initrd
Freeing initrd memory: 5120K
ralf here
NET: Registered protocol family 16
S3C2410: Initialising architecture
devfs: 2004-01-31 Richard Gooch (rgooch@atnf.csiro.au)
devfs: boot_options: 0x1
Console: switching to colour frame buffer device 80x25
fb0: Virtual frame buffer device, using 1024K of video memory
S3C2410 RTC, (c) 2004 Simtec Electronics
s3c2410_serial0 at MMIO 0x50000000 (irq = 70) is a S3C2410
s3c2410_serial1 at MMIO 0x50004000 (irq = 73) is a S3C2410
s3c2410_serial2 at MMIO 0x50008000 (irq = 76) is a S3C2410
io scheduler noop registered
io scheduler anticipatory registered
io scheduler deadline registered
io scheduler cfq registered
RAMDISK driver initialized: 16 RAM disks of 5120K size 1024 blocksize
S3C2410 NAND Driver, (c) 2004 Simtec Electronics
mice: PS/2 mouse device common for all mice
NET: Registered protocol family 2
IP: routing cache hash table of 512 buckets, 4Kbytes
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 204
NET: Registered protocol family 1
ralf init over
ralf flush scheduled work
in flush workqueue
RAMDISK: Compressed image found at block 0
VFS: Mounted root (ext2 filesystem).
Mounted devfs on /dev
ralf in init process
Freeing init memory: 92K
open /dev/console
the command line is : /sbin/init

尝试过在busybox init_main()函数开始打印printf("ralf in busybox\n";失败

论坛徽章:
0
2 [报告]
发表于 2008-03-13 20:37 |只看该作者
你确定console=ttySAC0没问题吗

论坛徽章:
0
3 [报告]
发表于 2008-03-15 17:06 |只看该作者

回复 #2 epegasus 的帖子

没有问题。
问题找到了,还是busybox有问题。
换了个编译器,arm-linux-3.4.1
重新编译linux-2.6.20 和 busybox-1.9.1通过。
设置inittable 能成功运行到shell
arch number =193
arch param addres =0x30000100
the kernel =0x30008000
Uncompressing Linux............................................................................................... done, booting the kernel.
Linux version 2.6.20 (root@localhost.localdomain) (gcc version 3.4.1) #5 Sat Mar 15 16:40:43 CST 2008
CPU: ARM920T [41129200] revision 0 (ARMv4T), cr=00007177
Machine: SMDK2410
Memory policy: ECC disabled, Data cache writeback
CPU S3C2410A (id 0x32410002)
S3C2410: core 202.800 MHz, memory 101.400 MHz, peripheral 50.700 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.  Total pages: 8128
Kernel command line: root=/dev/ram0 console=ttySAC0,115200 initrd=0x30800000,5M init=/linuxrc
irq: clearing pending ext status 00000200
irq: clearing subpending status 00000002
PID hash table entries: 128 (order: 7, 512 bytes)
timer tcon=00500000, tcnt a509, tcfg 00000200,00000000, usec 00001e4c
Console: colour dummy device 80x30
Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
Memory: 32MB = 32MB total
Memory: 24248KB available (2680K code, 279K data, 120K init)
Mount-cache hash table entries: 512
CPU: Testing write buffer coherency: ok
S3C24XX DMA Driver, (c) 2003-2004,2006 Simtec Electronics
Registering sysclass
DMA channel 0 at c2800000, irq 33
DMA channel 1 at c2800040, irq 34
DMA channel 2 at c2800080, irq 35
DMA channel 3 at c28000c0, irq 36
NET: Registered protocol family 16
S3C2410 Power Management, (c) 2004 Simtec Electronics
S3C2410: Initialising architecture
0:               xdreq0, channels 0---
1:               xdreq1, channels -1--
2:                  sdi, channels 0-23
3:                 spi0, channels -1--
4:                 spi1, channels ---3
5:                uart0, channels 0---
6:                uart1, channels -1--
7:                uart2, channels ---3
8:                timer, channels 0-23
9:              i2s-sdi, channels -12-
10:              i2s-sdo, channels --2-
11:               <NULL>, channels ----
12:               <NULL>, channels ----
13:               <NULL>, channels ----
14:              usb-ep1, channels 0---
15:              usb-ep2, channels -1--
16:              usb-ep3, channels --2-
17:              usb-ep4, channels ---3
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: 1024 (order: 0, 4096 bytes)
TCP bind hash table entries: 512 (order: -1, 2048 bytes)
TCP: Hash tables configured (established 1024 bind 512)
TCP reno registered
checking if image is initramfs...it isn't (no cpio magic); looks like an initrd
Freeing initrd memory: 5120K
NetWinder Floating Point Emulator V0.97 (double precision)
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler deadline registered
io scheduler cfq registered
s3c2410-lcd s3c2410-lcd: no platform data for lcd, cannot attach
s3c2410-lcd: probe of s3c2410-lcd failed with error -22
lp: driver loaded but no devices found
ppdev: user-space parallel port driver
S3C2410 Watchdog Timer, (c) 2004 Simtec Electronics
Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ sharing enabled
s3c2410-uart.0: s3c2410_serial0 at MMIO 0x50000000 (irq = 70) is a S3C2410
s3c2410-uart.1: s3c2410_serial1 at MMIO 0x50004000 (irq = 73) is a S3C2410
s3c2410-uart.2: s3c2410_serial2 at MMIO 0x50008000 (irq = 76) is a S3C2410
RAMDISK driver initialized: 16 RAM disks of 5120K size 1024 blocksize
loop: loaded (max 8 devices)
dm9000 Ethernet Driver
Uniform Multi-Platform E-IDE driver Revision: 7.00alpha2
ide: Assuming 50MHz system bus speed for PIO modes; override with idebus=xx
BAST NOR-Flash Driver, (c) 2004 Simtec Electronics
S3C24XX NAND Driver, (c) 2004 Simtec Electronics
s3c2410-nand s3c2410-nand: Tacls=3, 29ns Twrph0=7 69ns, Twrph1=3 29ns
NAND device: Manufacturer ID: 0xec, Chip ID: 0x76 (Samsung NAND 64MiB 3,3V 8-bit)
Scanning device for bad blocks
Creating 8 MTD partitions on "NAND 64MiB 3,3V 8-bit":
0x00000000-0x00004000 : "Boot Agent"
0x00000000-0x00200000 : "S3C2410 flash partition 1"
0x00400000-0x00800000 : "S3C2410 flash partition 2"
0x00800000-0x00a00000 : "S3C2410 flash partition 3"
0x00a00000-0x00e00000 : "S3C2410 flash partition 4"
0x00e00000-0x01800000 : "S3C2410 flash partition 5"
0x01800000-0x03000000 : "S3C2410 flash partition 6"
0x03000000-0x04000000 : "S3C2410 flash partition 7"
usbmon: debugfs is not available
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
mice: PS/2 mouse device common for all mice
S3C24XX RTC, (c) 2004,2006 Simtec Electronics
s3c2410-i2c s3c2410-i2c: slave address 0x10
s3c2410-i2c s3c2410-i2c: bus frequency set to 99 KHz
s3c2410-i2c s3c2410-i2c: i2c-0: S3C I2C adapter
TCP cubic registered
NET: Registered protocol family 1
drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
RAMDISK: Compressed image found at block 0
VFS: Mounted root (ext2 filesystem).
Freeing init memory: 120K
init started: BusyBox v1.9.1 (2008-03-14 19:53:19 CST)
starting pid 759, tty '': '/etc/init.d/rcS'
starting pid 761, tty '': '/sbin/getty'

#
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP