Code Monkey home page Code Monkey logo

Comments (6)

danboid avatar danboid commented on June 27, 2024 1

I have now got Debian sid automatically booting from my m.2 SSD!

This is a hacky solution because it uses the booti command to load the kernel and initrd instead of using the u-boot sysboot command to parse the extlinux.conf file but its a step in the right direction and proves that direct SSD boot is possible with a current VF2 image.

You might want to run env default -a -f to reset your current u-boot config before running the following u-boot commands:

setenv boot_targets nvme0
setenv preboot 'run chipa_set_uboot;pci enum;nvme scan'
setenv bootargs 'root=/dev/nvme0n1p4 console=tty1 console=ttyS0,115200  debug rootwait  earlycon=sbi'
setenv kernel_comp_addr_r 0x50000000
setenv kernel_comp_size 0x04000000
setenv bootcmd 'fatload nvme 0:3 ${kernel_addr_r} vmlinuz-5.15.0-vf2-104+; fatload nvme 0:3 ${ramdisk_addr_r} initrd.img-5.15.0-vf2-104+; fatload nvme 0:3 ${fdt_addr_r} dtb-5.15.0-vf2-104+/starfive/jh7110-visionfive-v2.dtb; booti $kernel_addr_r $ramdisk_addr_r:$filesize $fdt_addr_r'
saveenv

from imagebuilder.

danboid avatar danboid commented on June 27, 2024

I dug out my powered USB 3.0 hub. The USB 3 SATA SSD adapter still only gives me ~200 Kb/s but I can use my 2.5" mechanical USB 3 disk when its plugged into the powered hub and I get about 110 MB/s reads which is pretty much its full speed.

from imagebuilder.

danboid avatar danboid commented on June 27, 2024

I've been looking into gettng the video decoding working. The README for the wave511 driver ( https://github.com/starfive-tech/soft_3rdpart.git ) says:

By default, VDEC uses the cma method to allocate mem from the general CMA space. If you want to specify a reserved space for VDEC, you can reserve it in the dts file. At the same time, in the file code/vdi/linux/driver/vdec.c, open the VPU_SUPPORT_RESERVED_VIDEO_MEMORY macro. Simple example of reservation method:

reserved_memory: reserved-memory {
	#address-cells = <2>;
	#size-cells = <2>;
	ranges;
    vpu_reserved: framebuffer@d8000000 {
        reg = <0x0 0xd8000000 0x0 0x20000000>;
    };
};
vpu_dec:vpu_dec@118F0000 {
    compatible = "starfive,vdec";
    reg = <0 0x118F0000 0 0x10000>;
    memory-region = <&vpu_reserved>;
    interrupt-parent = <&plic>;
    interrupts = <23>;
    clocks = <&vpuclk>;
    clock-names = "vcodec";
    status = "okay";
};

https://github.com/starfive-tech/soft_3rdpart/tree/JH7110_VisionFive2_devel/wave420l

If we can get wave420l to build and load its kernel module it promises realtime encoding of 4K H265, which is very impressive for a ~£100 SBC.

from imagebuilder.

danboid avatar danboid commented on June 27, 2024

I have been able to successfully boot your sid image directly from NVMe but only when manually entering these commands into u-boot:

nvme scan
fatload nvme 0:3 ${kernel_addr_r} vmlinuz-5.15.0-vf2-104+
fatload nvme 0:3 ${ramdisk_addr_r} initrd.img-5.15.0-vf2-104+
fatload nvme 0:3 ${fdt_addr_r} dtb-5.15.0-vf2-104+/starfive/jh7110-visionfive-v2.dtb
setenv bootargs 'root=/dev/nvme0n1p4 rw console=tty0 console=ttyS0,115200 earlycon rootwait'
setenv kernel_comp_addr_r 0x50000000
setenv kernel_comp_size 0x04000000
booti $kernel_addr_r $ramdisk_addr_r:$filesize $fdt_addr_r

I'll update you when I get u-boot configured correctly to directly boot into Debian - its clearly possible.

Let me know if you beat me to it please!

from imagebuilder.

hexdump0815 avatar hexdump0815 commented on June 27, 2024

sorry for the deleyed response, i'm mostly offline right now - i did not yet look into this - i think i remember a thread in the rvspace forum about it or it was in here maybe? - https://github.com/riscv/meta-riscv/pull/382/files

from imagebuilder.

danboid avatar danboid commented on June 27, 2024

Ignore my comment about vdec and the video driver. I've decompiled the current dts that your kernel is using and it already includes vdec support.

I've not had a proper go at getting the vdec ffmpeg to build yet.

from imagebuilder.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.