R-Car/Boards/Yocto-Gen3-CommonFAQ/How to use Renesas repository's kernel on R-Car Gen3 Starter Kit.

From eLinux.org
Jump to: navigation, search

How to use Renesas repository's kernel on R-Car Gen3 Starter Kit.

By replacing with upstream kernel/dtb, it 's enabled to boot it on Starter Kit. Below is how to build upstream kernel.

  1. Preparing aarch64 cross-compiler
    It is enough to execute one of the following:
    1. Using gcc-aarch64-linux-gnu
      sudo apt install g++-aarch64-linux-gnu
      export CROSS_COMPILE=aarch64-linux-gnu-
      export ARCH=arm64
    2. Using Yocto SDK
      Please refer to the R-Car/Boards/Yocto-Gen3##Build_SDK to install SDK.
      source /opt/poky/x.y.z/environment-setup-aarch64-poky-linux
    3. Using other cross compiler(ex. linaro, kernel.org and so on)
      Set environment variable "CROSS_COMPILE" and "ARCH":
      export CROSS_COMPILE=<path/to/compiler>/<compiler_prefix>
      export ARCH=arm64
  2. Build kernel
    1. The case to use latest drivers
      git clone git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-drivers.git
      cd renesas-drivers
      make renesas_defconfig
    2. The case to use latest SoC or features
      git clone git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-devel.git
      cd renesas-devel
      make renesas_defconfig
    3. Renesas Linux BSP which is used in Yocto BSP
      git clone git://github.com/renesas-rcar/linux-bsp
      cd linux-bsp
      make defconfig