[#4601] when pass bootargs console=null into kernel from u-boot, the booted up kernel can't be pinged through
Submitted By: Mingquan Pan
Open Date
2008-11-04 01:25:31 Close Date
2008-12-01 11:38:39
Priority:
Medium Assignee:
Sonic Zhang
Status:
Closed Fixed In Release:
N/A
Found In Release:
N/A Release:
Category:
N/A Board:
N/A
Processor:
N/A Silicon Revision:
Is this bug repeatable?:
Yes Resolution:
Fixed
Uboot version or rev.:
Toolchain version or rev.:
Oct 10
App binary format:
N/A
Summary: when pass bootargs console=null into kernel from u-boot, the booted up kernel can't be pinged through
Details:
when pass bootargs console=null into kernel from u-boot, the booted up kernel can't be pinged through.
This happens after the kernel is upgraded to 2.6.28.
bfin> boote
Loading .text @ 0x00001000 (1090880 bytes)
Loading .rodata @ 0x0010b540 (261576 bytes)
Loading .init.rodata @ 0x0014b308 (80 bytes)
Loading __ksymtab @ 0x0014b358 (15872 bytes)
Loading __ksymtab_gpl @ 0x0014f158 (5048 bytes)
Loading __ksymtab_strings @ 0x00150510 (46718 bytes)
Loading __init_rodata @ 0x0015bb90 (172 bytes)
Loading __param @ 0x0015bc3c (380 bytes)
Clearing .bss @ 0x0015bdc0 (65376 bytes)
Loading .data @ 0x0016bd20 (66272 bytes)
Loading .init.text @ 0x0017c000 (100616 bytes)
Loading .init.data @ 0x00194908 (13656 bytes)
Loading .init.setup @ 0x00197e60 (588 bytes)
Loading .initcall.init @ 0x001980ac (548 bytes)
Loading .con_initcall.init @ 0x001982d0 (4 bytes)
Loading .init.ramfs @ 0x001982d4 (3531229 bytes)
Loading .text_l1 @ 0xffa00000 (6976 bytes)
sh_addr: FFA00000, p_paddr: 004F64B1
Loading from: 024E8000 to 004F64B1, size: 6976
Loading .data_l1 @ 0xff800000 (224 bytes)
sh_addr: FF800000, p_paddr: 004F7FF1
Loading from: 024EA000 to 004F7FF1, size: 224
## Starting application at 0x0018a280 ...
Linux version 2.6.28-rc2-ADI-2009R1-pre-svn5576 (test@my-local-machine) (gcc version 4.1.2 (ADI svn)) #27 Tue Nov 4 14:24:07 CST 2008
console [early_BFuart0] enabled
early printk enabled on early_BFuart0
Warning: limiting memory to 56MB due to hardware anomaly 05000263
Board Memory: 64MB
Kernel Managed Memory: 64MB
Memory map:
fixedcode = 0x00000400-0x00000490
text = 0x00001000-0x0010b540
rodata = 0x0010b540-0x0015bdb8
bss = 0x0015bdc0-0x0016bd20
data = 0x0016bd20-0x0017c000
stack = 0x0017a000-0x0017c000
init = 0x0017c000-0x004f9000
available = 0x004f9000-0x037ff000
DMA Zone = 0x03f00000-0x04000000
Hardware Trace Active and Enabled
Reset caused by Software reset
Blackfin support (C) 2004-2008 Analog Devices, Inc.
Compiled for ADSP-BF537 Rev 0.2
Blackfin Linux support by blackfin.uclinux.org/
Processor Speed: 500 MHz core clock and 100 MHz System Clock
NOMPU: setting up cplb tables for global access
Instruction Cache Enabled
Data Cache Enabled (write-through)
Built 1 zonelists in Zone order, mobility grouping off. Total pages: 14223
Kernel command line: root=/dev/mtdblock0 rw earlyprintk=serial,uart0,57600 ip=10.100.4.50 console=null
Configuring Blackfin Priority Driven Interrupts
PID hash table entries: 256 (order: 8, 1024 bytes)
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory available: 51668k/65536k RAM, (3572k init code, 1065k kernel code, 451k data, 1024k dma, 7756k reserved)
Calibrating delay loop... 997.37 BogoMIPS (lpj=1994752)
Security Framework initialized
Mount-cache hash table entries: 512
Blackfin Scratchpad data SRAM: 4 KB
Blackfin L1 Data A SRAM: 16 KB (15 KB free)
Blackfin L1 Data B SRAM: 16 KB (16 KB free)
Blackfin L1 Instruction SRAM: 48 KB (41 KB free)
net_namespace: 288 bytes
NET: Registered protocol family 16
Blackfin GPIO Controller
Blackfin DMA Controller
stamp_init(): registering device resources
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
NET: Registered protocol family 1
msgmni has been set to 100
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler cfq registered
Serial: Blackfin serial driver
bfin-uart.1: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART
brd: module loaded
bfin_mac_mdio: probed
bfin_mac: attached PHY driver [SMSC LAN83C185] (mii_bus:phy_addr=0:01, irq=-1, mdc_clk=2500000Hz(mdc_div=19)@sclk=100MHz)
bfin_mac bfin_mac.0: Blackfin on-chip Ethernet MAC driver, Version 1.1
bfin-spi bfin-spi.0: Blackfin BF5xx on-chip SPI Controller Driver, Version 1.0, regs_base@ffc00500, dma channel@7
rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0
bfin-wdt: initialized: timeout=20 sec (nowayout=0)
TCP cubic registered
NET: Registered protocol family 17
turn off boot console early_BFuart0
Then on host,run :
test@my-local-machine:~/work/cruise/checkouts/uclinux-dist> ping 10.100.4.50
PING 10.100.4.50 (10.100.4.50) 56(84) bytes of data.
From 10.100.4.174: icmp_seq=2 Destination Host Unreachable
From 10.100.4.174 icmp_seq=2 Destination Host Unreachable
From 10.100.4.174 icmp_seq=3 Destination Host Unreachable
From 10.100.4.174 icmp_seq=4 Destination Host Unreachable
--- 10.100.4.50 ping statistics ---
5 packets transmitted, 0 received, +4 errors, 100% packet loss, time 4001ms
, pipe 3
Follow-ups
--- Mike Frysinger 2008-11-04 01:53:21
i dont think you have any services defined in /etc/inittab. if you dont have
any defined, then init will exit, and the kernel will panic ... this is correct
behavior ...
--- Mingquan Pan 2008-11-04 03:50:55
but if the kernel command line is only : root=/dev/mtdblock0 rw
earlyprintk=serial,uart0,57600
ip=10.100.4.50 and not with console=null, after the kernel is booted up, it
could be pinged through. And it is fine before the upgrade, with the same kernel
configuration.
--- Mike Frysinger 2008-11-04 04:02:52
do you have USER_INIT_CONSOLE_SH turned on ? if so, then this is still correct
behavior as with a console, init will spawn a console shell and manage that
post your /etc/inittab as well as your configuration (make bugreport)
--- Mingquan Pan 2008-11-04 05:06:13
the USER_INIT_CONSOLE_SH is always turnded on by default, it is also on before
the upgrade.
The thing I don't understand is that why before the upgrade this usage is ok,
but not now.
the /etc/inittab and config file are pretty much like the default.
root:/> cat /etc/inittab
# inittab for uClinux
# Format:
# ttyline:termcap-entry:getty-command
#httpd:unknown:/bin/httpd
#sh:unknown:/bin/sh
#ttyS0::respawn:-/bin/sh
#sh:console:respawn:/bin/sh
#console::askfirst:-/bin/sh
inetd:unknown:/sbin/inetd
slog:unknown:/sbin/syslogd -n
klog:unknown:/sbin/klogd -n
watchdogd:unknown:/bin/watchdogd -f -s
config file is attached.
--- Mike Frysinger 2008-11-04 05:11:56
according to that inittab and config file, it looks like it should work OK ...
--- Sonic Zhang 2008-11-13 01:35:31
Fixed. Should check if tty_driver d is NULL before call kref_get() in
tty_driver_kref_get().
--- Mingquan Pan 2008-11-14 05:03:48
Yes,fixed. Close.
--- Mingquan Pan 2008-11-25 03:28:27
It is fixed on the other boards except bf533 board, so reopen it. The error log
is same:
bfin> bootelf
Loading phdr 0 to 0x00001000 (1413092 bytes)
Loading phdr 1 to 0x00169b4c (2500142 bytes)
Loading phdr 2 to 0x003cc17a (6952 bytes)
Loading phdr 3 to 0x003cdca2 (192 bytes)
## Starting application at 0x00183150 ...
Linux version 2.6.28-rc2-ADI-2009R1-pre-svn5746
(test@uclinux76-bf533-stamp-elf) (gcc version 4.1.2 (ADI svn)) #41 Mon Nov 24
01:32:55 MST 2008
Warning: limiting memory to 56MB due to hardware anomaly 05000263
Board Memory: 128MB
Kernel Managed Memory: 128MB
Memory map:
fixedcode = 0x00000400-0x00000490
text = 0x00001000-0x0010b470
rodata = 0x0010b470-0x00159fe4
bss = 0x00159ff0-0x00169b4c
data = 0x00169b4c-0x00178000
stack = 0x00176000-0x00178000
init = 0x00178000-0x003ce000
available = 0x003ce000-0x037ff000
DMA Zone = 0x07f00000-0x08000000
Hardware Trace Active and Enabled
Reset caused by Software reset
Blackfin support (C) 2004-2008 Analog Devices, Inc.
Compiled for ADSP-BF533 Rev 0.3
Warning: Compiled for Rev 3, but running on Rev 4
Blackfin Linux support by blackfin.uclinux.org/
Processor Speed: 398 MHz core clock and 79 MHz System Clock
NOMPU: setting up cplb tables for global access
Instruction Cache Enabled for CPU0
Data Cache Enabled for CPU0 (write-through)
Built 1 zonelists in Zone order, mobility grouping off. Total pages: 14223
Kernel command line:
Configuring Blackfin Priority Driven Interrupts
PID hash table entries: 256 (order: 8, 1024 bytes)
console [ttyBF0] enabled
Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
Memory available: 52864k/131072k RAM, (2392k init code, 1065k kernel code, 435k
data, 1024k dma, 73292k reserved)
Calibrating delay loop... 792.57 BogoMIPS (lpj=1585152)
Security Framework initialized
Mount-cache hash table entries: 512
Blackfin Scratchpad data SRAM: 4 KB
Blackfin L1 Data A SRAM: 16 KB (15 KB free)
Blackfin L1 Data B SRAM: 16 KB (16 KB free)
Blackfin L1 Instruction SRAM: 64 KB (57 KB free)
PDA for CPU0 reserved at 0015b194
net_namespace: 288 bytes
NET: Registered protocol family 16
Blackfin GPIO Controller
Blackfin DMA Controller
stamp_init(): registering device resources
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
NET: Registered protocol family 1
msgmni has been set to 103
io scheduler noop registered
io scheduler anticipatory registered (default)
io scheduler cfq registered
Serial: Blackfin serial driver
bfin-uart.1: ttyBF0 at MMIO 0xffc00400 (irq = 21) is a BFIN-UART
brd: module loaded
smc91x.c: v1.1, sep 22 2004 by Nicolas Pitre <nico@cam.org>
eth0: SMC91C11xFD (rev 1) at 20300300 IRQ 40 [nowait]
eth0: Ethernet addr: 00:e0:22:fe:04:8b
bfin-spi bfin-spi.0: Blackfin on-chip SPI Controller Driver, Version 1.0,
regs_base@ffc00500, dma channel@5
rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0
bfin-wdt: initialized: timeout=20 sec (nowayout=0)
TCP cubic registered
NET: Registered protocol family 17
rtc-bfin rtc-bfin: setting system clock to 1973-03-25 20:24:52 UTC (101939092)
Freeing unused kernel memory: 2392k freed
dma_alloc_init: dma_page @ 0x003cb000 - 256 pages at 0x07f00000
_____________________________________
a8888b. / Welcome to the uClinux distribution \
d888888b. / _ _ \
8P"YP"Y88 / | | |_| __ __ (TM) |
8|o||o|88 _____/ | | _ ____ _ _ \ \/ / |
8' .88 \ | | | | _ \| | | | \ / |
8`._.' Y8. \ | |__ | | | | | |_| | / \ |
d/ `8b. \ \____||_|_| |_|\____|/_/\_\ |
dP . Y8b. \ For embedded processors including |
d8:' " `::88b \ the Analog Devices Blackfin /
d8" 'Y88b \___________________________________/
:8P ' :888
8a. : _a88P For further information, check out:
._/"Yaa_: .| 88P| - blackfin.uclinux.org/
\ YP" `| 8P `. - docs.blackfin.uclinux.org/
/ \.___.d| .' - www.uclinux.org/
`--..__)8888P`._.' jgs/a:f - www.analog.com/blackfin
Have a lot of fun...
BusyBox v1.12.2 (2008-11-24 00:36:35 MST) built-in shell (msh)
Enter 'help' for a list of built-in commands.
root:/>
(Back at uclinux76-bf533-stamp-elf.analog.com)
----------------------------------------------------
Linux Kermit>q
Closing /dev/ttyS0...OK
sh-3.00$ telnet 10.100.4.50
Trying 10.100.4.50...
Failed inital telnet
--- Sonic Zhang 2008-12-01 05:16:03
can't replicate. looks your uboot doesn't forward the bootargs to kernel.
--- Mike Frysinger 2008-12-01 11:38:39
u-boot-2008.10 doesnt pass kernel args via bootelf as noted in other bugs
--- Mingquan Pan 2008-12-03 02:10:54
so change this test case to use uImage instead of linux.
Files
Changes
Commits
Dependencies
Duplicates
Associations
Tags
File Name File Type File Size Posted By
config.vender application/octet-stream 45450 Mingquan Pan
config.kernel application/octet-stream 32824 Mingquan Pan