Jump to content

Recommended Posts

Posted

Just freshly minted a Armbian build for this board. It boots just fine from SD card, but when I nand-sata-install to EMMC and power cycle. I'm greeted with this:

U-Boot TPL 2019.10-armbian (Dec 28 2019 - 02:48:10)
Trying to boot from BOOTROM
Returning to boot ROM...

U-Boot SPL 2019.10-armbian (Dec 28 2019 - 02:48:10 +0100)
Trying to boot from MMC2
unable to select a mode
mmc_load_image_raw_sector: mmc block read error
Trying to boot from MMC2
mmc_load_image_raw_sector: mmc block read error
Trying to boot from MMC1
mmc_load_image_raw_sector: mmc block read error
SPL: failed to boot from all boot devices
### ERROR ### Please RESET the board ###


 

Is this a known issue?

 

Posted

Gave the latest UBoot tag a spin, but it looks much the same:

U-Boot TPL 2020.01-rc5-armbian (Jan 03 2020 - 03:07:34)
Channel 0: LPDDR4, 50MHz
BW=32 Col=10 Bk=8 CS0 Row=15 CS1 Row=15 CS=2 Die BW=16 Size=2048MB
Channel 1: LPDDR4, 50MHz
BW=32 Col=10 Bk=8 CS0 Row=15 CS1 Row=15 CS=2 Die BW=16 Size=2048MB
256B stride
256B stride
lpddr4_set_rate: change freq to 400000000 mhz 0, 1
lpddr4_set_rate: change freq to 800000000 mhz 1, 0
Trying to boot from BOOTROM
Returning to boot ROM...

U-Boot SPL 2020.01-rc5-armbian (Jan 03 2020 - 03:07:34 +0100)
Trying to boot from MMC2
unable to select a mode
mmc_load_image_raw_sector: mmc block read error
Trying to boot from MMC2
mmc_load_image_raw_sector: mmc block read error
Trying to boot from MMC1
mmc_load_image_raw_sector: mmc block read error
SPL: failed to boot from all boot devices
### ERROR ### Please RESET the board ###

Then I tried to build latest master, but I omitted the board-roc-rk3399-pc-fix-disable-hs400.patch and I'm greeted with this (booted from SD).

Maybe I'll just call it goodnight :)

 

  Reveal hidden contents


 

Posted

Successful booting mainline atf, u-boot, kernel from eMMC, rootfs on NVME.

U-Boot TPL 2020.01-rc5-00066-g28aa6dc29a (Jan 03 2020 - 09:54:11)
Channel 0: LPDDR4, 50MHz
BW=32 Col=10 Bk=8 CS0 Row=15 CS1 Row=15 CS=2 Die BW=16 Size=2048MB
Channel 1: LPDDR4, 50MHz
BW=32 Col=10 Bk=8 CS0 Row=15 CS1 Row=15 CS=2 Die BW=16 Size=2048MB
256B stride
256B stride
lpddr4_set_rate: change freq to 400000000 mhz 0, 1
lpddr4_set_rate: change freq to 800000000 mhz 1, 0
Trying to boot from BOOTROM
Returning to boot ROM...

U-Boot SPL 2020.01-rc5-00066-g28aa6dc29a (Jan 03 2020 - 09:54:11 +0100)
Trying to boot from MMC2


U-Boot 2020.01-rc5-00066-g28aa6dc29a (Jan 03 2020 - 09:54:11 +0100)

Model: Firefly ROC-RK3399-PC Board
DRAM:  3.9 GiB
PMIC:  RK808
MMC:   dwmmc@fe320000: 1, sdhci@fe330000: 0
Loading Environment from MMC... *** Warning - bad CRC, using default environment

In:    serial@ff1a0000
Out:   serial@ff1a0000
Err:   serial@ff1a0000
Model: Firefly ROC-RK3399-PC Board
rockchip_dnl_key_pressed: adc_channel_single_shot fail!
Net:
Error: ethernet@fe300000 address not set.
No ethernet found.

Hit any key to stop autoboot:  0
switch to partitions #0, OK
mmc0(part 0) is current device
Scanning mmc 0:4...
Found /extlinux/extlinux.conf
Retrieving file: /extlinux/extlinux.conf
672 bytes read in 20 ms (32.2 KiB/s)
1:      mainline-kernel-5.4
Retrieving file: /Initrd
15692480 bytes read in 1522 ms (9.8 MiB/s)
Retrieving file: /Image
12347904 bytes read in 1211 ms (9.7 MiB/s)
append: earlycon=uart8250,mmio32,0xff1a0000 console=tty1 console=ttyS2,1500000 swiotlb=1 root=/dev/nvme0n1p1 rootwait rw rootfstype=ext4 init=/sbin/init mitigations=off
Retrieving file: /rk3399-roc-pc-mezzanine.dtb
57549 bytes read in 22 ms (2.5 MiB/s)
## Loading init Ramdisk from Legacy Image at 06000000 ...
   Image Name:   initramfs
   Image Type:   ARM Linux RAMDisk Image (uncompressed)
   Data Size:    15692416 Bytes = 15 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 01f00000
   Booting using the fdt blob at 0x1f00000
   Loading Ramdisk to f502a000, end f5f21280 ... OK
   Loading Device Tree to 00000000f5018000, end 00000000f50290cc ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
[    0.000000] Linux version 5.5.0-rc2-next-20191220-00003-g7380ee666901 (root@roc) (gcc version 9.2.1 20191130 (Debian 9.2.1-21)) #65 SMP PREEMPT Fri Jan 3 09:50:21 CET 2020
[    0.000000] Machine model: Firefly ROC-RK3399-PC Mezzanine Board

 

Posted
  On 1/3/2020 at 9:08 AM, Panzerknacker said:
Successful booting mainline atf, u-boot, kernel from eMMC, rootfs on NVME.
U-Boot TPL 2020.01-rc5-00066-g28aa6dc29a (Jan 03 2020 - 09:54:11)Channel 0: LPDDR4, 50MHzBW=32 Col=10 Bk=8 CS0 Row=15 CS1 Row=15 CS=2 Die BW=16 Size=2048MBChannel 1: LPDDR4, 50MHzBW=32 Col=10 Bk=8 CS0 Row=15 CS1 Row=15 CS=2 Die BW=16 Size=2048MB256B stride256B stridelpddr4_set_rate: change freq to 400000000 mhz 0, 1lpddr4_set_rate: change freq to 800000000 mhz 1, 0Trying to boot from BOOTROMReturning to boot ROM...U-Boot SPL 2020.01-rc5-00066-g28aa6dc29a (Jan 03 2020 - 09:54:11 +0100)Trying to boot from MMC2U-Boot 2020.01-rc5-00066-g28aa6dc29a (Jan 03 2020 - 09:54:11 +0100)Model: Firefly ROC-RK3399-PC BoardDRAM:  3.9 GiBPMIC:  RK808MMC:   dwmmc@fe320000: 1, sdhci@fe330000: 0Loading Environment from MMC... *** Warning - bad CRC, using default environmentIn:    serial@ff1a0000Out:   serial@ff1a0000Err:   serial@ff1a0000Model: Firefly ROC-RK3399-PC Boardrockchip_dnl_key_pressed: adc_channel_single_shot fail!Net:Error: ethernet@fe300000 address not set.No ethernet found.Hit any key to stop autoboot:  0switch to partitions #0, OKmmc0(part 0) is current deviceScanning mmc 0:4...Found /extlinux/extlinux.confRetrieving file: /extlinux/extlinux.conf672 bytes read in 20 ms (32.2 KiB/s)1:      mainline-kernel-5.4Retrieving file: /Initrd15692480 bytes read in 1522 ms (9.8 MiB/s)Retrieving file: /Image12347904 bytes read in 1211 ms (9.7 MiB/s)append: earlycon=uart8250,mmio32,0xff1a0000 console=tty1 console=ttyS2,1500000 swiotlb=1 root=/dev/nvme0n1p1 rootwait rw rootfstype=ext4 init=/sbin/init mitigations=offRetrieving file: /rk3399-roc-pc-mezzanine.dtb57549 bytes read in 22 ms (2.5 MiB/s)## Loading init Ramdisk from Legacy Image at 06000000 ...  Image Name:   initramfs  Image Type:   ARM Linux RAMDisk Image (uncompressed)  Data Size:    15692416 Bytes = 15 MiB  Load Address: 00000000  Entry Point:  00000000  Verifying Checksum ... OK## Flattened Device Tree blob at 01f00000  Booting using the fdt blob at 0x1f00000  Loading Ramdisk to f502a000, end f5f21280 ... OK  Loading Device Tree to 00000000f5018000, end 00000000f50290cc ... OKStarting kernel ...[    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034][    0.000000] Linux version 5.5.0-rc2-next-20191220-00003-g7380ee666901 (root@roc) (gcc version 9.2.1 20191130 (Debian 9.2.1-21)) #65 SMP PREEMPT Fri Jan 3 09:50:21 CET 2020[    0.000000] Machine model: Firefly ROC-RK3399-PC Mezzanine Board

 

Did you build linux 5.5-rc2 with the armbian build script?

Sent from my moto g(7) power using Tapatalk

Posted (edited)

@Panzerknacker What make/model EMMC you got? I have the 128GB which was delivered with the board. It's wierd the EMMC works in Linux but U-Boot SPL has issues. Wondering if there's patch somewhere... 

 

Edit: Many hours later...

 

Dug deep into the MMC code in UBoot and it seems there is a bug.. My EMMC will not negotiate success the advertised supported speed/mode (mmc: widths [8, 4, 1] modes [MMC legacy, MMC High Speed (26MHz), SD High Speed (50MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz)] ). UBoot should revert back to the "safer" speed here: mmc.c#L2146, but it seems to be missing a call to mmc_set_clock(). I added the missing call and it successfully reverts back to "MMC High Speed (26MHz)" and EMMC can be read. Board finally boots on EMMC :)

trying mode MMC High Speed (26MHz) width 8 (at 26 MHz)
CMD_SEND:6
		ARG			 0x03b70200
		MMC_RSP_R1b		 0x00800800 
CMD_SEND:13
		ARG			 0x00010000
		MMC_RSP_R1,5,6,7 	 0x00000900 
CURR STATE:4
CMD_SEND:6
		ARG			 0x03b90100
		MMC_RSP_R1b		 0x00000800 
CMD_SEND:13
		ARG			 0x00010000
		MMC_RSP_R1,5,6,7 	 0x00000900 
CURR STATE:4
CMD_SEND:8
		ARG			 0x00000000
		MMC_RSP_R1,5,6,7 	 0x00000900 
selecting mode MMC High Speed (26MHz) (freq : 26 MHz)
clock is enabled (26000000Hz)
CMD_SEND:8
		ARG			 0x00000000
		MMC_RSP_R1,5,6,7 	 0x00000900 
switch to partitions #0, OK
mmc0(part 0) is current device

Now booted kernel and the EMMC works perfectly in HS400 ES mode?!?!

Welcome to Armbian buster with Linux 5.4.6-rockchip64

System load:   0.00 0.00 0.00  	Up time:       1 min		
Memory usage:  3 % of 3868MB 	IP:            192.168.0.33
CPU temp:      36°C           	
Usage of /:    2% of 113G   	


root@roc:~# cat /sys/kernel/debug/mmc1/ios 
clock:		200000000 Hz
actual clock:	200000000 Hz
vdd:		7 (1.65 - 1.95 V)
bus mode:	2 (push-pull)
chip select:	0 (don't care)
power mode:	2 (on)
bus width:	3 (8 bits)
timing spec:	10 (mmc HS400 enhanced strobe)
signal voltage:	1 (1.80 V)
driver type:	0 (driver type B)

Oh, and 5.4.7 is no good...

 

Edited by Redferne
Success!
Posted
  On 1/3/2020 at 10:41 PM, Redferne said:

@Panzerknacker What make/model EMMC you got? I have the 128GB which was delivered with the board. It's wierd the EMMC works in Linux but U-Boot SPL has issues. Wondering if there's patch somewhere... 

Expand  

https://lkml.org/lkml/2019/11/11/203

 

The 128G72 has problems with U-Boot finding Initrd, Image and gpt when getting hot.

No problems with earlier stages or when cold.

Posted (edited)
  On 1/3/2020 at 10:41 PM, Redferne said:

Dug deep into the MMC code in UBoot and it seems there is a bug.. My EMMC will not negotiate success the advertised supported speed/mode (mmc: widths [8, 4, 1] modes [MMC legacy, MMC High Speed (26MHz), SD High Speed (50MHz), MMC High Speed (52MHz), MMC DDR52 (52MHz)] ). UBoot should revert back to the "safer" speed here: mmc.c#L2146, but it seems to be missing a call to mmc_set_clock(). I added the missing call and it successfully reverts back to "MMC High Speed (26MHz)" and EMMC can be read. Board finally boots on EMMC

Expand  

Respect.

Could you publish and upstream a patch?

 

Regarding the MP8859 12V supply, this is now ready and will be upstreamed:

https://github.com/Reichl/linux-next-roc-pc

 

Edit: Merged, will shine up in 5.6

Edited by Panzerknacker
Got merged in mainline kernel.
Posted

Not sure this a bug, but the following patch made my EMMC revert back to MMC High Speed (26MHz) after failing @ MMC High Speed (52MHz).

diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index f683b52e..2e01c75f 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -2139,11 +2143,14 @@ static int mmc_select_mode_and_width(struct mmc *mmc, uint card_caps)
 			if (!err)
 				return 0;
 error:
+			pr_debug("error: %d\n", err);
 			mmc_set_signal_voltage(mmc, old_voltage);
 			/* if an error occured, revert to a safer bus mode */
 			mmc_switch(mmc, EXT_CSD_CMD_SET_NORMAL,
 				   EXT_CSD_BUS_WIDTH, EXT_CSD_BUS_WIDTH_1);
 			mmc_select_mode(mmc, MMC_LEGACY);
+			mmc_set_clock(mmc, mmc->tran_speed,
+					MMC_CLK_ENABLE);
 			mmc_set_bus_width(mmc, 1);
 		}
 	}

 

Posted
  On 1/4/2020 at 5:35 PM, gounthar said:

That's cool, as mine still does not want to start with yesterday's Armbian build (despite booting Firefly's official Android image on the SDCard).

Expand  

If you're building 5.4.y, try tag:v5.4.6 instead. I couldn't get latest master to boot properly on this board.

Posted
  On 1/5/2020 at 3:29 AM, Redferne said:
If you're building 5.4.y, try tag:v5.4.6 instead. I couldn't get latest master to boot properly on this board.
Mine booted with 5.5rc2 but had a crash when starting openSSH with 5.5rc3, and rc4+, not sure if it's because I didn't make clean. make dtbs-install copies the dtb files to /boot/dtbs/(kernel version/rockchip
My installed uboot seems to expect the dtb to be /boot/dtb/rockchip. Now it won't power on at all, I assume it's because I pulled the power lead out at the wrong time so I'm building a new image file to flash onto the SDcard.
I haven't used make dtbs-install before so don't know if that's new behaviour or not.

Sent from my moto g(7) power using Tapatalk

Posted
  On 1/14/2020 at 4:03 PM, Fred St-Pierre said:
 
If only firefly/loverpi/libre were of any help. I'll post it on their forum and hope for the best.
They have been really quiet, they still have 2 or 3 boards they were going to launch last year that never launched on Indiegogo or Kickstarter. Maybe because of problems/negative feedback from the renegade elite, and long delays on la frite as well?

Sent from my moto g(7) power using Tapatalk

Posted
  On 1/14/2020 at 7:33 PM, a16bitsysop said:

They have been really quiet, they still have 2 or 3 boards they were going to launch last year that never launched on Indiegogo or Kickstarter. Maybe because of problems/negative feedback from the renegade elite, and long delays on la frite as well?

Sent from my moto g(7) power using Tapatalk
 

Expand  

 

Only OT post I'll post, as to not mine the thread with this, but yeah, quite possibly. La frite is missing fulfilment of mezzanine boards and wifi modules, while Renegade Elite has 10 people missing emmc modules (including me) and wifi modules. They've been vague and sketchy, saying they need a minimum order quantity to fulfill missing perks and that we have no reason to complain. 

 

Back OT: ever since kernel 5.4 has been dropped, we got one post from them saying that around christmas, we'd see something released by them in regards to u-boot and I BELIEVE OS. But their communication skills are very lacking. I'm wondering if contacting the Firefly team might yield better results to get the PD issue fixed.

Posted
  On 1/14/2020 at 2:48 PM, Panzerknacker said:

If we could solve this:

https://lore.kernel.org/linux-usb/0ac6bbe7-6395-526d-213c-ac58a19d8673@fivetechno.de/

we probably had everything working in mainline.

Expand  

Does anyone know if I can power this thing via the 12V header? The documentation on this is lacking. It should work since the mezzanine board can provide power either via battery or PoE. I do have a beefy 5V power supply, but it's in use and I do have a spare 12V power supply. I also have a USB-C PD power supply, but apparently that doesn't switch to higher voltages yet...

Posted

I finally got everything together to power this thing via the 12V header and it works :beer:

I did a minimal Ubuntu build like two weeks ago and it booted fine. I ran sbc-bench: http://ix.io/2aVd

 

Now it might be something more than a paper weight :D

IMG_20200206_172412.jpg

Posted
  On 2/19/2020 at 9:46 AM, frauhottelmann said:
I've built the current branch which is 5.4.20. You could go dev which I believe is 5.5.x.
Will have to build a new Dev kernel and see if my M2 drive is recognised.

Sent from my moto g(7) power using Tapatalk

Posted
  On 2/18/2020 at 9:52 PM, frauhottelmann said:

I've build 20.02. It's working fine (still powering via 12V).

Expand  

 

I wrote to the firefly team so they could help in fixing USB-C power upstream and received a response on Feb 12th saying they were all remote working due to Corona virus... But the request to get the proper code base would be forwarded to an engineer. No reply on this yet.

Posted
  On 2/25/2020 at 4:03 PM, Fred St-Pierre said:

 

I wrote to the firefly team so they could help in fixing USB-C power upstream and received a response on Feb 12th saying they were all remote working due to Corona virus... But the request to get the proper code base would be forwarded to an engineer. No reply on this yet.

Expand  

I tried 20.02 with kernel 5.5.6 to see if my m2 ssd would be recognised, it’s powered by POE and the switch is saying it is powering it at 52v.  I changed the dtb file to the mezzanine one and now I get (when doing a dmesg | grep pci)

[    1.527318] vcc3v3_pcie: supplied by dc_12v

[    2.751978] rockchip-pcie f8000000.pcie: no vpcie12v regulator found

[    2.752081] rockchip-pcie f8000000.pcie: f8000000.pcie supply vpcie0v9 not found, using dummy regulator

[    3.305332] rockchip-pcie f8000000.pcie: PCIe link training gen1 timeout!

[    3.305577] rockchip-pcie: probe of f8000000.pcie failed with error -110

 

maybe it’s the same cause?

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines