RZ-G/RZ-G2 BSP Porting OpenWRT
← Back to RZ-G/RZ-G2_BSP_Porting
SoC: All
Specification
Target OpenWRT OS Version: openwrt-22.03
Target reference board: RZ/G2L,/G2LC,/G2UL SMARC
Host PC Environment: Ubuntu20.04
OpenWRT build system setup bese on Ubuntu20.04
Run below command on Host Ubuntu PC
sudo apt update
sudo apt install build-essential ccache ecj fastjarfileg++gawk\
gettextgitjava-propose-classpath libelf-dev libncurses5-dev\
libncursesw5-dev libssl-dev python python2.7-dev python3unzipwget\
python-distutils-extra python3-setuptools python3-dev rsync subversion\
swigtimexsltproc zlib1g-dev
Download source code
git clone https://git.openwrt.org/openwrt/openwrt.git
The reasion why we need to choise 22.03 branch is because openwrt-22.03 use the same kernel version linux-5.10 with RZ/G2L VLP3.0.x yocto sdk, so we can reduce the hard difficulty when portting renesas's smarc board driver to the kernel.
openwrt22.03 base on kernel version 5.10.116
openwrt21.02 base on kernel version 5.4.194
openwrt19.07 base on kernel version 4.14.275
openwrt18.06 base on kernel version 4.14.206
Check out branch code |
cd openwrt
git branch -a
remotes/origin/HEAD -> origin/master remotes/origin/lede-17.01 remotes/origin/master remotes/origin/openwrt-18.06 remotes/origin/openwrt-19.07 remotes/origin/openwrt-21.02 remotes/origin/openwrt-22.03 git checkout openwrt-22.03 Branch 'openwrt-22.03' set up to track remote branch 'openwrt-22.03' from 'origin'. Switched to a new branch 'openwrt-22.03' git branch -a master
remotes/origin/HEAD -> origin/master remotes/origin/lede-17.01 remotes/origin/master remotes/origin/openwrt-18.06 remotes/origin/openwrt-19.07 remotes/origin/openwrt-21.02 remotes/origin/openwrt-22.03 |
Get current branch's application source code
cd openwrt
./scripts/feeds update -a && ./scripts/feeds install -a
Get current branch's application source code
cd openwrt
./scripts/feeds update -a && ./scripts/feeds install -a
Prepare kernel source code
Because openwrt22.03 use kernel version 5.10.xxx come from kernel.org, but this version source code download form kernel.org don't support RZ/G2L SMRAC EVK board build. So, we need to use external kernel code come from Renesas's GitHub.
git clone https://github.com/renesas-rz/rz_linux-cip cd rz_linux_cip git checkout rz-5.10-cip3
cd openwrt
make defconfig && make menuconfig
Select red box information
Target System () ---> Renesas
Subtarget ( ) ---> RZ/G2X MPU soc evk boards
Target Profile (smarc rzg2l) ---> smarc rzg2l