foss-for-synopsys-dwc-arc-processors / linux

Helpful resources for users & developers of Linux kernel for ARC
22 stars 13 forks source link

HSDK fails to boot Linux v5.11-rc1 #34

Closed vineetgarc closed 3 years ago

vineetgarc commented 3 years ago

5.11-rc1 boot log

Linux version 5.11.0-rc2-00130-gf4d9359de8ac (vineetg@vineetg-Latitude-7400) (arc-linux-gcc.br_real (Buildroot 2020.
08-4-g742b459a97f8-dirty) 10.2.0, GNU ld (GNU Binutils) 2.34) #186 SMP PREEMPT Tue Jan 5 17:20:56 PST 2021
Memory @ 80000000 [1024M] 
OF: fdt: Machine model: snps,hsdk
earlycon: uart8250 at MMIO32 0xf0005000 (options '115200n8')
printk: bootconsole [uart8250] enabled
Failed to get possible-cpus from dtb, pretending all 4 cpus exist
archs-intc      : 2 priority levels (default 1) FIRQ (not used)

IDENTITY        : ARCVER [0x54] ARCNUM [0x0] CHIPID [ 0x0]
processor [0]   : HS48 R3.10a (ARCv2 ISA)  Dual-Issue 
Timers          : Timer0 Timer1 RTC [UP 64-bit] GFRC [SMP 64-bit] 
ISA Extn        : atomic ll64 unalign mpy[opt 9] div_rem 
BPU             : full match, cache:2048, Predict Table:16384 Return stk: 8 Loop Buffer:8 (disabled) 
MMU [v5]        : 8k PAGE, 2M Super Page (not used) JTLB 1024 (256x4), uDTLB 8, uITLB 4, PAE40 (not used) 
I-Cache         : 64K, 4way/set, 64B Line, VIPT aliasing
D-Cache         : 64K, 2way/set, 64B Line, PIPT
SLC             : 512K, 128B Line
Peripherals     : 0xf0000000, IO-Coherency (per-device) 
Vector Table    : 0x90000000
FPU             : SP DP 
DEBUG           : smaRT RTT ActionPoint 8/full
Extn [SMP]      : ARConnect (v2): 4 cores with IPI IDU DEBUG GFRC
 ! Enable CONFIG_ARC_DSP_HANDLED for working apps
Zone ranges:
  Normal   [mem 0x0000000080000000-0x00000000bfffffff]
Movable zone start for each node
Early memory node ranges
  node   0: [mem 0x0000000080000000-0x00000000bfffffff]
Initmem setup node 0 [mem 0x0000000080000000-0x00000000bfffffff]
On node 0 totalpages: 131072
  Normal zone: 576 pages used for memmap
  Normal zone: 0 pages reserved
  Normal zone: 131072 pages, LIFO batch:31
percpu: Embedded 7 pages/cpu s23296 r8192 d25856 u57344
pcpu-alloc: s23296 r8192 d25856 u57344 alloc=7*8192
pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3 
Built 1 zonelists, mobility grouping on.  Total pages: 130496
Kernel command line: earlycon=uart8250,mmio32,0xf0005000,115200n8 console=ttyS0,115200n8 debug print-fatal-signals=1
Dentry cache hash table entries: 131072 (order: 6, 524288 bytes, linear)
Inode-cache hash table entries: 65536 (order: 5, 262144 bytes, linear)
mem auto-init: stack:off, heap alloc:off, heap free:off
Memory: 1027408K/1048576K available (5394K kernel code, 634K rwdata, 1328K rodata, 6552K init, 268K bss, 21168K rese
rved, 0K cma-reserved)
rcu: Preemptible hierarchical RCU implementation.
rcu:    RCU event tracing is enabled.
        Trampoline variant of Tasks RCU enabled.
rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
NR_IRQS: 512
MCIP: IDU supports 64 common irqs
sched_clock: 64 bits at 999MHz, resolution 1ns, wraps every 4398046511103ns
clocksource: ARConnect GFRC: mask: 0xffffffffffffffff max_cycles: 0x1cd42e4dffb, max_idle_ns: 881590591483 ns
Console: colour dummy device 80x25
Calibrating delay loop... 996.14 BogoMIPS (lpj=4980736)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 2048 (order: 0, 8192 bytes, linear)
Mountpoint-cache hash table entries: 2048 (order: 0, 8192 bytes, linear)
rcu: Hierarchical SRCU implementation.
smp: Bringing up secondary CPUs ...
Idle Task [1] (ptrval)
Trying to bring up CPU1 ...
archs-intc      : 2 priority levels (default 1) FIRQ (not used)

IDENTITY        : ARCVER [0x54] ARCNUM [0x1] CHIPID [ 0x0]
processor [1]   : HS48 R3.10a (ARCv2 ISA)  Dual-Issue 
Timers          : Timer0 Timer1 RTC [UP 64-bit] 
ISA Extn        : atomic ll64 unalign mpy[opt 9] div_rem 
BPU             : full match, cache:2048, Predict Table:16384 Return stk: 8 Loop Buffer:8 
MMU [v5]        : 8k PAGE, 2M Super Page (not used) JTLB 1024 (256x4), uDTLB 8, uITLB 4, PAE40 (not used) 
I-Cache         : 64K, 4way/set, 64B Line, VIPT aliasing
D-Cache         : 64K, 2way/set, 64B Line, PIPT
SLC             : 512K, 128B Line
Peripherals     : 0xf0000000, IO-Coherency (per-device) 
Vector Table    : 0x90000000
FPU             : SP DP 
DEBUG           : smaRT RTT ActionPoint 8/full
Extn [CCM]      : DCCM @ 60000000, 64 KB / ICCM: @ 60000000, 256 KB
Extn [SMP]      : ARConnect (v2): 4 cores with IPI IDU DEBUG GFRC
 ! Enable CONFIG_ARC_DSP_HANDLED for working apps
## CPU1 LIVE ##: Executing Code...
Idle Task [2] (ptrval)
Trying to bring up CPU2 ...
archs-intc      : 2 priority levels (default 1) FIRQ (not used)

IDENTITY        : ARCVER [0x54] ARCNUM [0x2] CHIPID [ 0x0]
processor [2]   : HS48 R3.10a (ARCv2 ISA)  Dual-Issue 
Timers          : Timer0 Timer1 RTC [UP 64-bit] 
ISA Extn        : atomic ll64 unalign mpy[opt 9] div_rem 
BPU             : full match, cache:2048, Predict Table:16384 Return stk: 8 Loop Buffer:8 
MMU [v5]        : 8k PAGE, 2M Super Page (not used) JTLB 1024 (256x4), uDTLB 8, uITLB 4, PAE40 (not used) 
I-Cache         : 64K, 4way/set, 64B Line, VIPT aliasing
D-Cache         : 64K, 2way/set, 64B Line, PIPT
SLC             : 512K, 128B Line
Peripherals     : 0xf0000000, IO-Coherency (per-device) 
Vector Table    : 0x90000000
FPU             : SP DP 
DEBUG           : smaRT RTT ActionPoint 8/full
Extn [SMP]      : ARConnect (v2): 4 cores with IPI IDU DEBUG GFRC
 ! Enable CONFIG_ARC_DSP_HANDLED for working apps
## CPU2 LIVE ##: Executing Code...
Idle Task [3] (ptrval)
Trying to bring up CPU3 ...
archs-intc      : 2 priority levels (default 1) FIRQ (not used)

IDENTITY        : ARCVER [0x54] ARCNUM [0x3] CHIPID [ 0x0]
processor [3]   : HS48 R3.10a (ARCv2 ISA)  Dual-Issue 
Timers          : Timer0 Timer1 RTC [UP 64-bit] 
ISA Extn        : atomic ll64 unalign mpy[opt 9] div_rem 
BPU             : full match, cache:2048, Predict Table:16384 Return stk: 8 Loop Buffer:8 
MMU [v5]        : 8k PAGE, 2M Super Page (not used) JTLB 1024 (256x4), uDTLB 8, uITLB 4, PAE40 (not used) 
I-Cache         : 64K, 4way/set, 64B Line, VIPT aliasing
D-Cache         : 64K, 2way/set, 64B Line, PIPT
SLC             : 512K, 128B Line
Peripherals     : 0xf0000000, IO-Coherency (per-device) 
Vector Table    : 0x90000000
FPU             : SP DP 
DEBUG           : smaRT RTT ActionPoint 8/full
Extn [CCM]      : DCCM @ 60000000, 64 KB / ICCM: @ 60000000, 256 KB
Extn [SMP]      : ARConnect (v2): 4 cores with IPI IDU DEBUG GFRC
 ! Enable CONFIG_ARC_DSP_HANDLED for working apps
## CPU3 LIVE ##: Executing Code...
smp: Brought up 1 node, 4 CPUs
devtmpfs: initialized
random: get_random_u32 called from rhashtable_init+0xbc/0x288 with crng_init=0
clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
futex hash table entries: 1024 (order: 4, 131072 bytes, linear)
NET: Registered protocol family 16
DMA: preallocated 128 KiB GFP_KERNEL pool for atomic allocations
thermal_sys: Registered thermal governor 'step_wise'
OF: /soc/gpio@3000/gpio-controller@0: could not find phandle
reg-fixed-voltage regulator-5v0: use noncoherent DMA ops
SCSI subsystem initialized
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
pps_core: LinuxPPS API ver. 1 registered
pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
PTP clock support registered
clocksource: Switched to clocksource ARConnect GFRC
NET: Registered protocol family 2
tcp_listen_portaddr_hash hash table entries: 1024 (order: 0, 12288 bytes, linear)
TCP established hash table entries: 8192 (order: 2, 32768 bytes, linear)
TCP bind hash table entries: 8192 (order: 3, 65536 bytes, linear)
TCP: Hash tables configured (established 8192 bind 8192)
UDP hash table entries: 512 (order: 1, 16384 bytes, linear)
UDP-Lite hash table entries: 512 (order: 1, 16384 bytes, linear)
NET: Registered protocol family 1
random: fast init done
RPC: Registered named UNIX socket transport module.
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
arc-pct pct: use noncoherent DMA ops
ARC perf        : 8 counters (48 bits), 123 conditions, [overflow IRQ support]
workingset: timestamp_bits=30 max_order=17 bucket_order=0
Block layer SCSI generic (bsg) driver version 0.4 loaded (major 250)
io scheduler mq-deadline registered
io scheduler kyber registered
snps-creg-gpio f00014b0.gpio: use noncoherent DMA ops
snps-creg-gpio f00014b0.gpio: GPIO controller with 2 gpios probed
gpio-dwapb f0003000.gpio: use noncoherent DMA ops
gpio-dwapb f0003000.gpio: no IRQ for port0
dw_axi_dmac_platform f0080000.dmac: use noncoherent DMA ops
dw_axi_dmac_platform f0080000.dmac: DesignWare AXI DMA Controller, 4 channels
hsdk-reset f00008a0.reset-controller: use noncoherent DMA ops
Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
dw-apb-uart f0005000.serial: use noncoherent DMA ops
printk: console [ttyS0] disabled
f0005000.serial: ttyS0 at MMIO 0xf0005000 (irq = 6, base_baud = 2083125) is a 16550A
printk: console [ttyS0] enabled
printk: console [ttyS0] enabled
printk: bootconsole [uart8250] disabled
printk: bootconsole [uart8250] disabled
usbcore: registered new interface driver udl
etnaviv-gpu f0090000.gpu: use noncoherent DMA ops
 (null): use noncoherent DMA ops
etnaviv etnaviv: bound f0090000.gpu (ops 0x90bd9eb4)
etnaviv-gpu f0090000.gpu: model: GC0, revision: 0
etnaviv-gpu f0090000.gpu: Unknown GPU model
[drm] Initialized etnaviv 1.3.0 20151214 for etnaviv on minor 0
brd: module loaded
dw_spi_mmio f0020000.spi: use noncoherent DMA ops
spi-nor spi0.0: sst26wf016b (2048 Kbytes)

5.10 is fine with same rootfs

vineetgarc commented 3 years ago

So it seems there are a couple of issues which surprisingly the inhouse regression jobs have not caught (perhaps they went away for holidays too).

First issue is snafu in generic signal handling changes: 53855e12588743ea128 ("arc: add support for TIF_NOTIFY_SIGNAL") which I didn't spot at the time of review. Fix will likely make it into 5.11-rc3: http://lists.infradead.org/pipermail/linux-snps-arc/2021-January/004729.html

The 2nd is no console output in a devtmpfs based Buildroot init system due to upstream 757055ae8dedf5 ("init/console: Use ttynull as a fallback when there is no console"). This has been reported to mailing list too http://lists.infradead.org/pipermail/linux-snps-arc/2021-January/004728.html

vineetgarc commented 3 years ago

Fixes for both the issues: arc: add support for TIF_NOTIFY_SIGNAL and Revert "init/console: Use ttynull as a fallback when there is no console" have been merged in released 5.11-rc3

Verfified that 5.11-rc3 boots fine.

Linux version 5.11.0-rc3 (vineetg@vineetg-Latitude-7400) (arc-linux-gcc.br_real (Buildroot 2020
.08-4-g742b459a97f8) 9.3.0, GNU ld (GNU Binutils) 2.34) #192 SMP PREEMPT Sun Jan 10 15:06:19 PST 
2021
Memory @ 80000000 [1024M] 
OF: fdt: Machine model: snps,hsdk
earlycon: uart8250 at MMIO32 0xf0005000 (options '115200n8')
printk: bootconsole [uart8250] enabled
Failed to get possible-cpus from dtb, pretending all 4 cpus exist
archs-intc      : 2 priority levels (default 1) FIRQ (not used)

IDENTITY        : ARCVER [0x54] ARCNUM [0x0] CHIPID [ 0x0]
processor [0]   : HS48 R3.10a (ARCv2 ISA)  Dual-Issue 
Timers          : Timer0 Timer1 RTC [UP 64-bit] GFRC [SMP 64-bit] 
ISA Extn        : atomic ll64 unalign mpy[opt 9] div_rem 
BPU             : full match, cache:2048, Predict Table:16384 Return stk: 8 Loop Buffer:8 (disabl
ed) 
MMU [v5]        : 8k PAGE, 2M Super Page (not used) JTLB 1024 (256x4), uDTLB 8, uITLB 4, PAE40 (n
ot used) 
I-Cache         : 64K, 4way/set, 64B Line, VIPT aliasing
D-Cache         : 64K, 2way/set, 64B Line, PIPT
SLC             : 512K, 128B Line
Peripherals     : 0xf0000000, IO-Coherency (per-device) 
Vector Table    : 0x90000000
FPU             : SP DP 
DEBUG           : smaRT RTT ActionPoint 8/full
Extn [SMP]      : ARConnect (v2): 4 cores with IPI IDU DEBUG GFRC
 ! Enable CONFIG_ARC_DSP_HANDLED for working apps
Zone ranges:
  Normal   [mem 0x0000000080000000-0x00000000bfffffff]
Movable zone start for each node
Early memory node ranges
  node   0: [mem 0x0000000080000000-0x00000000bfffffff]
Initmem setup node 0 [mem 0x0000000080000000-0x00000000bfffffff]
On node 0 totalpages: 131072
  Normal zone: 576 pages used for memmap
  Normal zone: 0 pages reserved
  Normal zone: 131072 pages, LIFO batch:31
percpu: Embedded 7 pages/cpu s23296 r8192 d25856 u57344
pcpu-alloc: s23296 r8192 d25856 u57344 alloc=7*8192
pcpu-alloc: [0] 0 [0] 1 [0] 2 [0] 3 
Built 1 zonelists, mobility grouping on.  Total pages: 130496
Kernel command line: earlycon=uart8250,mmio32,0xf0005000,115200n8 console=ttyS0,115200n8 debug pr
int-fatal-signals=1
Dentry cache hash table entries: 131072 (order: 6, 524288 bytes, linear)
Inode-cache hash table entries: 65536 (order: 5, 262144 bytes, linear)
mem auto-init: stack:off, heap alloc:off, heap free:off
Memory: 1027368K/1048576K available (5444K kernel code, 636K rwdata, 1328K rodata, 6560K init, 26
8K bss, 21208K reserved, 0K cma-reserved)
rcu: Preemptible hierarchical RCU implementation.
rcu:    RCU event tracing is enabled.
        Trampoline variant of Tasks RCU enabled.
rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
NR_IRQS: 512
MCIP: IDU supports 64 common irqs
sched_clock: 64 bits at 999MHz, resolution 1ns, wraps every 4398046511103ns
clocksource: ARConnect GFRC: mask: 0xffffffffffffffff max_cycles: 0x1cd42e4dffb, max_idle_ns: 881
590591483 ns
Console: colour dummy device 80x25
Calibrating delay loop... 996.14 BogoMIPS (lpj=4980736)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 2048 (order: 0, 8192 bytes, linear)
Mountpoint-cache hash table entries: 2048 (order: 0, 8192 bytes, linear)
rcu: Hierarchical SRCU implementation.
...
...
Saving random seed: random: dd: uninitialized urandom read (512 bytes read)
OK
usb 1-1: new high-speed USB device number 2 using ehci-platform
hub 1-1:1.0: USB hub found
hub 1-1:1.0: 2 ports detected
# 
# 
# 
# 
# ls
bin        hackbench  lib32      mnt        proc       sbin       usr
dev        init       linuxrc    oom        root       sys        var
etc        lib        media      opt        run        tmp
#