Building specific kernel version

How I can build a specific kernel version for BPI-M5?? The major version in repository is 4.9 but I want to build 5.1 version.

You have to check if a 5.1 version with support for your board exists. I guess support is not in mainline linux,so you need to upport support from 4.9 to 5.1,but 5.1 is no lts version,better use 5.4.

I suggest

  • cloning bpi-repo (4.9),check for keenel exact version (dot-release)
  • add official kernel source in new branch (git remote add stable https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/refs/
  • clone the same version from stable tree and compare changes between these 2,
  • then you can try starting upporting by checkout the 5.x version and adding changes you’ve found
1 Like

Well, I’m not an expert in this matter, I just clone BPI-repo and build kernel as they said but I don’t know how to upport. I tried to replace Kernel folder from linux-stable cloned to BPI folder but it won’t compile.

First you need to get differences between bpi 4.9 and upstream 4.9

So clone bpi-repo,get kernel version (Makefile in linux-mt) and create a new branch with the same mainline version from stable tree or clone it in a new folder,maybe this is easier for the diff…