custom kernel vs kernel 4.14 vs kernel 5_4

201 views
Skip to first unread message

Navin P

unread,
Nov 24, 2020, 1:57:18 AM11/24/20
to chromium-os-dev
Hi,


My board is amd64-generic . I'm on master.
My kernel selected is 4.14.205. I do a ./build_packages and
./build_image and everything is fine. So the kernel
files are already existing for 4.14.My latest points to
R89-13604.0.2020_11_23_1911-a1.
I do a cros_workon start sys-kernel/chromeos-kernel-5_4-9999
Now my problem starts when i choose emerge chromeos-kernel-5_4 i get
file collison error in
/build/amd64-generic/boot and /build/amd64-generic/usr/lib/debug/boot.
Then I clean the old 4.14 kernel by emerge-${BOARD} -C
chromeos-kernel-4.14 to prevent file collison.
Now after build_packages and emerge i have the new kernel in place.
Now I do a cros_workon stop .
Then i try to ./build_image , it fails because it tries to install
4.14 again and file collision occurs.
I also want to build kernels in linux-stable and torvalds-master. I
could achieve this by overwriting the
source kernel directory of 4.14 and it boots fine. It doesn't look
like a clean approach . Can you tell me
how to build a custom kernel like 5.9.9 and also a kernel like 5.4 ?
I would like to do some tests / benchmark
timing tests with the UI being the same.


Regards,
Navin

Navin P

unread,
Nov 24, 2020, 11:27:51 PM11/24/20
to chromium-os-dev
Hi,

Forgot to mention I'm booting through an external usb device.

My board is amd64-generic . I'm on master.My kernel selected is 4.14.205. I do a ./build_packages and ./build_image and everything is fine. So the kernel files are already existing for 4_14.My latest points to R89-13604.0.2020_11_23_1911-a1. I do a cros_workon start sys-kernel/chromeos-kernel-5_4-9999 Now my problem starts when i choose emerge chromeos-kernel-5_4 i get file collison error  in  /build/amd64-generic/boot and /build/amd64-generic/usr/lib/debug/boot.


Then I clean the old 4.14 kernel by emerge-${BOARD} -C chromeos-kernel-4.14 to prevent file collison. Now after build_packages and emerge  i have the new kernel in place. Now I do a cros_workon stop . Then i try to ./build_image , it fails because it tries to install 4.14 again and file collision occurs. I also want to build kernels in linux-stable and torvalds-master.

I could achieve this by overwriting the source kernel directory of 4.14 and it boots fine. It doesn't look like a clean approach .

Can you tell me how to build a custom kernel like 5.9.9  and also a kernel like 5.4 ? Older posts say you should download the code in third_party/kernel/ under 4_14.




Regards,
Navin

Daisuke Nojiri

unread,
Nov 26, 2020, 2:16:19 PM11/26/20
to Navin P, chromium-os-dev
Hi Navin,

Have you tried update_kernel.sh? I'm developing chromeos-kernel-5_4 but don't run build_image. https://chromium.googlesource.com/chromiumos/docs/+/master/kernel_development.md#Build-and-deploy.

--
--
Chromium OS Developers mailing list: chromiu...@chromium.org
View archives, change email options, or unsubscribe:
https://groups.google.com/a/chromium.org/group/chromium-os-dev
---
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-os-d...@chromium.org.

Dmitry Torokhov

unread,
Nov 26, 2020, 3:56:39 PM11/26/20
to Daisuke Nojiri, Navin P, chromium-os-dev
There are multiple profiles exist for amd64-generic board, including one with 5.4 kernel (take a look in src/overlays/overlay-amd64-generic/profiles). Use setup_board --board=$BOARD --profile=$PROFILE to select the one you want.

Or you can try quick and dirty "emerge-amd64-generic --unmerge chromeos-kernel-4_4; emerge-amd64-generic chromeos-kernel-5_4"

Navin P

unread,
Nov 27, 2020, 4:45:48 AM11/27/20
to Dmitry Torokhov, Daisuke Nojiri, chromium-os-dev
Thanks, that works for existing profiles. My other question was about
5.9.9 or 5.10.rc4+, can we do something quick ?
I haven't tried update_kernel.sh because you have to boot usb stick
on another device and setup the ip etc. I could try if it can usb
flash base or dev image created from ./build_image
--board=amd64-generic --noenable_rootfs_verification base or dev.

Vincent Palatin

unread,
Nov 27, 2020, 4:50:34 AM11/27/20
to Navin P, Dmitry Torokhov, Daisuke Nojiri, chromium-os-dev
On Fri, Nov 27, 2020 at 10:45 AM Navin P <navin...@gmail.com> wrote:
Thanks, that works for existing profiles. My other question was about
5.9.9 or 5.10.rc4+, can we do something quick ?

The easiest way might be the one pointed by the Chromium OS kernel development doc:
Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages