Welcome! Log In Create A New Profile

Advanced

HP T5325 Thin Client U-Boot-2017.07-tld-1

Posted by bodhi 
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 10, 2019 08:46PM
kalehrl Wrote:
-------------------------------------------------------
> I actually tried to boot without kwboot and it
> worked miraculously!

I dont recall you report this :) that’s great.

> I remember I also moved
> rootfs to internal flash so I tried booting
> without USB flash drive and it also worked! I have
> no idea how it works now but not the last time I
> tried. Flash unlock command gives an error like
> before and I'm not sure environment is set up
> properly.

Could you post serial console log of the boot without kwboot. Just power up, interrupt serial console and

printenv
boot

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 11, 2019 12:36AM
Sure.
root@debian:/home/kalehrl# picocom /dev/ttyUSB0 -b 115200
picocom v1.7

port is        : /dev/ttyUSB0
flowcontrol    : none
baudrate is    : 115200
parity is      : none
databits are   : 8
escape is      : C-a
local echo is  : no
noinit is      : no
noreset is     : no
nolock is      : no
send_cmd is    : sz -vv
receive_cmd is : rz -vv
imap is        : 
omap is        : 
emap is        : crcrlf,delbs,

Terminal ready


U-Boot 2017.07-tld-1 (Nov 01 2017 - 00:58:19 -0700)
HP Thin Client T5325

SoC:   Kirkwood 88F6281_A1
SPI:   ready
DRAM:  512 MiB
WARNING: Caches not enabled
MMC:   
SF: Detected mx25l8005 with page size 256 Bytes, erase size 64 KiB, total 1 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0
88E3016 Initialized on egiga0
Hit any key to stop autoboot:  0
printenv:
T5325> printenv 
arcNumber=2097
arch=sandbox
baudrate=115200
board=sandbox
board_name=sandbox
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
boot_net_pci_enum=pci enum
boot_net_usb_start=usb start
boot_prefixes=/ /boot/
boot_script_dhcp=boot.scr.uimg
boot_scripts=boot.scr.uimg boot.scr
boot_targets=host1 host0 
bootcmd=run bootcmd_uenv; run scan_disk; run set_bootargs; run bootcmd_exec
bootcmd_exec=run load_uimage; if run load_initrd; then if run load_dtb; then bootm $load_uimage_addr $load_initrd_addr $load_dtb_addr; else bootm $load_uimage_addr $load_initrd_addr; fi; else if run load_dtb; then bootm $load_uimage_addr - $load_dtb_addr; else bootm $load_uimage_addr; fi; fi
bootcmd_host0=setenv devnum 0; run host_boot
bootcmd_host1=setenv devnum 1; run host_boot
bootcmd_uenv=run uenv_load; if test $uenv_loaded -eq 1; then run uenv_import; fi
bootdelay=10
bootdev=usb
bootm_size=0x10000000
cpu=sandbox
device=0:1
devices=usb ide
disks=0 1 2 3
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
dtb_file=/boot/dts/kirkwood-t5325.dtb
eth1addr=00:00:11:22:33:45
eth3addr=00:00:11:22:33:46
eth5addr=00:00:11:22:33:47
ethact=egiga0
ethaddr=52:3b:20:9c:11:51
fdt_addr_r=0xc00000
fileaddr=800000
filesize=ca0
host_boot=if host dev ${devnum}; then setenv devtype host; run scan_dev_for_boot_part; fi
if_netconsole=ping $serverip
ipaddr=192.168.0.231
kernel_addr_r=0x1000000
led_error=orange blinking
led_exit=green off
led_init=green blinking
load_dtb=echo loading DTB $dtb_file ...; load $bootdev $device $load_dtb_addr $dtb_file
load_dtb_addr=0x1c00000
load_initrd=echo loading uInitrd ...; load $bootdev $device $load_initrd_addr /boot/uInitrd
load_initrd_addr=0x1100000
load_uimage=echo loading uImage ...; load $bootdev $device $load_uimage_addr /boot/uImage
load_uimage_addr=0x800000
mainlineLinux=yes
mtdparts=mtdparts=spi0.0:512K(uboot),256K(sdd_firmware),64K(uboot_env),64K(permanent_uboot_env),64K(hp_env)
preboot_nc=run if_netconsole start_netconsole
pxefile_addr_r=0x2000
ramdisk_addr_r=0x2000000
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scan_disk=echo running scan_disk ...; scan_done=0; setenv scan_usb "usb start";  setenv scan_ide "ide reset";  setenv scan_mmc "mmc rescan"; for dev in $devices; do if test $scan_done -eq 0; then echo Scan device $dev; run scan_$dev; for disknum in $disks; do if test $scan_done -eq 0; then echo device $dev $disknum:1; if load $dev $disknum:1 $load_uimage_addr /boot/uImage 1; then scan_done=1; echo Found bootable drive on $dev $disknum; setenv device $disknum:1; setenv bootdev $dev; fi; fi; done; fi; done
scriptaddr=0x1000
serverip=192.168.0.220
set_bootargs=setenv bootargs console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 $mtdparts $custom_params
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version;
stderr=serial
stdin=serial
stdout=serial
uenv_addr=0x810000
uenv_import=echo importing envs ...; env import -t $uenv_addr $filesize
uenv_init_devices=setenv init_usb "usb start";  setenv init_ide "ide reset";  setenv init_mmc "mmc rescan"; for devtype in $devices; do run init_$devtype; done;
uenv_load=run uenv_init_devices; setenv uenv_loaded 0; for devtype in $devices;  do for disknum in 0; do run uenv_read_disk; done; done;
uenv_read=echo loading envs from $devtype $disknum ...; if load $devtype $disknum:1 $uenv_addr /boot/uEnv.txt; then setenv uenv_loaded 1; fi
uenv_read_disk=if test $devtype -eq mmc; then if $devtype part; then run uenv_read;  fi; else if $devtype part $disknum; then run uenv_read; fi;  fi
usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi
usb_ready_retry=15

Environment size: 4838/65532 bytes
boot:
T5325> boot
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 2 USB Device(s) found
       scanning usb for storage devices... 0 Storage Device(s) found

Reset IDE: Bus 0: OK Bus 1: not available  
  Device 0: Model: SM22 Firm: I052 Ser#: (03)5526888-20080228
            Type: Hard Disk
            Capacity: 463.6 MB = 0.4 GB (949536 x 512)
## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0
loading envs from usb 0 ...
** Bad device usb 0 **

Partition Map for IDE device 0  --   Partition Type: DOS

Part	Start Sector	Num Sectors	UUID		Type
  1	63        	949473    	00000000-01	83 Boot
running scan_disk ...
Scan device usb
device usb 0:1
** Bad device usb 0 **
device usb 1:1
** Bad device usb 1 **
device usb 2:1
** Bad device usb 2 **
device usb 3:1
** Bad device usb 3 **
Scan device ide

Reset IDE: Bus 0: OK Bus 1: not available  
  Device 0: Model: SM22 Firm: I052 Ser#: (03)5526888-20080228
            Type: Hard Disk
            Capacity: 463.6 MB = 0.4 GB (949536 x 512)
device ide 0:1
1 bytes read in 12 ms (0 Bytes/s)
Found bootable drive on ide 0
loading uImage ...
3876600 bytes read in 1404 ms (2.6 MiB/s)
loading uInitrd ...
7101070 bytes read in 2552 ms (2.7 MiB/s)
loading DTB /boot/dts/kirkwood-t5325.dtb ...
11927 bytes read in 22 ms (529.3 KiB/s)
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-4.14.1-kirkwood-tld-1
   Created:      2017-12-23  17:58:38 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    3876536 Bytes = 3.7 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-4.14.1-kirkwood-tld-1
   Created:      2017-12-23  17:59:12 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    7101006 Bytes = 6.8 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 01c00000
   Booting using the fdt blob at 0x1c00000
   Loading Kernel Image ... OK
   Loading Ramdisk to 0f93a000, end 0ffffa4e ... OK
   Loading Device Tree to 0f934000, end 0f939e96 ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 4.14.1-kirkwood-tld-1 (root@tldDebian) (gcc version 6.3.0 20170516 (Debian 6.3.0-18)) #1 PREEMPT Wed Nov 22 23:38:14 PST 2017
[    0.000000] CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=0005397f
[    0.000000] CPU: VIVT data cache, VIVT instruction cache
[    0.000000] OF: fdt: Machine model: HP t5325 Thin Client
[    0.000000] Memory policy: Data cache writeback
[    0.000000] random: fast init done
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 130048
[    0.000000] Kernel command line: console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 mtdparts=spi0.0:512K(uboot),256K(sdd_firmware),64K(uboot_env),64K(permanent_uboot_env),64K(hp_env)
[    0.000000] PID hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Memory: 499416K/524288K available (8192K kernel code, 714K rwdata, 2040K rodata, 1024K init, 285K bss, 24872K reserved, 0K cma-reserved)
[    0.000000] Virtual kernel memory layout:
[    0.000000]     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
[    0.000000]     fixmap  : 0xffc00000 - 0xfff00000   (3072 kB)
[    0.000000]     vmalloc : 0xe0800000 - 0xff800000   ( 496 MB)
[    0.000000]     lowmem  : 0xc0000000 - 0xe0000000   ( 512 MB)
[    0.000000]     modules : 0xbf000000 - 0xc0000000   (  16 MB)
[    0.000000]       .text : 0xc0008000 - 0xc0900000   (9184 kB)
[    0.000000]       .init : 0xc0c00000 - 0xc0d00000   (1024 kB)
[    0.000000]       .data : 0xc0d00000 - 0xc0db2aec   ( 715 kB)
[    0.000000]        .bss : 0xc0db94b0 - 0xc0e00a4c   ( 286 kB)
[    0.000000] Preemptible hierarchical RCU implementation.
[    0.000000] 	Tasks RCU enabled.
[    0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000000] clocksource: orion_clocksource: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 9556302233 ns
[    0.000009] sched_clock: 32 bits at 200MHz, resolution 5ns, wraps every 10737418237ns
[    0.000046] Switching to timer-based delay loop, resolution 5ns
[    0.000568] Console: colour dummy device 80x30
[    0.000606] Calibrating delay loop (skipped), value calculated using timer frequency.. 400.00 BogoMIPS (lpj=2000000)
[    0.000631] pid_max: default: 32768 minimum: 301
[    0.000816] Security Framework initialized
[    0.000970] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000995] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001902] CPU: Testing write buffer coherency: ok
[    0.002890] Setting up static identity map for 0x100000 - 0x100058
[    0.003157] mvebu-soc-id: MVEBU SoC ID=0x6281, Rev=0x3
[    0.003395] Hierarchical SRCU implementation.
[    0.006852] devtmpfs: initialized
[    0.011281] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.011309] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.011717] prandom: seed boundary self test passed
[    0.015902] prandom: 100 self tests passed
[    0.015915] pinctrl core: initialized pinctrl subsystem
[    0.017009] NET: Registered protocol family 16
[    0.017485] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.018980] cpuidle: using governor ladder
[    0.019049] cpuidle: using governor menu
[    0.019519] Feroceon L2: Enabling L2
[    0.019565] Feroceon L2: Cache support initialised.
[    0.019911] [Firmware Info]: /ocp@f1000000/ethernet-controller@72000/ethernet0-port@0: local-mac-address is not set
[    0.025354] No ATAGs?
[    0.033116] vgaarb: loaded
[    0.033419] SCSI subsystem initialized
[    0.033847] usbcore: registered new interface driver usbfs
[    0.033904] usbcore: registered new interface driver hub
[    0.033958] usbcore: registered new device driver usb
[    0.034908] clocksource: Switched to clocksource orion_clocksource
[    0.125279] VFS: Disk quotas dquot_6.6.0
[    0.125359] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    0.134120] NET: Registered protocol family 2
[    0.134864] TCP established hash table entries: 4096 (order: 2, 16384 bytes)
[    0.134975] TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
[    0.135029] TCP: Hash tables configured (established 4096 bind 4096)
[    0.135116] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    0.135140] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    0.135322] NET: Registered protocol family 1
[    0.135750] RPC: Registered named UNIX socket transport module.
[    0.135764] RPC: Registered udp transport module.
[    0.135772] RPC: Registered tcp transport module.
[    0.135779] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    0.136032] Unpacking initramfs...
[    0.771746] Freeing initrd memory: 6936K
[    0.771898] NetWinder Floating Point Emulator V0.97 (double precision)
[    0.772655] audit: initializing netlink subsys (disabled)
[    0.773089] Initialise system trusted keyrings
[    0.773134] Key type blacklist registered
[    0.773227] audit: type=2000 audit(0.760:1): state=initialized audit_enabled=0 res=1
[    0.773300] workingset: timestamp_bits=30 max_order=17 bucket_order=0
[    0.773384] zbud: loaded
[    0.774276] NFS: Registering the id_resolver key type
[    0.774301] Key type id_resolver registered
[    0.774309] Key type id_legacy registered
[    0.774327] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    0.774337] Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
[    0.774616] jffs2: version 2.2. (NAND) (SUMMARY)  �� 2001-2006 Red Hat, Inc.
[    0.774825] fuse init (API version 7.26)
[    0.775280] orangefs_debugfs_init: called with debug mask: :none: :0:
[    0.775450] orangefs_init: module version upstream loaded
[    0.775461] SGI XFS with ACLs, security attributes, realtime, no debug enabled
[    6.700484] jitterentropy: Initialization failed with host not compliant with requirements: 2
[    6.701282] Key type asymmetric registered
[    6.701295] Asymmetric key parser 'x509' registered
[    6.701367] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 249)
[    6.701379] io scheduler noop registered
[    6.701388] io scheduler deadline registered
[    6.701477] io scheduler cfq registered (default)
[    6.702817] kirkwood-pinctrl f1010000.pin-controller: registered pinctrl driver
[    6.704793] mvebu-pcie mbus@f1000000:pcie@82000000: PCI host bridge to bus 0000:00
[    6.704812] pci_bus 0000:00: root bus resource [io  0x1000-0xfffff]
[    6.704827] pci_bus 0000:00: root bus resource [mem 0xe0000000-0xefffffff]
[    6.704841] pci_bus 0000:00: root bus resource [bus 00-ff]
[    6.705491] PCI: bus0: Fast back to back transfers disabled
[    6.705517] pci 0000:00:01.0: bridge configuration invalid ([bus 00-00]), reconfiguring
[    6.705777] pci 0000:01:00.0: enabling Extended Tags
[    6.706005] pci 0000:01:00.0: vgaarb: VGA device added: decodes=io+mem,owns=none,locks=none
[    6.734982] PCI: bus1: Fast back to back transfers disabled
[    6.735053] pci 0000:00:01.0: BAR 14: assigned [mem 0xe0000000-0xe5ffffff]
[    6.735070] pci 0000:00:01.0: BAR 13: assigned [io  0x10000-0x10fff]
[    6.735089] pci 0000:01:00.0: BAR 0: assigned [mem 0xe0000000-0xe3ffffff pref]
[    6.735109] pci 0000:01:00.0: BAR 1: assigned [mem 0xe4000000-0xe403ffff]
[    6.735127] pci 0000:01:00.0: BAR 2: assigned [io  0x10000-0x1007f]
[    6.735143] pci 0000:00:01.0: PCI bridge to [bus 01]
[    6.735157] pci 0000:00:01.0:   bridge window [io  0x10000-0x10fff]
[    6.735173] pci 0000:00:01.0:   bridge window [mem 0xe0000000-0xe5ffffff]
[    6.735276] pcieport 0000:00:01.0: enabling device (0140 -> 0143)
[    6.735841] mv_xor f1060800.xor: Marvell shared XOR driver
[    6.795677] mv_xor f1060800.xor: Marvell XOR (Registers Mode): ( xor cpy intr )
[    6.795901] mv_xor f1060900.xor: Marvell shared XOR driver
[    6.855667] mv_xor f1060900.xor: Marvell XOR (Registers Mode): ( xor cpy intr )
[    6.856091] Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
[    6.857298] console [ttyS0] disabled
[    6.857363] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 27, base_baud = 12500000) is a 16550A
[    7.594656] console [ttyS0] enabled
[    7.604342] loop: module loaded
[    7.608110] sata_mv f1080000.sata: slots 32 ports 2
[    7.615599] scsi host0: sata_mv
[    7.619142] scsi host1: sata_mv
[    7.622477] ata1: SATA max UDMA/133 irq 35
[    7.626653] ata2: SATA max UDMA/133 irq 35
[    7.632204] m25p80 spi0.0: found mx25l8005, expected m25p80
[    7.637866] m25p80 spi0.0: mx25l8005 (1024 Kbytes)
[    7.642694] 5 cmdlinepart partitions found on MTD device spi0.0
[    7.648664] Creating 5 MTD partitions on "spi0.0":
[    7.653487] 0x000000000000-0x000000080000 : "uboot"
[    7.659331] 0x000000080000-0x0000000c0000 : "sdd_firmware"
[    7.665714] 0x0000000c0000-0x0000000d0000 : "uboot_env"
[    7.671777] 0x0000000d0000-0x0000000e0000 : "permanent_uboot_env"
[    7.678761] 0x0000000e0000-0x0000000f0000 : "hp_env"
[    7.685661] libphy: Fixed MDIO Bus: probed
[    7.690482] libphy: orion_mdio_bus: probed
[    7.699563] mv643xx_eth: MV-643xx 10/100/1000 ethernet driver version 1.4
[    7.707714] mv643xx_eth_port mv643xx_eth_port.0 eth0: port 0 with MAC address 52:3b:20:9c:11:51
[    7.716653] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    7.723234] ehci-pci: EHCI PCI platform driver
[    7.727840] ehci-orion: EHCI orion driver
[    7.732071] orion-ehci f1050000.ehci: EHCI Host Controller
[    7.737668] orion-ehci f1050000.ehci: new USB bus registered, assigned bus number 1
[    7.745561] orion-ehci f1050000.ehci: irq 31, io mem 0xf1050000
[    7.774940] orion-ehci f1050000.ehci: USB 2.0 started, EHCI 1.00
[    7.781223] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
[    7.788070] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    7.795349] usb usb1: Product: EHCI Host Controller
[    7.800249] usb usb1: Manufacturer: Linux 4.14.1-kirkwood-tld-1 ehci_hcd
[    7.806999] usb usb1: SerialNumber: f1050000.ehci
[    7.812284] hub 1-0:1.0: USB hub found
[    7.816149] hub 1-0:1.0: 1 port detected
[    7.820737] usbcore: registered new interface driver usb-storage
[    7.827131] mousedev: PS/2 mouse device common for all mice
[    7.833225] rtc-mv f1010300.rtc: rtc core: registered f1010300.rtc as rtc0
[    7.840346] i2c /dev entries driver
[    7.845866] hidraw: raw HID events driver (C) Jiri Kosina
[    7.851657] drop_monitor: Initializing network drop monitor service
[    7.858300] NET: Registered protocol family 17
[    7.862849] Key type dns_resolver registered
[    7.867897] registered taskstats version 1
[    7.872011] Loading compiled-in X.509 certificates
[    7.876932] zswap: loaded using pool lzo/zbud
[    7.902716] Key type big_key registered
[    7.916350] Key type encrypted registered
[    7.921734] rtc-mv f1010300.rtc: setting system clock to 2000-01-01 00:00:00 UTC (946684800)
[    8.124953] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl F300)
[    8.133562] ata1.00: ATA-7: SM224, I0521, max UDMA/133
[    8.138751] ata1.00: 949536 sectors, multi 0: LBA 
[    8.146002] ata1.00: configured for UDMA/133
[    8.160763] scsi 0:0:0:0: Direct-Access     ATA      SM224            1    PQ: 0 ANSI: 5
[    8.169874] sd 0:0:0:0: [sda] 949536 512-byte logical blocks: (486 MB/464 MiB)
[    8.177685] sd 0:0:0:0: [sda] Write Protect is off
[    8.182656] sd 0:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[    8.191883] usb 1-1: new high-speed USB device number 2 using orion-ehci
[    8.200215]  sda: sda1
[    8.203891] sd 0:0:0:0: [sda] Attached SCSI disk
[    8.395454] usb 1-1: New USB device found, idVendor=0424, idProduct=2514
[    8.402225] usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[    8.410106] hub 1-1:1.0: USB hub found
[    8.414071] hub 1-1:1.0: 4 ports detected
[    8.509413] ata2: SATA link down (SStatus 0 SControl F300)
[    8.528016] Freeing unused kernel memory: 1024K
Loading, please wait...
starting version 232
Begin: Loading essential drivers ... done.
Begin: Running /scripts/init-premount ... done.
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.
Begin: Running /scripts/local-premount ... done.
Begin: Will now check root file system ... fsck from util-linux 2.29.2
[/sbin/fsck.ext3 (1) -- /dev/sda1] fsck.ext3 -a -C0 /dev/sda1 
rootfs: clean, 8619/118784 files, 242534/474736 blocks
done.
[   19.525510] EXT4-fs (sda1): mounting ext3 file system using the ext4 subsystem
[   19.536107] EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts: (null)
done.
Begin: Running /scripts/local-bottom ... done.
Begin: Running /scripts/init-bottom ... done.
INIT: version 2.88 booting
[info] Using makefile-style concurrent boot in runlevel S.
[ ok ] Setting hostname to 'debian'...done.
[....] Starting the hotplug events dispatcher: systemd-udevdstarting version 232
. ok 
[ ok [   21.273600] input: gpio_keys as /devices/platform/gpio_keys/input/input0
                                                 done.
[....] Waiting for /dev to be fully populated...[   21.482397] xgifb: module is from the staging directory, the quality is unknown, you have been warned.
[   21.579113] xgifb 0000:01:00.0: Relocate IO address: 10000 [00010030]
[   21.655300] xgifb 0000:01:00.0: enabling device (0140 -> 0143)
[   21.661200] xgifb 0000:01:00.0: chipid = 32
[   21.665516] orion_wdt: Initial timeout 21 sec
[   21.782823] marvell-cesa f1030000.crypto: CESA device successfully registered
[   21.793859] xgifb: SR14=51 DramSzie 2000000 ChannelNum 1
[   21.820942] sd 0:0:0:0: Attached scsi generic sg0 type 0
[   21.905067] xgifb 0000:01:00.0: Framebuffer at 0xe0000000, mapped to 0xe1000000, size 32768k
[   21.913575] xgifb 0000:01:00.0: MMIO at 0xe4000000, mapped to 0xe3040000, size 256k
[   21.969515] asoc-simple-card sound: alc5621-hifi <-> i2s mapping ok
[   22.036679] attempt to access beyond end of device
[   22.041503] unknown-block(8,0): rw=0, want=949537, limit=949536
[   22.080171] attempt to access beyond end of device
[   22.101372] xgifb 0000:01:00.0: No or unknown bridge type detected
[   22.101385] xgifb: Default mode is 800x600x16 (60Hz)
[   22.163010] Console: switching to colour frame buffer device 100x37
[   22.165030] unknown-block(8,0): rw=0, want=949537, limit=949536
[   22.165041] Buffer I/O error on dev sda1, logical block 474736, async page read
done.
[ ok ] Activating swap:.
[   32.156382] EXT4-fs (sda1): re-mounted. Opts: errors=remount-ro
[ ok ] Will now activate lvm and md swap:done.
[info] Will now check all file systems.
fsck from util-linux 2.29.2
Checking all file systems.
LABEL=rootfs is mounted
[ ok ] Done checking file systems. A log is being saved in /var/log/fsck/checkfs if that location is writable..
[....] Cleaning [   33.381692] random: crng init done
[ ok mporary files...[....] Cleaning /tmp...done.
[ ok .
[ ok ] Will now mount local filesystems:.
[ ok ] Will now activate swapfile swap:done.
[ ok ] Checking minimum space in /tmp...done.
[ ok ] Cleaning up temporary files....
[ ok ] Setting kernel variables...done.
[ ok ] Initializing random number generator...done.
[   34.795691] mv643xx_eth_port mv643xx_eth_port.0 eth0: link up, 100 Mb/s, full duplex, flow control disabled
[....] Configuring network interfaces...Internet Systems Consortium DHCP Client 4.3.5
Copyright 2004-2016 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/eth0/52:3b:20:9c:11:51
Sending on   LPF/eth0/52:3b:20:9c:11:51
Sending on   Socket/fallback
DHCPREQUEST of 192.168.1.32 on eth0 to 255.255.255.255 port 67
DHCPACK of 192.168.1.32 from 192.168.1.1
bound to 192.168.1.32 -- renewal in 255030 seconds.
done.
[ ok ] Cleaning up temporary files....
INIT: Entering runlevel: 2
[info] Using makefile-style concurrent boot in runlevel 2.
[....] Starting busybox' syslogd implementation : syslogdStarting /sbin/syslogd...
1204 (syslogd)
. ok 
[   36.881394] NET: Registered protocol family 10
[   36.888919] Segment Routing with IPv6
Starting Dropbear SSH server: dropbear.
[....] Starting busybox' klogd implementation : klogdStarting /sbin/klogd...
1203 (klogd)
. ok 
[ ok ] Starting FTP server: vsftpd.
[....] Running local boot scripts (/etc/rc.local)<13>Jan  1 01:00:35 root[1317]: Bring eth0 down/up to work around problem negotiating 100Mbs link
Killed old client process
Internet Systems Consortium DHCP Client 4.3.5
Copyright 2004-2016 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/eth0/52:3b:20:9c:11:51
Sending on   LPF/eth0/52:3b:20:9c:11:51
Sending on   Socket/fallback
DHCPRELEASE on eth0 to 192.168.1.1 port 67
Internet Systems Consortium DHCP Client 4.3.5
Copyright 2004-2016 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

[   44.655277] mv643xx_eth_port mv643xx_eth_port.0 eth0: link up, 100 Mb/s, full duplex, flow control disabled
Listening on LPF/eth0/52:3b:20:9c:11:51
Sending on   LPF/eth0/52:3b:20:9c:11:51
Sending on   Socket/fallback
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 6
DHCPREQUEST of 192.168.1.32 on eth0 to 255.255.255.255 port 67
DHCPOFFER of 192.168.1.32 from 192.168.1.1
DHCPACK of 192.168.1.32 from 192.168.1.1
bound to 192.168.1.32 -- renewal in 282664 seconds.
. ok 

Debian GNU/Linux 9 debian ttyS0

debian login: root
Password: 
Linux debian 4.14.1-kirkwood-tld-1 #1 PREEMPT Wed Nov 22 23:38:14 PST 2017 armv5tel

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
root@debian:~#
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 11, 2019 03:48AM
kalehrl,

That looks fantastic! you are basically done and can use this box for production.

The issue about listing and modifying envs in Debian is not that important, because you are running the latest u-boot. Envs can be manipultaled in serial console or using uEnv.txt in the /boot directory should you want to disconnect serial console.

So I'd say there is no reason to put it on the shelf.

We can figure out the SPI mtd issue in Debian later. It is not a show stopper by any mean.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 11, 2019 07:42AM
I have no idea how all this happened.
I was sure I didn't install the latest uboot correctly and in the process bricked the box.
After a year, I tried booting the box and it started working fine with the latest uboot.
It boggles the mind!
I went back to the previous posts and clearly see the old uboot header from 2016.

I'm trying to slim down the rootfs even further. Now it's around 212MB.
Are all of these files in the /boot folder necessary:
initrd.img-4.14.1-kirkwood-tld-1
uImage
System.map-4.14.1-kirkwood-tld-1
uInitrd
config-4.14.1-kirkwood-tld-1
vmlinuz-4.14.1-kirkwood-tld-1
In /boot/dts I erased them all and left just kirkwood-t5325.dtb.

Also, I would like to disable all unnecessary services to save cpu cycles.
You mentioned disabling net console using uEnv.txt.
Does it have something to do with cpu usage after booting?
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 11, 2019 08:03AM
kalehrl,

> I have no idea how all this happened.
> I was sure I didn't install the latest uboot
> correctly and in the process bricked the box.
> After a year, I tried booting the box and it
> started working fine with the latest uboot.
> It boggles the mind!

:)

> I went back to the previous posts and clearly see
> the old uboot header from 2016.
>
> I'm trying to slim down the rootfs even further.
> Now it's around 212MB.
> Are all of these files in the /boot folder
> necessary:
>
> initrd.img-4.14.1-kirkwood-tld-1
> uImage
> System.map-4.14.1-kirkwood-tld-1
> uInitrd
> config-4.14.1-kirkwood-tld-1
> vmlinuz-4.14.1-kirkwood-tld-1
>
> In /boot/dts I erased them all and left just
> kirkwood-t5325.dtb.

That's unecessary, but would not hurt anything. I would just leave all DTBs in the /boot/dts. In case you want to reuse this rootfs for a different Kirkwood box.


> Also, I would like to disable all unnecessary
> services to save cpu cycles.
> You mentioned disabling net console using
> uEnv.txt.
> Does it have something to do with cpu usage after
> booting?

No, netconsole only relevant during boot. So you can ignore it.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 11, 2019 12:54PM
Again it lost the settings.
root@debian:/home/kalehrl# picocom /dev/ttyUSB0 -b 115200
picocom v1.7

port is        : /dev/ttyUSB0
flowcontrol    : none
baudrate is    : 115200
parity is      : none
databits are   : 8
escape is      : C-a
local echo is  : no
noinit is      : no
noreset is     : no
nolock is      : no
send_cmd is    : sz -vv
receive_cmd is : rz -vv
imap is        : 
omap is        : 
emap is        : crcrlf,delbs,

Terminal ready
�

U-Boot 2017.07-tld-1 (Nov 01 2017 - 00:58:19 -0700)
HP Thin Client T5325

SoC:   Kirkwood 88F6281_A1
SPI:   ready
DRAM:  512 MiB
WARNING: Caches not enabled
MMC:   
SF: Detected mx25l8005 with page size 256 Bytes, erase size 64 KiB, total 1 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0
88E3016 Initialized on egiga0
T5325>
Typing boot won't boot the box from internal flash nor from the USB drive.
The printenv lists borked env entries like the ones before.
It's as if it sometimes can and sometimes can't read the contents of the chip where they are saved:
arch=sandbox
baudrate=115200
board=sandbox
board_name=sandbox
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
boot_net_pci_enum=pci enum
boot_net_usb_start=usb start
boot_prefixes=/ /boot/
boot_script_dhcp=boot.scr.uimg
boot_scripts=boot.scr.uimg boot.scr
boot_targets=host1 host0 
bootcmd_host0=setenv devnum 0; run host_boot
bootcmd_host1=setenv devnum 1; run host_boot
bootdelay=2
bootm_size=0x10000000
cpu=sandbox
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
eth1addr=00:00:11:22:33:45
eth3addr=00:00:11:22:33:46
eth5addr=00:00:11:22:33:47
ethact=egiga0
ethaddr=52:3b:20:9c:11:51
fdt_addr_r=0xc00000
host_boot=if host dev ${devnum}; then setenv devtype host; run scan_dev_for_boot_part; fi
ipaddr=1.2.3.4
kernel_addr_r=0x1000000
pxefile_addr_r=0x2000
ramdisk_addr_r=0x2000000
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scriptaddr=0x1000
stderr=serial
stdin=serial
stdout=serial
usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi

Environment size: 2099/65532 bytes
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 11, 2019 05:29PM
kalehrl,

> arch=sandbox
> board=sandbox
> board_name=sandbox

The above is apparently wrong. Note that the sandbox is the board which is possible in memory only.

So it had silently failed to use the flash. If the flash had problem, it would have reported a CRC error.

It is a weird problem that I need to think about, perhaps look at u-boot source code to see why.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 12, 2019 02:12AM
bodhi Wrote:
-------------------------------------------------------
> kalehrl,
>
> Try this script loading procedure:
>
> https://forum.doozan.com/read.php?3,29362,29390#msg-29390
>
> 1. Note the difference in DTB file. This procedure
> was written for the GoFlex Net.
>
>
Quote

Adjust the other specific envs and then
> boot the rootfs:
> setenv devices 'usb ide'
> setenv ethaddr xx:xx:xx:xx:xx:xx
> setenv dtb_file
> '/boot/dts/kirkwood-goflexnet.dtb'
> boot
>
> So your DTB file would be:
>
> setenv dtb_file '/boot/dts/kirkwood-t5325.dtb'
>
>
> 2. And in your case, don't use kwboot. Just boot
> from the u-boot-2016.05-tld-1 in NAND.

I tried this but when I type source 0x800000, I get:
## Executing script at 00800000
Bad data crc
So the chip may be bad after all.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 12, 2019 06:06AM
kalehrl ,

> I tried this but when I type source 0x800000, I
> get:
>
> ## Executing script at 00800000
> Bad data crc
>
> So the chip may be bad after all.

Not really. That did not prove the flash is bad.

I'll be back with more suggestion.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 12, 2019 05:48PM
kalehrl,

Let's try this approach:

https://forum.doozan.com/read.php?3,83124,83124#msg-83124

But skip Step 2, since you are booting with serial console.

Quote

2. Modify the envs in uEnv.txt to make it usable in netconsole (that you already has set up and working).

Remove the following lines in uEnv.txt

ethaddr=52:3b:20:9c:11:51
ipaddr=192.168.0.231
serverip=192.168.0.220
stderr=serial
stdin=serial
stdout=serial

After you can boot into Debian, reboot.

And come back to serial console, repeat the procedure one more time (skip Step 2 again). But also save the envs at Step 5 before boot

Quote

5. At this point your current u-boot envs are set to a correct set of u-boot envs to boot the USB rootfs (If you want confirmation, post the log of netconsole up until this point here).

Go ahead and boot

saveenv
boot

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 13, 2019 12:39PM
Hi bodhi
It seems to have worked out fine.
When I issued saveenv command, there were some messages about erasing spi flash and it finished without any errors. :D
Upon reboot, it booted fine in Debian.
However, when in Debian I issue:
cat /proc/mtd
I get:
dev:    size   erasesize  name
mtd0: 00080000 00010000 "u-boot"
mtd1: 00040000 00010000 "SSD firmware"
mtd2: 00010000 00010000 "u-boot env"
mtd3: 00010000 00010000 "permanent u-boot env"
mtd4: 00010000 00010000 "permanent u-boot env"
Which is I believe wrong.

I fixed it by changing the appropriate line in uEnv.txt to:
mtdparts=mtdparts=spi0.0:512K(uboot),256K(sdd_firmware),64K(uboot_env),64K(permanent_uboot_env),64K(hp_env)

I also added the correct MAC address in the file and imported it.
It seems that it is impossible to use fw_setenv command which gives crc error after which the box doesn't boot and it is necessary to import the uEnv.txt via serial console.
For example, I tried this command:
fw_setenv mtdparts 'mtdparts=spi0.0:512K(uboot),256K(sdd_firmware),64K(uboot_env),64K(permanent_uboot_env),64K(hp_env)'
and there was crc error.



Edited 2 time(s). Last edit at 05/13/2019 01:38PM by kalehrl.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 13, 2019 06:29PM
kalehrl,


> It seems to have worked out fine.
> When I issued saveenv command, there were some
> messages about erasing spi flash and it finished
> without any errors. :D
> Upon reboot, it booted fine in Debian.

Cool!

> It seems that it is impossible to use fw_setenv
> command which gives crc error after which the box
> doesn't boot and it is necessary to import the
> uEnv.txt via serial console.

Let's stay with serial console. And avoid using fw_setenv until we know how to define the mtds for the kernel to use. I think it might have something to do with the flash type (ie. different sector size or something like that).

As long as it works in u-boot, then we know the flash is working fine.

I'll look at this when I have a chance.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 14, 2019 03:37AM
kalehrl,

I think I see the possible problem when you said you saw this in previous post

dev:    size   erasesize  name
mtd0: 00080000 00010000 "u-boot"
mtd1: 00040000 00010000 "SSD firmware"
mtd2: 00010000 00010000 "u-boot env"
mtd3: 00010000 00010000 "permanent u-boot env"
mtd4: 00010000 00010000 "permanent u-boot env"

That is not what we want to see (even though you fixed mtdparts envs, it might not work).

Please boot normally with serial console and then

cat /proc/mtd
cat /etc/fw_env.config
fw_printenv
And post the entire serial log here. I want to compare it with my log.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 14, 2019 07:11AM
U-Boot 2017.07-tld-1 (Nov 01 2017 - 00:58:19 -0700)
HP Thin Client T5325

SoC:   Kirkwood 88F6281_A1
SPI:   ready
DRAM:  512 MiB
WARNING: Caches not enabled
MMC:   
SF: Detected mx25l8005 with page size 256 Bytes, erase size 64 KiB, total 1 MiB
In:    serial
Out:   serial
Err:   serial
Net:   egiga0
88E3016 Initialized on egiga0
Hit any key to stop autoboot:  0 
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 3 USB Device(s) found
       scanning usb for storage devices... 
Use USB retry period from the environment: 15 second(s)
1 Storage Device(s) found

Reset IDE: Bus 0: OK Bus 1: not available  
  Device 0: Model: SM22 Firm: I052 Ser#: (03)5526888-20080228
            Type: Hard Disk
            Capacity: 463.6 MB = 0.4 GB (949536 x 512)
Unknown command 'mmc' - try 'help'

Partition Map for USB device 0  --   Partition Type: DOS

Part	Start Sector	Num Sectors	UUID		Type
  1	2048      	125302784 	0017b630-01	83

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0

## Unknown partition table type 0
loading envs from usb 0 ...
** File not found /boot/uEnv.txt **

Partition Map for IDE device 0  --   Partition Type: DOS

Part	Start Sector	Num Sectors	UUID		Type
  1	63        	949473    	00000000-01	83 Boot
Unknown command 'mmc' - try 'help'
running scan_disk ...
Scan device usb
device usb 0:1
1 bytes read in 538 ms (0 Bytes/s)
Found bootable drive on usb 0
loading uImage ...
4551232 bytes read in 679 ms (6.4 MiB/s)
loading uInitrd ...
7422440 bytes read in 697 ms (10.2 MiB/s)
loading DTB /boot/dts/kirkwood-t5325.dtb ...
11919 bytes read in 646 ms (17.6 KiB/s)
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-5.1.0-kirkwood-tld-1
   Created:      2000-01-01   1:04:48 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4551168 Bytes = 4.3 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-5.1.0-kirkwood-tld-1
   Created:      2000-01-01   1:05:15 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    7422376 Bytes = 7.1 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 01c00000
   Booting using the fdt blob at 0x1c00000
   Loading Kernel Image ... OK
   Loading Ramdisk to 0f8eb000, end 0ffff1a8 ... OK
   Loading Device Tree to 0f8e5000, end 0f8eae8e ... OK
Using machid 0x831 from environment

Starting kernel ...

Uncompressing Linux... done, booting the kernel.
[    0.000000][    T0] Booting Linux on physical CPU 0x0
[    0.000000][    T0] Linux version 5.1.0-kirkwood-tld-1 (root@tldDebian) (gcc version 6.3.0 20170516 (Debian 6.3.0-18+deb9u1)) #1 PREEMPT Tue May 7 00:16:02 PDT 2019
[    0.000000][    T0] CPU: Feroceon 88FR131 [56251311] revision 1 (ARMv5TE), cr=0005397f
[    0.000000][    T0] CPU: VIVT data cache, VIVT instruction cache
[    0.000000][    T0] OF: fdt: Machine model: HP t5325 Thin Client
[    0.000000][    T0] Memory policy: Data cache writeback
[    0.000000][    T0] random: get_random_bytes called from start_kernel+0x78/0x4f4 with crng_init=0
[    0.000000][    T0] Built 1 zonelists, mobility grouping on.  Total pages: 130048
[    0.000000][    T0] Kernel command line: console=ttyS0,115200 root=LABEL=rootfs rootdelay=10 mtdparts=spi0.0:512K(uboot),256K(sdd_firmware),64K(uboot_env),64K(permanent_uboot_env),64K(hp_env)
[    0.000000][    T0] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[    0.000000][    T0] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000][    T0] Memory: 496960K/524288K available (9216K kernel code, 844K rwdata, 3012K rodata, 1024K init, 290K bss, 27328K reserved, 0K cma-reserved)
[    0.000000][    T0] rcu: Preemptible hierarchical RCU implementation.
[    0.000000][    T0] 	Tasks RCU enabled.
[    0.000000][    T0] rcu: RCU calculated value of scheduler-enlistment delay is 10 jiffies.
[    0.000000][    T0] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000000][    T0] clocksource: orion_clocksource: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 9556302233 ns
[    0.000008][    T0] sched_clock: 32 bits at 200MHz, resolution 5ns, wraps every 10737418237ns
[    0.000046][    T0] Switching to timer-based delay loop, resolution 5ns
[    0.000816][    T0] Console: colour dummy device 80x30
[    0.000869][    T0] Calibrating delay loop (skipped), value calculated using timer frequency.. 400.00 BogoMIPS (lpj=2000000)
[    0.000895][    T0] pid_max: default: 32768 minimum: 301
[    0.001279][    T0] LSM: Security Framework initializing
[    0.001472][    T0] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.001499][    T0] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.002372][    T0] *** VALIDATE proc ***
[    0.002607][    T0] *** VALIDATE cgroup1 ***
[    0.002632][    T0] *** VALIDATE cgroup2 ***
[    0.002733][    T0] CPU: Testing write buffer coherency: ok
[    0.004411][    T1] Setting up static identity map for 0x100000 - 0x100058
[    0.004705][    T1] mvebu-soc-id: MVEBU SoC ID=0x6281, Rev=0x3
[    0.004990][    T1] rcu: Hierarchical SRCU implementation.
[    0.008316][    T1] devtmpfs: initialized
[    0.013314][    T1] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.013347][    T1] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.013587][    T1] prandom: seed boundary self test passed
[    0.017775][    T1] prandom: 100 self tests passed
[    0.017790][    T1] pinctrl core: initialized pinctrl subsystem
[    0.019179][    T1] NET: Registered protocol family 16
[    0.019704][    T1] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.020647][    T1] audit: initializing netlink subsys (disabled)
[    0.021915][   T14] audit: type=2000 audit(0.020:1): state=initialized audit_enabled=0 res=1
[    0.022036][    T1] cpuidle: using governor ladder
[    0.022113][    T1] cpuidle: using governor menu
[    0.022623][    T1] Feroceon L2: Enabling L2
[    0.022673][    T1] Feroceon L2: Cache support initialised.
[    0.023039][    T1] [Firmware Info]: /ocp@f1000000/ethernet-controller@72000/ethernet0-port@0: local-mac-address is not set
[    0.029129][    T1] No ATAGs?
[    0.038290][    T1] vgaarb: loaded
[    0.038645][    T1] SCSI subsystem initialized
[    0.039122][    T1] usbcore: registered new interface driver usbfs
[    0.039187][    T1] usbcore: registered new interface driver hub
[    0.039247][    T1] usbcore: registered new device driver usb
[    0.039428][    T1] pps_core: LinuxPPS API ver. 1 registered
[    0.039440][    T1] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    0.039468][    T1] PTP clock support registered
[    0.040529][    T1] clocksource: Switched to clocksource orion_clocksource
[    1.063406][    T1] VFS: Disk quotas dquot_6.6.0
[    1.063499][    T1] VFS: Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
[    1.073236][    T1] NET: Registered protocol family 2
[    1.074071][    T1] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes)
[    1.074107][    T1] TCP established hash table entries: 4096 (order: 2, 16384 bytes)
[    1.074166][    T1] TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
[    1.074219][    T1] TCP: Hash tables configured (established 4096 bind 4096)
[    1.074314][    T1] UDP hash table entries: 256 (order: 0, 4096 bytes)
[    1.074341][    T1] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
[    1.074556][    T1] NET: Registered protocol family 1
[    1.075204][    T1] RPC: Registered named UNIX socket transport module.
[    1.075218][    T1] RPC: Registered udp transport module.
[    1.075227][    T1] RPC: Registered tcp transport module.
[    1.075236][    T1] RPC: Registered tcp NFSv4.1 backchannel transport module.
[    1.075490][    T1] Unpacking initramfs...
[    1.751386][    T1] Freeing initrd memory: 7252K
[    1.751547][    T1] NetWinder Floating Point Emulator V0.97 (double precision)
[    1.752711][    T1] Initialise system trusted keyrings
[    1.752767][    T1] Key type blacklist registered
[    1.752992][    T1] workingset: timestamp_bits=30 max_order=17 bucket_order=0
[    1.753099][    T1] zbud: loaded
[    1.754185][    T1] NFS: Registering the id_resolver key type
[    1.754218][    T1] Key type id_resolver registered
[    1.754228][    T1] Key type id_legacy registered
[    1.754249][    T1] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[    1.754261][    T1] Installing knfsd (copyright (C) 1996 okir@monad.swb.de).
[    1.754561][    T1] jffs2: version 2.2. (NAND) (SUMMARY)  �� 2001-2006 Red Hat, Inc.
[    1.754787][    T1] fuse init (API version 7.29)
[    1.755177][    T1] orangefs_debugfs_init: called with debug mask: :none: :0:
[    1.755362][    T1] orangefs_init: module version upstream loaded
[    1.755375][    T1] SGI XFS with ACLs, security attributes, realtime, scrub, no debug enabled
[    2.550537][    C0] random: fast init done
[    7.773859][   T82] alg: No test for lzo-rle (lzo-rle-generic)
[    7.778102][   T84] alg: No test for lzo-rle (lzo-rle-scomp)
[    7.845618][    T1] Key type asymmetric registered
[    7.845637][    T1] Asymmetric key parser 'x509' registered
[    7.845707][    T1] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 247)
[    7.847203][    T1] kirkwood-pinctrl f1010000.pin-controller: registered pinctrl driver
[    7.849137][    T1] mvebu-pcie mbus@f1000000:pcie-controller@82000000: PCI host bridge to bus 0000:00
[    7.849162][    T1] pci_bus 0000:00: root bus resource [bus 00-ff]
[    7.849178][    T1] pci_bus 0000:00: root bus resource [mem 0xe0000000-0xefffffff]
[    7.849192][    T1] pci_bus 0000:00: root bus resource [io  0x1000-0xeffff]
[    7.850852][    T1] PCI: bus0: Fast back to back transfers disabled
[    7.850882][    T1] pci 0000:00:01.0: bridge configuration invalid ([bus 00-00]), reconfiguring
[    7.851179][    T1] pci 0000:01:00.0: enabling Extended Tags
[    7.851443][    T1] pci 0000:01:00.0: vgaarb: VGA device added: decodes=io+mem,owns=none,locks=none
[    7.881655][    T1] PCI: bus1: Fast back to back transfers disabled
[    7.881888][    T1] pci 0000:00:01.0: BAR 14: assigned [mem 0xe0000000-0xe5ffffff]
[    7.881907][    T1] pci 0000:00:01.0: BAR 13: assigned [io  0x10000-0x10fff]
[    7.881923][    T1] pci 0000:00:01.0: BAR 6: assigned [mem 0xe6000000-0xe60007ff pref]
[    7.881944][    T1] pci 0000:01:00.0: BAR 0: assigned [mem 0xe0000000-0xe3ffffff pref]
[    7.881964][    T1] pci 0000:01:00.0: BAR 1: assigned [mem 0xe4000000-0xe403ffff]
[    7.881983][    T1] pci 0000:01:00.0: BAR 2: assigned [io  0x10000-0x1007f]
[    7.882000][    T1] pci 0000:00:01.0: PCI bridge to [bus 01]
[    7.882015][    T1] pci 0000:00:01.0:   bridge window [io  0x10000-0x10fff]
[    7.882033][    T1] pci 0000:00:01.0:   bridge window [mem 0xe0000000-0xe5ffffff]
[    7.882149][    T1] pcieport 0000:00:01.0: enabling device (0140 -> 0143)
[    7.882732][    T1] mv_xor f1060800.xor: Marvell shared XOR driver
[    7.941333][    T1] mv_xor f1060800.xor: Marvell XOR (Registers Mode): ( xor cpy intr )
[    7.941588][    T1] mv_xor f1060900.xor: Marvell shared XOR driver
[    8.001324][    T1] mv_xor f1060900.xor: Marvell XOR (Registers Mode): ( xor cpy intr )
[    8.001766][    T1] Serial: 8250/16550 driver, 2 ports, IRQ sharing disabled
[    8.003052][    T1] printk: console [ttyS0] disabled
[    8.003122][    T1] f1012000.serial: ttyS0 at MMIO 0xf1012000 (irq = 27, base_baud = 12500000) is a 16550A
[    8.815299][    T1] printk: console [ttyS0] enabled
[    8.827639][    T1] loop: module loaded
[    8.832112][    T1] sata_mv f1080000.sata: slots 32 ports 2
[    8.840424][    T1] scsi host0: sata_mv
[    8.844900][    T1] scsi host1: sata_mv
[    8.849038][    T1] ata1: SATA max UDMA/133 irq 35
[    8.853911][    T1] ata2: SATA max UDMA/133 irq 35
[    8.860287][    T1] m25p80 spi0.0: found mx25l8005, expected m25p80
[    8.866661][    T1] m25p80 spi0.0: mx25l8005 (1024 Kbytes)
[    8.872214][    T1] 5 cmdlinepart partitions found on MTD device spi0.0
[    8.878859][    T1] Creating 5 MTD partitions on "spi0.0":
[    8.884404][    T1] 0x000000000000-0x000000080000 : "uboot"
[    8.891347][    T1] 0x000000080000-0x0000000c0000 : "sdd_firmware"
[    8.898757][    T1] 0x0000000c0000-0x0000000d0000 : "uboot_env"
[    8.905946][    T1] 0x0000000d0000-0x0000000e0000 : "permanent_uboot_env"
[    8.914007][    T1] 0x0000000e0000-0x0000000f0000 : "hp_env"
[    8.922087][    T1] libphy: Fixed MDIO Bus: probed
[    8.927662][    T1] libphy: orion_mdio_bus: probed
[    8.937673][    T1] mv643xx_eth: MV-643xx 10/100/1000 ethernet driver version 1.4
[    8.945773][    T1] mv643xx_eth_port mv643xx_eth_port.0: DMA mask not set
[    8.953469][    T1] mv643xx_eth_port mv643xx_eth_port.0 eth0: port 0 with MAC address f4:ce:46:23:f6:83
[    8.963155][    T1] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    8.970448][    T1] ehci-pci: EHCI PCI platform driver
[    8.975728][    T1] ehci-orion: EHCI orion driver
[    8.980712][    T1] orion-ehci f1050000.ehci: EHCI Host Controller
[    8.986961][    T1] orion-ehci f1050000.ehci: new USB bus registered, assigned bus number 1
[    8.995577][    T1] orion-ehci f1050000.ehci: irq 31, io mem 0xf1050000
[    9.030565][    T1] orion-ehci f1050000.ehci: USB 2.0 started, EHCI 1.00
[    9.037564][    T1] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002, bcdDevice= 5.01
[    9.046594][    T1] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
[    9.054572][    T1] usb usb1: Product: EHCI Host Controller
[    9.060169][    T1] usb usb1: Manufacturer: Linux 5.1.0-kirkwood-tld-1 ehci_hcd
[    9.067529][    T1] usb usb1: SerialNumber: f1050000.ehci
[    9.073577][    T1] hub 1-0:1.0: USB hub found
[    9.078114][    T1] hub 1-0:1.0: 1 port detected
[    9.083552][    T1] usbcore: registered new interface driver usb-storage
[    9.090752][    T1] mousedev: PS/2 mouse device common for all mice
[    9.097601][    T1] rtc-mv f1010300.rtc: registered as rtc0
[    9.103450][    T1] i2c /dev entries driver
[    9.109706][    T1] hidraw: raw HID events driver (C) Jiri Kosina
[    9.116266][    T1] drop_monitor: Initializing network drop monitor service
[    9.123734][    T1] NET: Registered protocol family 17
[    9.129174][    T1] Key type dns_resolver registered
[    9.135036][    T1] registered taskstats version 1
[    9.139887][    T1] Loading compiled-in X.509 certificates
[    9.145524][    T1] zswap: loaded using pool lzo/zbud
[    9.189555][    T1] Key type big_key registered
[    9.209580][    T1] Key type encrypted registered
[    9.216339][    T1] rtc-mv f1010300.rtc: setting system clock to 2000-01-01T00:00:00 UTC (946684800)
[    9.350572][  T111] ata1: SATA link up 3.0 Gbps (SStatus 123 SControl F300)
[    9.360074][  T111] ata1.00: ATA-7: SM224, I0521, max UDMA/133
[    9.365965][  T111] ata1.00: 949536 sectors, multi 0: LBA 
[    9.373944][  T111] ata1.00: configured for UDMA/133
[    9.389448][    T7] scsi 0:0:0:0: Direct-Access     ATA      SM224            1    PQ: 0 ANSI: 5
[    9.399303][  T115] sd 0:0:0:0: [sda] 949536 512-byte logical blocks: (486 MB/464 MiB)
[    9.407862][  T115] sd 0:0:0:0: [sda] Write Protect is off
[    9.413591][  T115] sd 0:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[    9.425139][  T115]  sda: sda1
[    9.429728][  T115] sd 0:0:0:0: [sda] Attached SCSI disk
[    9.450569][   T15] usb 1-1: new high-speed USB device number 2 using orion-ehci
[    9.651092][   T15] usb 1-1: New USB device found, idVendor=0424, idProduct=2514, bcdDevice= 0.00
[    9.660044][   T15] usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=0
[    9.668615][   T15] hub 1-1:1.0: USB hub found
[    9.673331][   T15] hub 1-1:1.0: 4 ports detected
[    9.744086][  T113] ata2: SATA link down (SStatus 0 SControl F300)
[    9.763298][    T1] Freeing unused kernel memory: 1024K
[    9.769158][    T1] Checked W+X mappings: passed, no W+X pages found
[    9.775567][    T1] Run /init as init process
Loading, please wait...
starting version 232
[    9.881206][  T155] random: systemd-udevd: uninitialized urandom read (16 bytes read)
[    9.889753][  T155] random: systemd-udevd: uninitialized urandom read (16 bytes read)
[    9.908406][  T156] random: udevadm: uninitialized urandom read (16 bytes read)
[    9.990628][   T15] usb 1-1.3: new high-speed USB device number 3 using orion-ehci
[   10.166231][   T15] usb 1-1.3: New USB device found, idVendor=090c, idProduct=1000, bcdDevice=11.00
[   10.182712][   T15] usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[   10.200365][   T15] usb 1-1.3: Product: Flash Drive
[   10.210151][   T15] usb 1-1.3: Manufacturer: Samsung
[   10.219141][   T15] usb 1-1.3: SerialNumber: 0374716020010662
[   10.232102][   T15] usb-storage 1-1.3:1.0: USB Mass Storage device detected
[   10.250645][   T15] scsi host2: usb-storage 1-1.3:1.0
[   10.751240][  T158] usbcore: registered new interface driver uas
Begin: Loading essential drivers ... done.
[   11.629188][  T115] scsi 2:0:0:0: Direct-Access     Samsung  Flash Drive      1100 PQ: 0 ANSI: 6
[   11.644904][   T34] sd 2:0:0:0: [sdb] 125304832 512-byte logical blocks: (64.2 GB/59.8 GiB)
[   11.660024][   T34] sd 2:0:0:0: [sdb] Write Protect is off
[   11.671531][   T34] sd 2:0:0:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[   11.696868][   T34]  sdb: sdb1
[   11.707762][   T34] sd 2:0:0:0: [sdb] Attached SCSI removable disk
Begin: Running /scripts/init-premount ... done.
Begin: Mounting root file system ... Begin: Running /scripts/local-top ... done.
Begin: Running /scripts/local-premount ... done.
Begin: Will now check root file system ... fsck from util-linux 2.29.2
[/sbin/fsck.ext4 (1) -- /dev/sdb1] fsck.ext4 -a -C0 /dev/sdb1 
rootfs: clean, 8726/3915776 files, 380212/15662848 blocks
done.
[   21.049106][  T193] EXT4-fs (sdb1): mounted filesystem with ordered data mode. Opts: (null)
done.
Begin: Running /scripts/local-bottom ... done.
Begin: Running /scripts/init-bottom ... done.
INIT: version 2.88 booting
[info] Using makefile-style concurrent boot in runlevel S.
[ ok ] Setting hostname to 'debian'...done.
[....] Starting the hotplug events dispatcher: systemd-udevdstarting version 232
. ok 
[....] Synthesizing the initial hotplug events...[   23.243919][  T407] input: gpio_keys as /devices/platform/gpio_keys/input/input0
[ ok                                             done.
[....] Waiting for /dev to be fully populated...[   23.815171][  T407] orion_wdt: Initial timeout 21 sec
[   23.828937][    C0] random: crng init done
[   23.833110][    C0] random: 7 urandom warning(s) missed due to ratelimiting
[   23.935408][  T414] marvell-cesa f1030000.crypto: CESA device successfully registered
[   23.954243][  T406] sd 0:0:0:0: Attached scsi generic sg0 type 0
[   24.010676][  T406] sd 2:0:0:0: Attached scsi generic sg1 type 0
done.
[ ok ] Activating swap:.
[   34.360790][  T594] EXT4-fs (sdb1): re-mounted. Opts: errors=remount-ro
[ ok ] Will now activate lvm and md swap:done.
[info] Will now check all file systems.
fsck from util-linux 2.29.2
Checking all file systems.
LABEL=rootfs is not mounted
[/sbin/fsck.ext4 (1) -- /] fsck.ext4 -y -C0 /dev/sda1 
e2fsck 1.43.4 (31-Jan-2017)
rootfs: clean, 8569/118784 files, 239580/474736 blocks
[ ok ] Done checking file systems. A log is being saved in /var/log/fsck/checkfs if that location is writable..
[ ok ] Cleaning up temporary files...[....] Cleaning /tmp...done.
[ ok .
[ ok ] Will now mount local filesystems:.
[ ok ] Will now activate swapfile swap:done.
[ ok ] Checking minimum space in /tmp...done.
[ ok ] Cleaning up temporary files....
[ ok ] Setting kernel variables...done.
[ ok ] Initializing random number generator...done.
[ ok ] Configuring network interfaces...done.
[ ok ] Cleaning up temporary files....
INIT: Entering runlevel: 2
[info] Using makefile-style concurrent boot in runlevel 2.
[....] Starting busybox' syslogd implementation : syslogdStarting /sbin/syslogd...
1227 (syslogd)
. ok 
[   38.097206][ T1251] NET: Registered protocol family 10
[   38.105097][ T1251] Segment Routing with IPv6
Starting Dropbear SSH server: dropbear.
[ ok ] Starting NTP server: ntpd.
[....] Starting busybox' klogd implementation : klogdStarting /sbin/klogd...
1225 (klogd)
. ok 
[ ok ] Starting FTP server: vsftpd.
[ ok ] Running local boot scripts (/etc/rc.local).

Debian GNU/Linux 9 debian ttyS0

debian login: root
Password: 
Linux debian 5.1.0-kirkwood-tld-1 #1 PREEMPT Tue May 7 00:16:02 PDT 2019 armv5tel

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.

cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00080000 00010000 "uboot"
mtd1: 00040000 00010000 "sdd_firmware"
mtd2: 00010000 00010000 "uboot_env"
mtd3: 00010000 00010000 "permanent_uboot_env"
mtd4: 00010000 00010000 "hp_env"

cat /etc/fw_env.config
# MTD device name	Device offset	Env. size	Flash sector size	Number of sectors
/dev/mtd0 0xc0000 0x20000 0x20000


fw_printenv
Warning: Bad CRC, using default environment
bootargs=
bootcmd=
bootdelay=2
baudrate=115200
arch=sandbox
cpu=sandbox
board=sandbox
board_name=sandbox
stdin=serial,cros-ec-keyb,usbkbd
stdout=serial,vidconsole
stderr=serial,vidconsole
ethaddr=00:00:11:22:33:44
eth1addr=00:00:11:22:33:45
eth3addr=00:00:11:22:33:46
eth5addr=00:00:11:22:33:47
ipaddr=1.2.3.4
host_boot=if host dev ${devnum}; then setenv devtype host; run scan_dev_for_boot_part; fi
boot_net_pci_enum=pci enum
boot_net_usb_start=usb start
usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi
boot_prefixes=/ /boot/
boot_scripts=boot.scr.uimg boot.scr
boot_script_dhcp=boot.scr.uimg
boot_targets=host1 host0 
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
bootcmd_host1=setenv devnum 1; run host_boot
bootcmd_host0=setenv devnum 0; run host_boot
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
bootm_size=0x10000000
kernel_addr_r=0x1000000
fdt_addr_r=0xc00000
ramdisk_addr_r=0x2000000
scriptaddr=0x1000
pxefile_addr_r=0x2000
root@debian:~#
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 14, 2019 06:38PM
kalehrl,

[    8.872214][    T1] 5 cmdlinepart partitions found on MTD device spi0.0
[    8.878859][    T1] Creating 5 MTD partitions on "spi0.0":
[    8.884404][    T1] 0x000000000000-0x000000080000 : "uboot"
[    8.891347][    T1] 0x000000080000-0x0000000c0000 : "sdd_firmware"
[    8.898757][    T1] 0x0000000c0000-0x0000000d0000 : "uboot_env"
[    8.905946][    T1] 0x0000000d0000-0x0000000e0000 : "permanent_uboot_env"
[    8.914007][    T1] 0x0000000e0000-0x0000000f0000 : "hp_env"

cat /proc/mtd
dev:    size   erasesize  name
mtd0: 00080000 00010000 "uboot"
mtd1: 00040000 00010000 "sdd_firmware"
mtd2: 00010000 00010000 "uboot_env"
mtd3: 00010000 00010000 "permanent_uboot_env"
mtd4: 00010000 00010000 "hp_env"

The above are correct so far.

But this is apparently not good:

cat /etc/fw_env.config
# MTD device name	Device offset	Env. size	Flash sector size	Number of sectors
/dev/mtd0 0xc0000 0x20000 0x20000

You forgot to change the fw_env.config! Should be

cat /etc/fw_env.config
# MTD device name	Device offset	Env. size	Flash sector size	Number of sectors

# HP T5325 Thin Client
/dev/mtd2 0x00000 0x10000 0x10000

So modify the /etc/fw_env.config, and no need to reboot.

fw_printenv

And test
fw_setenv  test_001 yes
fw_printenv

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)



Edited 1 time(s). Last edit at 05/14/2019 06:40PM by bodhi.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 15, 2019 07:34AM
Nope. Still the same:

fw_printenv
Warning: Bad CRC, using default environment
bootargs=
bootcmd=
bootdelay=2
baudrate=115200
arch=sandbox
cpu=sandbox
board=sandbox
board_name=sandbox
stdin=serial,cros-ec-keyb,usbkbd
stdout=serial,vidconsole
stderr=serial,vidconsole
ethaddr=00:00:11:22:33:44
eth1addr=00:00:11:22:33:45
eth3addr=00:00:11:22:33:46
eth5addr=00:00:11:22:33:47
ipaddr=1.2.3.4
host_boot=if host dev ${devnum}; then setenv devtype host; run scan_dev_for_boot_part; fi
boot_net_pci_enum=pci enum
boot_net_usb_start=usb start
usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi
boot_prefixes=/ /boot/
boot_scripts=boot.scr.uimg boot.scr
boot_script_dhcp=boot.scr.uimg
boot_targets=host1 host0
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
bootcmd_host1=setenv devnum 1; run host_boot
bootcmd_host0=setenv devnum 0; run host_boot
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
bootm_size=0x10000000
kernel_addr_r=0x1000000
fdt_addr_r=0xc00000
ramdisk_addr_r=0x2000000
scriptaddr=0x1000
pxefile_addr_r=0x2000
root@debian:~# fw_setenv  test_001 yes
Warning: Bad CRC, using default environment

fw_setenv test_001 yes
Warning: Bad CRC, using default environment

fw_printenv
Warning: Bad CRC, using default environment
bootargs=
bootcmd=
bootdelay=2
baudrate=115200
arch=sandbox
cpu=sandbox
board=sandbox
board_name=sandbox
stdin=serial,cros-ec-keyb,usbkbd
stdout=serial,vidconsole
stderr=serial,vidconsole
ethaddr=00:00:11:22:33:44
eth1addr=00:00:11:22:33:45
eth3addr=00:00:11:22:33:46
eth5addr=00:00:11:22:33:47
ipaddr=1.2.3.4
host_boot=if host dev ${devnum}; then setenv devtype host; run scan_dev_for_boot_part; fi
boot_net_pci_enum=pci enum
boot_net_usb_start=usb start
usb_boot=usb start; if usb dev ${devnum}; then setenv devtype usb; run scan_dev_for_boot_part; fi
boot_prefixes=/ /boot/
boot_scripts=boot.scr.uimg boot.scr
boot_script_dhcp=boot.scr.uimg
boot_targets=host1 host0
boot_extlinux=sysboot ${devtype} ${devnum}:${distro_bootpart} any ${scriptaddr} ${prefix}extlinux/extlinux.conf
scan_dev_for_extlinux=if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}extlinux/extlinux.conf; then echo Found ${prefix}extlinux/extlinux.conf; run boot_extlinux; echo SCRIPT FAILED: continuing...; fi
boot_a_script=load ${devtype} ${devnum}:${distro_bootpart} ${scriptaddr} ${prefix}${script}; source ${scriptaddr}
scan_dev_for_scripts=for script in ${boot_scripts}; do if test -e ${devtype} ${devnum}:${distro_bootpart} ${prefix}${script}; then echo Found U-Boot script ${prefix}${script}; run boot_a_script; echo SCRIPT FAILED: continuing...; fi; done
scan_dev_for_boot=echo Scanning ${devtype} ${devnum}:${distro_bootpart}...; for prefix in ${boot_prefixes}; do run scan_dev_for_extlinux; run scan_dev_for_scripts; done;
scan_dev_for_boot_part=part list ${devtype} ${devnum} -bootable devplist; env exists devplist || setenv devplist 1; for distro_bootpart in ${devplist}; do if fstype ${devtype} ${devnum}:${distro_bootpart} bootfstype; then run scan_dev_for_boot; fi; done
bootcmd_host1=setenv devnum 1; run host_boot
bootcmd_host0=setenv devnum 0; run host_boot
distro_bootcmd=for target in ${boot_targets}; do run bootcmd_${target}; done
bootm_size=0x10000000
kernel_addr_r=0x1000000
fdt_addr_r=0xc00000
ramdisk_addr_r=0x2000000
scriptaddr=0x1000
pxefile_addr_r=0x2000
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 15, 2019 07:44AM
After:
fw_setenv test_001 yes
The box didn't boot so I had to import it from uEnv.txt file.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 15, 2019 02:04PM
kalehrl,

> The box didn't boot so I had to import it from
> uEnv.txt file.

My bad, I forgot to say if you saw the CRC error then don't do fw_setenv!

Apparently I need to read the kernel code to check this flash type. Everything else was verified to be OK. I must have missed something :)

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 16, 2019 07:52AM
No problem.
It's very easy to restore it.
I uninstalled some packages and now
shutdown -h now
command reboots the box instead of powering it off.
shutdown now
powers it off but the blue LED is still on.
Any ideas what package handles the shutdown functions?
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 16, 2019 08:28PM
kalehrl,

> No problem.
> It's very easy to restore it.
> I uninstalled some packages and now
>
> shutdown -h now
>
> command reboots the box instead of powering it
> off.
>
> shutdown now
>
> powers it off but the blue LED is still on.
> Any ideas what package handles the shutdown
> functions?

Which packages were uninstalled?

shutdown -h now is correct command to use.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)



Edited 1 time(s). Last edit at 05/17/2019 02:54AM by bodhi.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 17, 2019 02:57AM
kalehrl,

If that "shutdown -h now" behaves differently, then the init script (e.g. halt) must have been changed somehow.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 17, 2019 07:17AM
Which packages were uninstalled?
I uninstalled some of them but not the essential ones.
dpkg doesn't report any errors or missing dependencies.
I also tried dpkg install -f but no packages are installed.
I haven't touched halt scripts.
I had a look at /etc/init.d folder and there are 2 halt scripts:
halt and halt.dpkg-old
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
May 17, 2019 09:59PM
kalehrl,

> I had a look at /etc/init.d folder and there are 2
> halt scripts:
> halt and halt.dpkg-old

That means it was changed at least once during apt-get upgrade.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Fermín Olaiz
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
September 20, 2023 04:04PM
Hi! I am following the B guide (using the 4.12.1-kirkwood-tld-1 rootfs).
After unlocking the flash I try to write it but it throws an error while verifying. I made sure to flash the previous backup to make sure I could boot again and it verified correctly! (which implies the nand is not being written properly or even at all).

Logs:

root@debian:~# flashcp -v uboot.2017.07-tld-1.t5325.mtd0.kwb /dev/mtd0
Erasing blocks: 8/8 (100%)
Writing data: 512k/512k (100%)
Verifying data: 10k/512k (1%)File does not seem to match flash data. First mismatch at 0x00000000-0x00002800
root@debian:~# flashcp -v uboot.2016.05-tld-1.environment.64K.img  /dev/mtd2
Erasing blocks: 1/1 (100%)
Writing data: 64k/64k (100%)
Verifying data: 10k/64k (15%)File does not seem to match flash data. First mismatch at 0x00000000-0x00002800
root@debian:~# flashcp -v devmtd0 /dev/mtd0
Erasing blocks: 8/8 (100%)
Writing data: 512k/512k (100%)
Verifying data: 512k/512k (100%)
root@debian:~# flashcp -v devmtd1 /dev/mtd1                                                                                                
Erasing blocks: 4/4 (100%)
Writing data: 256k/256k (100%)
Verifying data: 256k/256k (100%)

Any clues as to what it might be?

PS: Thanks for this project! I'm sure it's been a ton of work!
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
September 20, 2023 04:29PM
Fermín Olaiz,

> Hi! I am following the B guide (using the
> 4.12.1-kirkwood-tld-1 rootfs).

Note Step B.2 in the installation instruction.

Quote

B. Installation from the latest Debian rootfs

- If you have installed the latest Debian rootfs, but your u-boot is still stock, then follow all the steps in this section B.
- If you are upgrading from uboot.2016.05-tld-1 then you only need to do step 1 to step 4 in this section B.

Steps:

1. Boot into Debian rootfs, extract u-boot images

cd /boot
tar -xf uboot.2017.07-tld-1.t5325.bodhi.tar
tar -xf uboot.2016.05-tld-1.environment.bodhi.tar

2. Verify the MTD flash definition in your Debian rootfs. Note the mtd0 and mtd2 definition, they must be identical to your current mtd0 and mtd2. Also note that stock mtd definition is different. So if your mtdpart defintion is still stock, please post question before continue.

cat /proc/mtd
dev: size erasesize name
mtd0: 00080000 00010000 "uboot"
mtd1: 00040000 00010000 "sdd_firmware"
mtd2: 00010000 00010000 "uboot_env"
mtd3: 00010000 00010000 "permanent_uboot_env"
mtd4: 00010000 00010000 "hp_env"

Do

cat /proc/mtd

Does it look the same as above, or is it still stock mtd? Also please post your dmesg too when asking question (so I can doublecheck).

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
September 21, 2023 10:36AM
@bodhi sorry for all the missing info.

I am using stock uBoot. The mtd is slightly different although it looks right.

root@debian:~# cat /proc/mtd 
dev:    size   erasesize  name
mtd0: 00080000 00010000 "u-boot"
mtd1: 00040000 00010000 "SSD firmware"
mtd2: 00010000 00010000 "u-boot env"
mtd3: 00010000 00010000 "permanent u-boot env"
mtd4: 00010000 00010000 "permanent u-boot env"

dmesg: https://pastebin.com/B85dVRBb

Also, when I try to unlock /dev/mtd2 (u-boot env) although it exits as 0 it remains locked.
Despite that, flasing /dev/mtd0 is also unsuccessful.

root@debian:~# flash_unlock -u /dev/mtd2; echo $?
0
root@debian:~# flash_unlock -i /dev/mtd2
Device: /dev/mtd2
Start: 0
Len: 0x10000
Lock status: locked
Return code: 1

Thank you!



Edited 1 time(s). Last edit at 09/21/2023 10:37AM by fermino.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
September 21, 2023 10:42AM
Quick update: it seems the flash is not being written at all:

root@debian:~# flash_unlock /dev/mtd0

root@debian:~# flashcp -v devmtd0 /dev/mtd0
Erasing blocks: 8/8 (100%)
Writing data: 512k/512k (100%)
Verifying data: 512k/512k (100%)

root@debian:~# flashcp -v uboot.2017.07-tld-1.t5325.mtd0.kwb /dev/mtd0
Erasing blocks: 8/8 (100%)
Writing data: 512k/512k (100%)
Verifying data: 10k/512k (1%)File does not seem to match flash data. First mismatch at 0x00000000-0x00002800

root@debian:~# dd if=/dev/mtd0 of=devmtd0_wrongly_written
1024+0 records in
1024+0 records out
524288 bytes (524 kB, 512 KiB) copied, 0.825285 s, 635 kB/s

root@debian:~# sha256sum devmtd0 devmtd0_wrongly_written 
741b1bcb6cf551e17097b45de96be14de8a8d30d40374104a47a9a050d54f249  devmtd0
741b1bcb6cf551e17097b45de96be14de8a8d30d40374104a47a9a050d54f249  devmtd0_wrongly_written



Edited 1 time(s). Last edit at 09/21/2023 10:42AM by fermino.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
September 21, 2023 02:13PM
fermino,

Yours is the odd case. The instruction A and B both show that you should create the USB rootfs and flashing new u-boot at the same time. But you are running stock u-boot with Debian.

So there are some adjustment during boot that you need to do.

=============

Since you have not successfully flashed u-boot and envs images, you can reboot. Stock u-boot will run. Note that if you have backed up the mtds, you can verify that the u-boot partition is still the same (Update: I saw that you did that).

Power up, interrupt serial console and get the listing of the envs.
printenv
And then boot in to Debian and
cat /etc/fw_env.config

We'll adjust the envs so that it will give you a set of mtds that can be flashed.

===========

By the way, you can use the latest rootfs: Debian-5.13.6-kirkwood-tld-1-rootfs-bodhi.tar.bz2 (26 Sept 2021). The instruction was written long ago, the latest rootfs will work and will save you some time upgrading to the latest Debian and Linux kernel.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)



Edited 1 time(s). Last edit at 09/21/2023 03:10PM by bodhi.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
September 21, 2023 05:17PM
So, if I'm getting it correctly the mtd is just raw flash space (in the nand? or somewhere else?) that is then divided in blocks by the mtd definition? Is that definition coming only from fw_env.config or from other place? (I'm trying to understand how it works, it's the first time I touch uboot :) )

printenv: https://pastebin.com/6dRxaWuc

fw_env.config:
root@debian:~# cat /etc/fw_env.config 
/dev/mtd2 0x00000 0x10000 0x10000
root@debian:~#

Thank you!

Edit: the reason I went with the 4.1 kernel before updating uboot is that I read somewhere in the forums that stock uboot could have problems loading the new kernels (which are bigger iirc). I will look into that, though!



Edited 2 time(s). Last edit at 09/21/2023 05:22PM by fermino.
Re: HP T5325 Thin Client U-Boot-2017.07-tld-1
September 21, 2023 06:15PM
> So, if I'm getting it correctly the mtd is just
> raw flash space (in the nand? or somewhere else?)

This box has SPI flash (not NAND flash). And the mtd is a logical layer on top of the flash (whether it is NAND or SPI). This layer is managed by the u-boot (while it is running) and kernel drivers (during and after the kernel boots).

> that is then divided in blocks by the mtd
> definition? Is that definition coming only from
> fw_env.config or from other place?

The u-boot env mtdparts is where the mtd partitions are defined. The rules of thumb is u-boot always resides at the 0x0 location of the flash (for boards that boot with flash).

>
> printenv: https://pastebin.com/6dRxaWuc

I'll take a look. By the way, if the log is small you can post here (using code tags), no need for pastebin.

>
> fw_env.config:
> root@debian:~# cat /etc/fw_env.config
> /dev/mtd2 0x00000 0x10000 0x10000

Looks good.

> Edit: the reason I went with the 4.1
> kernel before updating uboot is that I read
> somewhere in the forums that stock uboot could
> have problems loading the new kernels (which are
> bigger iirc). I will look into that, though!

Yes, it was from me. It's a general statement to help people to get it booted the first time they try. But the size problem is not wisespread. So after it booted, try the latest rootfs.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: