Hi,

On Tue, Oct 04, 2016 at 07:40:05AM -0700, Marcos Cruz wrote:
> Hi all,
> 
> 
>     I am trying upgrade the kernel of a board to mainline kernel (4.7.4) 
> and I'm having difficulties with the booting procedure after the upgrade. 
>     This board hasn't a dts file available in the kernel, I had to write 
> one and I believe this is the likely source of the problem.
>     The board actually boots but it is not mounting the root partition (it 
> is an eMMC, /dev/mmcblk0p7). After some messages sent over the serial line, 
> the kernel disables some board power sources and stops sending data. 
> Probably there are more messages to be sent.
>     Anyone knows what's wrong? The board works flawlessly with an older 
> kernel (3.3.0) and the older tools provided by the people that developed 
> this board.

Without the DT and the schematics or the FEX file, it's quite hard to
tell.

> Uncompressing Linux...
>  done, booting the kernel.
> [    0.000000] Booting Linux on physical CPU 0x0
> [    0.000000] Linux version 4.7.4 (marcos@fulgore) (gcc version 4.9.1 
> (Buildroot 2014.08-00008-gb374d79-dirty) ) #32 SMP Thu Sep 29 16:52:23 BRT 
> 2016
> [    0.000000] CPU: ARMv7 Processor [410fc073] revision 3 (ARMv7), cr=10c5387d
> [    0.000000] CPU: div instructions available: patching division code
> [    0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing 
> instruction cache
> [    0.000000] Machine model: Medidor Sigmasys v0
> [    0.000000] bootconsole [earlycon0] enabled
> [    0.000000] Memory policy: Data cache writealloc
> [    0.000000] percpu: Embedded 13 pages/cpu @ef7ad000 s22400 r8192 d22656 
> u53248
> [    0.000000] Built 1 zonelists in Zone order, mobility grouping on.  Total 
> pages: 260608
> [    0.000000] Kernel command line: console=ttyS0,115200 root=/dev/mmcblk0p7 
> init=/init loglevel=7 
> partitions=bootloader@mmcblk0p2:env@mmcblk0p5:boot@mmcblk0p6:rootfs@mmcblk0p7:UDISK@mmcblk0p1
>  earlyprintk
> [    0.000000] PID hash table entries: 4096 (order: 2, 16384 bytes)
> [    0.000000] Dentry cache hash table entries: 131072 (order: 7, 524288 
> bytes)
> [    0.000000] Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
> [    0.000000] Memory: 1030528K/1048576K available (5273K kernel code, 249K 
> rwdata, 1412K rodata, 1024K init, 249K bss, 18048K reserved, 0K cma-reserved, 
> 262144K highmem)
> [    0.000000] Virtual kernel memory layout:
> [    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
> [    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
> [    0.000000]     vmalloc : 0xf0800000 - 0xff800000   ( 240 MB)
> [    0.000000]     lowmem  : 0xc0000000 - 0xf0000000   ( 768 MB)
> [    0.000000]     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
> [    0.000000]     modules : 0xbf000000 - 0xbfe00000   (  14 MB)
> [    0.000000]       .text : 0xc0008000 - 0xc07877d8   (7678 kB)
> [    0.000000]       .init : 0xc0800000 - 0xc0900000   (1024 kB)
> [    0.000000]       .data : 0xc0900000 - 0xc093e6e0   ( 250 kB)
> [    0.000000]        .bss : 0xc0940000 - 0xc097e44c   ( 250 kB)
> [    0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
> [    0.000000] Hierarchical RCU implementation.
> [    0.000000] \0x09Build-time adjustment of leaf fanout to 32.
> [    0.000000] \0x09RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=4.
> [    0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=32, nr_cpu_ids=4
> [    0.000000] NR_IRQS:16 nr_irqs:16 16
> [    0.000000] Architected cp15 timer(s) running at 24.00MHz (phys).
> [    0.000000] clocksource: arch_sys_counter: mask: 0xffffffffffffff 
> max_cycles: 0x588fe9dc0, max_idle_ns: 440795202592 ns
> [    0.000006] sched_clock: 56 bits at 24MHz, resolution 41ns, wraps every 
> 4398046511097ns
> [    0.008086] Switching to timer-based delay loop, resolution 41ns
> [    0.014374] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, 
> max_idle_ns: 79635851949 ns
> [    0.023681] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, 
> max_idle_ns: 12741736309 ns
> [    0.033158] Console: colour dummy device 80x30
> [    0.037694] Calibrating delay loop (skipped), value calculated using timer 
> frequency.. 48.00 BogoMIPS (lpj=240000)
> [    0.048136] pid_max: default: 32768 minimum: 301
> [    0.052914] Mount-cache hash table entries: 2048 (order: 1, 8192 bytes)
> [    0.059615] Mountpoint-cache hash table entries: 2048 (order: 1, 8192 
> bytes)
> [    0.067310] CPU: Testing write buffer coherency: ok
> [    0.072559] /cpus/cpu@0 missing clock-frequency property
> [    0.077954] /cpus/cpu@1 missing clock-frequency property
> [    0.083371] /cpus/cpu@2 missing clock-frequency property
> [    0.088765] /cpus/cpu@3 missing clock-frequency property
> [    0.094168] CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
> [    0.100072] Setting up static identity map for 0x40100000 - 0x40100058
> [    0.119023] CPU1: thread -1, cpu 1, socket 0, mpidr 80000001
> [    0.130609] CPU2: thread -1, cpu 2, socket 0, mpidr 80000002
> [    0.142186] CPU3: thread -1, cpu 3, socket 0, mpidr 80000003
> [    0.142242] Brought up 4 CPUs
> [    0.162508] SMP: Total of 4 processors activated (192.00 BogoMIPS).
> [    0.168850] CPU: All CPU(s) started in SVC mode.

Sidenote, you should consider upgrading your bootloader to support
PSCI.

> [    0.174347] devtmpfs: initialized
> [    0.183613] VFP support v0.3: implementor 41 architecture 2 part 30 
> variant 7 rev 3
> [    0.191556] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, 
> max_idle_ns: 19112604462750000 ns
> [    0.201531] pinctrl core: initialized pinctrl subsystem
> [    0.207671] NET: Registered protocol family 16
> [    0.212466] DMA: preallocated 256 KiB pool for atomic coherent allocations
> [    0.223272] hw-breakpoint: found 5 (+1 reserved) breakpoint and 4 
> watchpoint registers.
> [    0.231351] hw-breakpoint: maximum watchpoint size is 8 bytes.
> [    0.244582] SCSI subsystem initialized
> [    0.248791] usbcore: registered new interface driver usbfs
> [    0.254398] usbcore: registered new interface driver hub
> [    0.259846] usbcore: registered new device driver usb
> [    0.265127] pps_core: LinuxPPS API ver. 1 registered
> [    0.270182] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo 
> Giometti <[email protected]>
> [    0.279399] PTP clock support registered
> [    0.283593] Advanced Linux Sound Architecture Driver Initialized.
> [    0.290445] clocksource: Switched to clocksource arch_sys_counter
> [    0.305000] NET: Registered protocol family 2
> [    0.309892] TCP established hash table entries: 8192 (order: 3, 32768 
> bytes)
> [    0.317122] TCP bind hash table entries: 8192 (order: 4, 65536 bytes)
> [    0.323760] TCP: Hash tables configured (established 8192 bind 8192)
> [    0.330245] UDP hash table entries: 512 (order: 2, 16384 bytes)
> [    0.336299] UDP-Lite hash table entries: 512 (order: 2, 16384 bytes)
> [    0.342902] NET: Registered protocol family 1
> [    0.347564] RPC: Registered named UNIX socket transport module.
> [    0.353586] RPC: Registered udp transport module.
> [    0.358368] RPC: Registered tcp transport module.
> [    0.363164] RPC: Registered tcp NFSv4.1 backchannel transport module.
> [    0.369967] hw perfevents: enabled with armv7_cortex_a7 PMU driver, 5 
> counters available
> [    0.379025] futex hash table entries: 1024 (order: 4, 65536 bytes)
> [    0.386063] workingset: timestamp_bits=28 max_order=18 bucket_order=0
> [    0.400912] NFS: Registering the id_resolver key type
> [    0.406083] Key type id_resolver registered
> [    0.410345] Key type id_legacy registered
> [    0.415194] bounce: pool size: 64 pages
> [    0.419283] Block layer SCSI generic (bsg) driver version 0.4 loaded 
> (major 250)
> [    0.426771] io scheduler noop registered
> [    0.430781] io scheduler deadline registered
> [    0.435149] io scheduler cfq registered (default)
> [    0.442156] sun6i-a31s-pinctrl 1c20800.pinctrl: initialized sunXi PIO 
> driver
> [    0.449415] sun6i-a31-r-pinctrl 1f02c00.pinctrl: Reset controller missing
> [    0.508666] Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
> [    0.518045] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
> [    0.524673] ehci-platform: EHCI generic platform driver
> [    0.530071] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
> [    0.536348] ohci-platform: OHCI generic platform driver
> [    0.542433] i2c /dev entries driver
> [    0.546188] i2c-sunxi-p2wi 1f03400.i2c: could not find pctldev for node 
> /soc@01c00000/pinctrl@01f02c00/p2wi, deferring probe
> [    0.557577] IR NEC protocol handler initialized
> [    0.562200] IR RC5(x/sz) protocol handler initialized
> [    0.567328] IR RC6 protocol handler initialized
> [    0.571946] IR JVC protocol handler initialized
> [    0.576553] IR Sony protocol handler initialized
> [    0.581257] IR SANYO protocol handler initialized
> [    0.586041] IR Sharp protocol handler initialized
> [    0.590832] IR MCE Keyboard/mouse protocol handler initialized
> [    0.596740] IR XMP protocol handler initialized
> [    0.601889] sunxi-wdt 1c20ca0.watchdog: Watchdog enabled (timeout=16 sec, 
> nowayout=0)
> [    0.612915] sun4i-ss 1c15000.crypto-engine: Die ID 5
> [    0.619054] usbcore: registered new interface driver usbhid
> [    0.624725] usbhid: USB HID core driver
> [    0.630318] NET: Registered protocol family 17
> [    0.634961] Key type dns_resolver registered
> [    0.639424] Registering SWP/SWPB emulation handler
> [    0.645792] sun6i-a31-r-pinctrl 1f02c00.pinctrl: initialized sunXi PIO 
> driver
> [    0.653684] axp20x-i2c 0-0068: AXP20x variant AXP221 found
> [    0.683582] input: axp20x-pek as 
> /devices/platform/soc@01c00000/1f03400.i2c/i2c-0/0-0068/axp20x-pek/input/input0
> [    0.698869] dc1sw: supplied by vcc-3v0
> [    0.703473] dc5ldo: supplied by vcc-dram
> [    0.718521] axp20x-i2c 0-0068: AXP20X driver loaded
> [    0.724104] sunxi-mmc 1c11000.mmc: allocated mmc-pwrseq
> [    0.760465] sunxi-mmc 1c11000.mmc: base:0xf08a0000 irq:29
> [    0.769131] vcc3v0: disabling
> [    0.771878] sunxi-mmc 1c11000.mmc: smc 0 err, cmd 8, RTO !!
> [    0.775963] sunxi-mmc 1c11000.mmc: smc 0 err, cmd 55, RTO !!
> [    0.776788] sunxi-mmc 1c11000.mmc: smc 0 err, cmd 55, RTO !!
> [    0.777610] sunxi-mmc 1c11000.mmc: smc 0 err, cmd 55, RTO !!
> [    0.778433] sunxi-mmc 1c11000.mmc: smc 0 err, cmd 55, RTO !!
> [    0.800802] vcc3v3: disabling
> [    0.803850] vcc5v0: disabling
> [    0.806903] vdd-gpu: disabling
> [    0.810638] vcc-lcd: disabling
> [    0.814027] sunxi-mmc 1c11000.mmc: smc 0 err, cmd 6, RCE !!
> [    0.819697] vdd-cpus: disabling

Shutting down the CPU regulator is usually a rather bad idea :)
You should probably flag it as always-on in the DT.

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Attachment: signature.asc
Description: PGP signature

Reply via email to