编译 Linux 内核

下载与编译

git clone "https://gitee.com/thead-linux/linux-5.10.4.git"
make ARCH=riscv CROSS_COMPILE=riscv64-unknown-linux-gnu- defconfig
make -j ARCH=riscv CROSS_COMPILE=riscv64-unknown-linux-gnu- LOCALVERSION=

mkimage -A riscv -O linux -T kernel -C none \
  -a 0x00200000 -e 0x00200000 -n Linux \
  -d arch/riscv/boot/Image uImage

烧写

scp uImage root@192.168.1.100:/boot/uImage
scp arch/riscv/boot/dts/thead/*.dtb root@192.168.1.100:/boot/
ssh root@192.168.1.100 reboot

192.168.1.100 地址换成 EVB 开发板的网络 IP 地址。

results matching ""

    No results matching ""