Sunday, July 30, 2023

Re: Samsung NVMe M.2 SSD 970 EVO Plus fails to attach on VisionFive 2 (JH7110 SoC) board

Zitat von developer@robert-palm.de:

> Zitat von "Peter J. Philipp" <pjp@delphinusdns.org>:
>
>> [tying in misc@ for this resource]
>>
>> On Fri, Jul 28, 2023 at 03:26:54PM +0200, developer@robert-palm.de wrote:
>>> Many thanks! Please, will you commit it so I can test it with the next
>>> snapshot version ?
>>
>> I have already contacted Robert (?) privately, here it is publically.
>>
>> I have exported my QEMU script on github, in case anyone else needs to
>> compile RISCV64 kernels and images (without having to wait on snapshots):
>>
>> https://github.com/pbug44/openbsd-riscv-misc/blob/master/start-rv64.sh
>>
>> I use this config to compile kernels for riscv64 (on a rpi4b it's slow!).
>>
>> Best Regards,
>> -peter
>>
>> --
>> Over thirty years experience on Unix-like Operating Systems
>> starting with QNX.
>
> Yes, many thanks for your script and kind offer!
>
> Excited if this will work - would like to figure out how to do it
> later on by myself, firstly. Did not do any kernel compile yet :)

Sorry for delay. I got booting from NVMe working now without recompile.

I took a step back to my error after installing OpenBSD onto the nvme
(without using the edk2 files).

The problem after a reboot is:

`** Invalid partition 3 **`
`Couldn't find partition nvme 0:3`
`Can't set block device`


Then I figured out:

`StarFive # ls nvme 0:1`
`efi/`
`0 file(s), 1 dir(s)`

But, after booting up from nvme like so:

`load` **mmc 1:1** `0x48000000 vendor/jh7110-starfive-visionfive-2-v1.3b.dtb`
`load` **nvme 0:1** `0x44000000 efi/boot/bootriscv64.efi`
`bootefi 0x44000000 0x48000000`

I mounted the efi folder on my nvme and the sdcard and copied over the
vendor folder from the sdcard to the nvme:

`vf2# mount_msdos /dev/sd0i /root/efinvme/`
`vf2# mount_msdos /dev/sd1i /root/efisdcard/`
`vf2# cp -r /root/efisdcard/vendor/ /root/efinvme/`

Now, (after another reboot) I can take out the sdcard and boot
directly from nvme like so:

`load` **nvme 0:1** `0x48000000 vendor/jh7110-starfive-visionfive-2-v1.3b.dtb`
`load` **nvme 0:1** `0x44000000 efi/boot/bootriscv64.efi`
`bootefi 0x44000000 0x48000000`


So I am happy this works now. Maybe I will ask about networking in
another post. Does not work for me so far on both ports after and
during installation...

No comments:

Post a Comment