Browse Source

buildroot config: Modify initramfs and rootfs config

And update README.md

Signed-off-by: Andy Hu <andy.hu@starfivetech.com>
Andy Hu 2 years ago
parent
commit
949074336c
3 changed files with 37 additions and 66 deletions
  1. 24 33
      README.md
  2. 1 1
      conf/buildroot_initramfs_config
  3. 12 32
      conf/buildroot_rootfs_config

+ 24 - 33
README.md

@@ -25,9 +25,9 @@ Install required additional packages.
 
 ## Fetch code Instructions ##
 
-Checkout this repository (the multimedia branch: `JH7100_starlight_multimedia`). Then you will need to checkout all of the linked submodules using:
+Checkout this repository  (branch `JH7100_VisionFive`). Then you will need to checkout all of the linked submodules using:
 
-	$ git checkout --track origin/JH7100_starlight_multimedia
+	$ git checkout --track origin/JH7100_VisionFive
 	$ git submodule update --init --recursive
 
 This will take some time and require around 5GB of disk space. Some modules may
@@ -37,8 +37,8 @@ Once the submodules are initialized, 4 submodules `buildroot`, `HiFive_U-boot`,
 `linux` and `opensbi` need checkout to corresponding branches manually, seeing `.gitmodule`
 
 	$ cd buildroot && git checkout --track origin/starlight_multimedia && cd ..
-	$ cd HiFive_U-Boot && git checkout --track origin/JH7100_Multimedia_V0.1.0 && cd ..
-	$ cd linux && git checkout --track origin/visionfive-5.13.y-devel && cd ..
+	$ cd HiFive_U-Boot && git checkout --track origin/JH7100_upstream_devel && cd ..
+	$ cd linux && git checkout --track origin/visionfive-5.15.y-devel && cd ..
 	$ cd opensbi && git checkout master && cd ..
 
 ## Build Instructions ##
@@ -53,6 +53,8 @@ You can choose building your target board with `HWBOARD` variables.
 > For starlight-a1 or a2 board:  `make HWBOARD=starlight-a1`, or `make starlight-a1`
 > For starlight-a3 board:  `make HWBOARD=starlight`, or `make starlight`
 > For visionfive board: `make HWBOARD=visionfive`, or `make visionfive`
+>
+> Or run `export HWBOARD=visionfive` first, then use it as before
 
 Note that if not specify the  `HWBOARD` , the default `make`  is for visionfive, just equal to `make HWBOARD=visionfive`
 Also you can specify the system environment variables `HWBOARD` to choose the board, 
@@ -76,11 +78,11 @@ freelight-u-sdk/work/opensbi/platform/generic/firmware/fw_payload.bin.out
 Note the other make command to config uboot, linux, buildroot, busybox configuration:
 
 ```
-make uboot-menuconfig      # uboot menuconfig
-make linux-menuconfig      # Kernel menuconfig
-make buildroot_initramfs-menuconfig   # initramfs menuconfig
-make buildroot_rootfs-menuconfig      # rootfs menuconfig
-make -C ./work/buildroot_initramfs/ O=./work/buildroot_initramfs busybox-menuconfig  # for initrafs busybox menuconfig in
+$ make uboot-menuconfig      # uboot menuconfig
+$ make linux-menuconfig      # Kernel menuconfig
+$ make buildroot_initramfs-menuconfig   # initramfs menuconfig
+$ make buildroot_rootfs-menuconfig      # rootfs menuconfig
+$ make -C ./work/buildroot_initramfs/ O=./work/buildroot_initramfs busybox-menuconfig  # for initrafs busybox menuconfig in
 ```
 
 ## Running on VisionFive/Starlight Board ##
@@ -136,7 +138,7 @@ When you see the `buildroot login:` message, then congratulations, the launch wa
 
 The default display framework is `DRM` now.  Use `make linux-menuconfig`  follow below could change between `DRM` and `Framebuffer` framework
 
-If switch from `DRM`to `Framebuffer` display framework (`hdmi` display device), 
+#### If switch from `DRM`to `Framebuffer` display framework with`hdmi` display device:
 
 ```
 1. Disable the DRM feature:
@@ -154,7 +156,7 @@ Note: Recommend Disable the below for usdk:
    CONFIG_FRAMEBUFFER_CONSOLE
 ```
 
-If switch from `Framebuffer` to `DRM` display framework ( `hdmi` display device):
+#### If switch from `Framebuffer` to `DRM` display framework with `hdmi` display device:
 
 ```
 1. Disable the below kernel config
@@ -165,13 +167,13 @@ If switch from `Framebuffer` to `DRM` display framework ( `hdmi` display device)
 
 2. Enable the below kernel config:
    CONFIG_DRM_I2C_NXP_TDA998X
-   CONFIG_DRM_I2C_NXP_TDA9950
    CONFIG_DRM_STARFIVE
+   CONFIG_PHY_M31_DPHY_RX0
 
-Note: when use DRM to hdmi pipeline, please make sure CONFIG_DRM_STARFIVE_MIPI_DSI is disable, or will cause color abnormal.
+3. Recommend to disable CONFIG_FRAMEBUFFER_CONSOLE, and CONFIG_DRM_STARFIVE_MIPI_DSI
 ```
 
-If switch  from `Framebuffer`  to `DRM` display framework (`mipi dsi` display device):
+#### If switch  from `Framebuffer`  to `DRM` display framework with`mipi dsi` display device:
 
 ```
 based on the above drm to hdmi pipeline config, enable the below kernel config:
@@ -227,20 +229,11 @@ The visionfive and starlight board natively always support PWMDAC to audio-out (
 
 ## Appendix III: Build TF Card Booting Image
 
-If you don't already use a local tftp server, then you probably want to make the sdcard target; the default size is 16 GBs. NOTE THIS WILL DESTROY ALL EXISTING DATA on the target sdcard; please modify the following file.
-
-conf/beaglev_defconfig_513:
-
-```
-change
-CONFIG_CMDLINE="earlyprintk console=tty1 console=ttyS0,115200 debug rootwait stmmaceth=chain_mode:1"
-to
-CONFIG_CMDLINE="earlyprintk console=tty1 console=ttyS0,115200 debug rootwait stmmaceth=chain_mode:1 root=/dev/mmcblk0p3"
-```
+If you don't already use a local tftp server, then you probably want to make the TF card target; the default size is 16 GBs. NOTE THIS WILL DESTROY ALL EXISTING DATA on the target TF card; please modify the following file. The `GPT` Partition Table for the TF card is recommended. 
 
-HiFive_U-Boot/configs/starfive_jh7100_starlight_smode_defconfig(using starlight or starlight-a1 board)
+`HiFive_U-Boot/configs/starfive_jh7100_starlight_smode_defconfig`  (for `starlight` or `starlight-a1` board)
 or
-HiFive_U-Boot/configs/starfive_jh7100_visionfive_smode_defconfig (using visionfive board):
+`HiFive_U-Boot/configs/starfive_jh7100_visionfive_smode_defconfig`  (for `visionfive` board):
 
 ```
 change
@@ -257,13 +250,11 @@ CONFIG_BOOTCOMMAND="run mmcsetup; run fdtsetup; run fatenv; echo 'running boot2.
 Please insert the TF card and run command `df -h` to check the device name `/dev/sdXX`, then run command `umount /dev/sdXX`",  then run the following instructions to build TF card image:
 
 ```
-make buildroot_rootfs -jx
-make -jx
-make vpubuild_rootfs
-make clean
-make -jx
-make buildroot_rootfs -jx
-make DISK=/dev/sdX format-nvdla-rootfs && sync
+$ make buildroot_rootfs -jx
+$ make vpudriver-build-rootfs
+$ rm -rf work/buildroot_rootfs/images/rootfs.ext*
+$ make buildroot_rootfs -jx
+$ make DISK=/dev/sdX format-nvdla-rootfs && sync
 ```
 Note: please also do not forget to update the `fw_payload.bin.out` which is built by this step.
 

+ 1 - 1
conf/buildroot_initramfs_config

@@ -175,9 +175,9 @@ BR2_PACKAGE_HTOP=y
 BR2_PACKAGE_UTIL_LINUX_MOUNT=y
 BR2_PACKAGE_WAVE511=y
 BR2_PACKAGE_WAVE521=y
-BR2_PACKAGE_SF_GST_OMX=y
 BR2_PACKAGE_SF_OMX_IL=y
 BR2_PACKAGE_SF_OMX_IL_TEST=y
+BR2_PACKAGE_SF_GST_OMX=y
 BR2_PACKAGE_V4L2_TEST=y
 BR2_PACKAGE_PP_TEST=y
 BR2_PACKAGE_LIBCAMERA_APPS=y

+ 12 - 32
conf/buildroot_rootfs_config

@@ -1,35 +1,22 @@
 BR2_riscv=y
-BR2_TOOLCHAIN_BUILDROOT_GLIBC=y
-BR2_KERNEL_HEADERS_CUSTOM_GIT=y
-BR2_KERNEL_HEADERS_CUSTOM_REPO_URL="https://github.com/starfive-tech/linux.git"
-BR2_KERNEL_HEADERS_CUSTOM_REPO_VERSION="visionfive-5.15.y-devel"
-BR2_PACKAGE_GLIBC_UTILS=y
-BR2_GCC_VERSION_10_X=y
-BR2_TOOLCHAIN_BUILDROOT_CXX=y
 BR2_TOOLCHAIN_EXTERNAL=y
-BR2_TOOLCHAIN_BUILDROOT_FORTRAN=y
-BR2_GCC_ENABLE_LTO=y
-BR2_GCC_ENABLE_OPENMP=y
 BR2_TOOLCHAIN_EXTERNAL_PATH="$(RISCV)"
 BR2_TOOLCHAIN_EXTERNAL_CUSTOM_PREFIX="$(ARCH)-buildroot-linux-gnu"
 BR2_TOOLCHAIN_EXTERNAL_HEADERS_5_9=y
 BR2_TOOLCHAIN_EXTERNAL_CUSTOM_GLIBC=y
 BR2_TOOLCHAIN_EXTERNAL_CXX=y
+BR2_TOOLCHAIN_EXTERNAL_OPENMP=y
 BR2_INIT_SYSV=y
 BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_MDEV=y
 BR2_TARGET_GENERIC_ROOT_PASSWD="starfive"
-BR2_PACKAGE_BUSYBOX_SHOW_OTHERS=y
+BR2_SYSTEM_DHCP="eth0"
 BR2_PACKAGE_ALSA_UTILS=y
 BR2_PACKAGE_ALSA_UTILS_ALSACONF=y
 BR2_PACKAGE_ALSA_UTILS_ALSALOOP=y
-BR2_SYSTEM_BIN_SH_BUSYBOX=y
-BR2_SYSTEM_DHCP="eth0"
 BR2_PACKAGE_ALSA_UTILS_AMIXER=y
 BR2_PACKAGE_ALSA_UTILS_APLAY=y
 BR2_PACKAGE_ALSA_UTILS_ASEQDUMP=y
 BR2_PACKAGE_ALSA_UTILS_SPEAKER_TEST=y
-BR2_PACKAGE_BONNIE=y
-BR2_PACKAGE_CACHE_CALIBRATOR=y
 BR2_PACKAGE_FFMPEG_GPL=y
 BR2_PACKAGE_FFMPEG_FFPROBE=y
 BR2_PACKAGE_FFMPEG_AVRESAMPLE=y
@@ -37,7 +24,6 @@ BR2_PACKAGE_FFMPEG_POSTPROC=y
 BR2_PACKAGE_GSTREAMER1=y
 BR2_PACKAGE_GSTREAMER1_CHECK=y
 BR2_PACKAGE_GST1_PLUGINS_BASE_INSTALL_TOOLS=y
-BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_APP=y
 BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_AUDIOMIXER=y
 BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_AUDIORATE=y
 BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_AUDIOTESTSRC=y
@@ -50,7 +36,6 @@ BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_ALSA=y
 BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_OGG=y
 BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_OPUS=y
 BR2_PACKAGE_GST1_PLUGINS_BASE_PLUGIN_VORBIS=y
-BR2_PACKAGE_GST1_PLUGINS_GOOD=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_JPEG=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_PNG=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_AUDIOPARSERS=y
@@ -66,7 +51,6 @@ BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_LEVEL=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_MATROSKA=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_MULTIFILE=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_MULTIPART=y
-BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_RTP=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_RTSP=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_VIDEOCROP=y
 BR2_PACKAGE_GST1_PLUGINS_GOOD_PLUGIN_VIDEOFILTER=y
@@ -98,6 +82,8 @@ BR2_PACKAGE_GST1_PLUGINS_UGLY_PLUGIN_MPEG2DEC=y
 BR2_PACKAGE_GST1_PLUGINS_UGLY_PLUGIN_X264=y
 BR2_PACKAGE_GST1_LIBAV=y
 BR2_PACKAGE_GST1_RTSP_SERVER=y
+BR2_PACKAGE_BONNIE=y
+BR2_PACKAGE_CACHE_CALIBRATOR=y
 BR2_PACKAGE_DHRYSTONE=y
 BR2_PACKAGE_GDB=y
 BR2_PACKAGE_GDB_VERSION_9_2=y
@@ -106,22 +92,21 @@ BR2_PACKAGE_LMBENCH=y
 BR2_PACKAGE_RAMSMP=y
 BR2_PACKAGE_RAMSPEED=y
 BR2_PACKAGE_STRACE=y
+BR2_PACKAGE_STRESS_NG=y
+BR2_PACKAGE_WHETSTONE=y
 BR2_PACKAGE_E2FSPROGS=y
 BR2_PACKAGE_EXFAT=y
 BR2_PACKAGE_EXFAT_UTILS=y
 BR2_PACKAGE_MTD=y
-BR2_PACKAGE_STRESS_NG=y
 BR2_PACKAGE_NTFS_3G=y
 BR2_PACKAGE_GPTFDISK=y
 BR2_PACKAGE_GPTFDISK_GDISK=y
 BR2_PACKAGE_GPTFDISK_SGDISK=y
 BR2_PACKAGE_I2C_TOOLS=y
 BR2_PACKAGE_MEMTESTER=y
-BR2_PACKAGE_WHETSTONE=y
 BR2_PACKAGE_PCIUTILS=y
 BR2_PACKAGE_SYSSTAT=y
 BR2_PACKAGE_PYTHON3=y
-BR2_PACKAGE_OPENSSL=y
 BR2_PACKAGE_LIBKCAPI=y
 BR2_PACKAGE_LIBKCAPI_ENCAPP=y
 BR2_PACKAGE_LIBKCAPI_RNGAPP=y
@@ -168,7 +153,9 @@ BR2_PACKAGE_IPERF=y
 BR2_PACKAGE_IPERF3=y
 BR2_PACKAGE_IPTABLES=y
 BR2_PACKAGE_IPTABLES_NFTABLES=y
+BR2_PACKAGE_IPUTILS=y
 BR2_PACKAGE_IW=y
+BR2_PACKAGE_WGET=y
 BR2_PACKAGE_WPA_SUPPLICANT=y
 BR2_PACKAGE_WPA_SUPPLICANT_AP_SUPPORT=y
 BR2_PACKAGE_WPA_SUPPLICANT_WPS=y
@@ -178,13 +165,9 @@ BR2_PACKAGE_WPA_SUPPLICANT_WPA_CLIENT_SO=y
 BR2_PACKAGE_WPA_SUPPLICANT_PASSPHRASE=y
 BR2_PACKAGE_BASH=y
 BR2_PACKAGE_SCREEN=y
-BR2_PACKAGE_HTOP=y
-BR2_PACKAGE_IPUTILS=y
-BR2_PACKAGE_WGET=y
-BR2_PACKAGE_BASH=y
 BR2_PACKAGE_WHICH=y
 BR2_PACKAGE_COREUTILS=y
-BR2_PACKAGE_UTIL_LINUX=y
+BR2_PACKAGE_HTOP=y
 BR2_PACKAGE_UTIL_LINUX_BINARIES=y
 BR2_PACKAGE_UTIL_LINUX_AGETTY=y
 BR2_PACKAGE_UTIL_LINUX_BFS=y
@@ -210,7 +193,6 @@ BR2_PACKAGE_UTIL_LINUX_NOLOGIN=y
 BR2_PACKAGE_UTIL_LINUX_NSENTER=y
 BR2_PACKAGE_UTIL_LINUX_PARTX=y
 BR2_PACKAGE_UTIL_LINUX_PIVOT_ROOT=y
-#BR2_PACKAGE_UTIL_LINUX_RAW=y
 BR2_PACKAGE_UTIL_LINUX_RENAME=y
 BR2_PACKAGE_UTIL_LINUX_RUNUSER=y
 BR2_PACKAGE_UTIL_LINUX_SCHEDUTILS=y
@@ -229,13 +211,11 @@ BR2_PACKAGE_UTIL_LINUX_WALL=y
 BR2_PACKAGE_UTIL_LINUX_WDCTL=y
 BR2_PACKAGE_UTIL_LINUX_WRITE=y
 BR2_PACKAGE_UTIL_LINUX_ZRAMCTL=y
-BR2_PACKAGE_V4L2_TEST=y
-BR2_PACKAGE_PP_TEST=y
-BR2_PACKAGE_SF_GST_OMX=y
-BR2_PACKAGE_SF_OMX_IL=y
-BR2_PACKAGE_SF_OMX_IL_TEST=y
 BR2_PACKAGE_WAVE511=y
 BR2_PACKAGE_WAVE521=y
+BR2_PACKAGE_SF_OMX_IL=y
+BR2_PACKAGE_SF_OMX_IL_TEST=y
+BR2_PACKAGE_SF_GST_OMX=y
 BR2_PACKAGE_V4L2_TEST=y
 BR2_PACKAGE_PP_TEST=y
 BR2_PACKAGE_LIBCAMERA_APPS=y