Uboot update not flashed [SOLVED]

This forum is for topics dealing with problems with software specifically in the ARMv7h repo.

Uboot update not flashed [SOLVED]

Postby lucabelluccini » Thu Apr 12, 2018 11:11 pm

Hello,
I'm running Linux Alarm on my old Odroid X.

The mac address gets randomized. I tried to update the /boot/boot.txt and added

$this->bbcode_second_pass_code('', '[alarm@alarm boot]$ cat boot.txt
# After modifying, run ./mkscr

# MAC address configuration
setenv macaddr "5e:da:15:44:21:bd"
setenv ethaddr "5e:da:15:44:21:bd"

part uuid ${devtype} ${devnum}:${bootpart} uuid
setenv bootargs "console=tty1 console=${console} root=PARTUUID=${uuid} rw rootwait smsc95xx.macaddr=${macaddr}"

if load ${devtype} ${devnum}:${bootpart} ${kernel_addr_r} /boot/zImage; then
if load ${devtype} ${devnum}:${bootpart} ${fdt_addr_r} /boot/dtbs/${fdtfile}; then
if load ${devtype} ${devnum}:${bootpart} ${ramdisk_addr_r} /boot/initramfs-linux.img; then
bootz ${kernel_addr_r} ${ramdisk_addr_r}:${filesize} ${fdt_addr_r};
else
bootz ${kernel_addr_r} - ${fdt_addr_r};
fi;
fi;
fi')

Then ran ./mkscr. After the reboot, the mac address is still random.

Last time I updated the system, I got the message below:

$this->bbcode_second_pass_code('', '
(122/125) upgrading uboot-odroid-x [##############################################] 100%
>>> Note: uEnv.txt is no longer used. Make any customizations within /boot/boot.txt
and run ./mkscr within /boot to convert it to the boot.scr file.
A new U-Boot version needs to be flashed onto /dev/mmcblk0.
Do you want to do this now? [y|N]
y
No MMC device to flash, exiting.')

I think this could be curlprit? Please note I've no uEnv.txt

Keep in mind I installed everything on the onboard emmc, no more relying on the SD card.

I'm now on Linux alarm 4.16.0-1-ARCH #1 SMP Fri Apr 6 01:55:57 UTC 2018 armv7l GNU/Linux

Note I've only those mmc devices:

$this->bbcode_second_pass_code('', 'NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
mmcblk1 179:0 0 14.7G 0 disk
`-mmcblk1p1 179:1 0 14.7G 0 part /
mmcblk1boot0 179:16 0 4M 1 disk
mmcblk1boot1 179:32 0 4M 1 disk')

My boot switch on my board is off (emmc).

When installing, I've followed the procedure at https://archlinuxarm.org/platforms/armv ... g/odroid-x but as I do not have any microsd adapter, I've first created the SD card, then re-followed the same steps from the Arch linux booted from SD.

Is there a way to tell the updater my device is on /dev/mmcblk1 ? Or I've completely messed up?

In dmesg I cannot see the correct parameters to force the mac address.

Another thing I noticed is the fact in the guide the switch "behavior" is inverse to what's actually printed on the board:
$this->bbcode_second_pass_quote('', '
')Set the boot switches on the ODROID-X board to boot from SD:
Locate the jumper between the SD slot, USB ports, and heatsink, labeled for eMMC and SD selection
Place the jumper over just one of the pins (so you don't lose it), not over both pins.


On the board I have

$this->bbcode_second_pass_code('', 'ON: SD, OFF: eMMC')

I've tried to boot from SD with a fresh image of Arch and it works (I can force the mac address).
I can see the mac address passed as kernel parameter in dmesg.

Booting from eMMC, it's clear it is still searching for /boot/uEnv.txt ... And old u-Boot version.
$this->bbcode_second_pass_code('', 'U-Boot 2016.11-1 (Dec 02 2016 - 20:11:43 -0700) Arch Linux ARM

CPU: Exynos4412 @ 1 GHz
Model: Odroid based on Exynos4412
Board: Odroid based on Exynos4412
Type: x
DRAM: 1 GiB
LDO20@VDDQ_EMMC_1.8V: set 1800000 uV; enabling
LDO22@VDDQ_EMMC_2.8V: set 2800000 uV; enabling
LDO21@TFLASH_2.8V: set 2800000 uV; enabling
MMC: EXYNOS DWMMC: 0, SAMSUNG SDHCI: 1
*** Warning - bad CRC, using default environment

Net: No ethernet found.
Hit any key to stop autoboot: 0
starting USB...
USB0: USB EHCI 1.00
scanning bus 0 for devices... 1 USB Device(s) found
scanning usb for ethernet devices... 0 Ethernet Device(s) found
switch to partitions #0, OK
mmc0(part 0) is current device
mmc found on device 0
Checking for: /boot/uEnv.txt ...
6168824 bytes read in 225 ms (26.1 MiB/s)
loading /boot/dtbs/exynos4412-odroidx.dtb ...
71353 bytes read in 177 ms (393.6 KiB/s)
5276621 bytes read in 197 ms (25.5 MiB/s)
Kernel image @ 0x40007fc0 [ 0x000000 - 0x5e20f8 ]
## Flattened Device Tree blob at 40800000
Booting using the fdt blob at 0x40800000
Loading Ramdisk to 4faf7000, end 4ffff3cd ... OK
Loading Device Tree to 4fae2000, end 4faf66b8 ... OK

Starting kernel ...
')

Booting from SD
$this->bbcode_second_pass_code('', 'U-Boot 2018.01-1 (Feb 13 2018 - 02:20:29 +0000) Arch Linux ARM

CPU: Exynos4412 @ 1 GHz
Model: Odroid based on Exynos4412
Board: Odroid based on Exynos4412
Type: x
DRAM: 1 GiB
LDO20@VDDQ_EMMC_1.8V: set 1800000 uV; enabling
LDO22@VDDQ_EMMC_2.8V: set 2800000 uV; enabling
LDO21@TFLASH_2.8V: set 2800000 uV; enabling
MMC: SAMSUNG SDHCI: 1, EXYNOS DWMMC: 0
*** Warning - bad CRC, using default environment

Net: No ethernet found.
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc1 is current device
Scanning mmc 1:1...
Found U-Boot script /boot/boot.scr
732 bytes read in 95 ms (6.8 KiB/s)
## Executing script at 50000000
6166528 bytes read in 298 ms (19.7 MiB/s)
71353 bytes read in 1880 ms (36.1 KiB/s)
5267495 bytes read in 238 ms (21.1 MiB/s)
Kernel image @ 0x42000000 [ 0x000000 - 0x5e1800 ]
## Flattened Device Tree blob at 43000000
Booting using the fdt blob at 0x43000000
Loading Ramdisk to 4faf9000, end 4ffff027 ... OK
Loading Device Tree to 4fae4000, end 4faf86b8 ... OK

Starting kernel ...
')

I think the update of the U-boot failed and the board is not booting properly.

I've just ran the sd_fusing.sh script passing the correct block device (corresponding to the emmc).
The U-Boot is now updated.
lucabelluccini
 
Posts: 4
Joined: Mon Apr 24, 2017 7:15 pm

Return to ARMv7h

Who is online

Users browsing this forum: No registered users and 10 guests