hexdump0815 / linux-mainline-on-arm-chromebooks

running linux mainline on arm chromebooks - for example: samsung xe303c12 and xe503c12 (snow and peach), acer c100, c101 and c201 (veyron speedy, minnie etc. and gru bob and kevin), medion s2013 and s2015 (veyron jaq, mighty etc.), acer cb5 311 (nyan big), lenovo n23, acer r13 (oak elm and hana), lenovo duet (kukui krane) and most probably many many more over time ...
159 stars 10 forks source link

chromebook_snow: misc: Trying to enable KVM on my Samsung Chromebook ARM "SNOW" model XE303C12 #3

Open Marietto2008 opened 2 years ago

Marietto2008 commented 2 years ago

Hello.

I would like to enable KVM on my old but still functional "Samsung Chromebook ARM "SNOW" model XE303C12" because later I want to virtualize FreeBSD with qemu and kvm. After having read this guide :

https://github.com/hexdump0815/imagebuilder/blob/main/systems/chromebook_snow/readme.md

I've dd ed this image to my MMC card :

https://github.com/hexdump0815/imagebuilder/releases/tag/220619-01

and yeah,it's working great.

BTW I'm not so experienced at understanding how to recompile the kernel (or is it enough to recompile only the modules related to KVM ?) without asking for some help,but if you want to put me in the right path,I can do it. On your github there seems to be a guide that I can follow :

https://github.com/hexdump0815/linux-mainline-and-mali-generic-stable-kernel/blob/master/readme.cbe

It says to grab the kernel source code from here :

https://github.com/hexdump0815/linux-mainline-and-mali-generic-stable-kernel/blob/master/gitrepo

I did it,but later,when I did :

git checkout origin/linux-5.18.y -b linux-5.18.y

I realized that on /usr/lib/modules has been created this folder :

5.18.17-stb-cbe

the problem is that it does not match with the kernel version that I'm running :

Linux changeme 5.18.1-stb-cbe+ #1 SMP PREEMPT Sun Jun 5 14:16:07 CEST 2022 armv7l armv7l armv7l GNU/Linux

at this point I tried with another kernel version :

https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/snapshot/linux-5.18.1.tar.gz

Is this the correct one ? At this point I generated the .config file with the command :

make olddefconfig

and I tried adding these flags to the .config file :

CONFIG_HAVE_KVM_IRQCHIP=y CONFIG_KVM_MMIO=y CONFIG_VIRTUALIZATION=y CONFIG_KVM=y CONFIG_KVM_ARM_HOST=y CONFIG_KVM_ARM_MAX_VCPUS=4 CONFIG_KVM_ARM_VGIC=y CONFIG_KVM_ARM_TIMER=y

I added them using two techniques :

1) with a text editor : but it didn't work. It seems that they don't stick inside the .config file

2) with the command : make menuconfig and I looked for the KVM flags inside the other kernel entries,but I found nothing.

Since I'm not so experienced,I don't know what to do further ; I don't understand where the mistake is. -- Mario.

hexdump0815 commented 2 years ago

@Marietto2008 - for kvm the changes are not in modules i think, so you'll have to build a full kernel in that case ... i'll write some quick info about how to build a new kernel based on the images and the existing notes - i had that planned anyway to make it easier for others to get started with it (its not that complicated actually) - it might take a few days, but should hopefully be ready soon

as an alternative option i plan to maybe build a v5.19.1 kernel for snow as well and i might try to add the kvm options for it while i'm on it - this might take a few more days even :) ... anyway: either way you should hopefully end up with kvm on your snow at some point in the near future ... i really like it when people start to push some new life into those devices :) ... this is actually one of the reasons for all this - those devices are still too useful to just put them into a shelf or even worse the bin ...

Marietto2008 commented 2 years ago

yeah,thanks. I'm trying to ask here and there to understand how to do it by my own,but it will take more time than the time you need to write a small tutorial or to release a new kernel version,just because I'm an hobbyst. My real job is another one. So,while I wait for your updates,I will continue asking and reading and trying.

hexdump0815 commented 2 years ago

sounds like a good plan :)

hexdump0815 commented 2 years ago

it just came to my mind that your plan is more challangeing than initially expected as the kvm host support was dropped for 32bit arm linux in v5.7 and in qemu v5.1, so the latest kernel you can use would be v5.4 (as latest lts release which still gets updates below v5.7) and the latest possible qemu would be v5.0 ...

Marietto2008 commented 2 years ago

So,this is the reason why the adding of the KVM flags inside the kernel config file don't stick. Anyway in my opinion kernel 5.4 and qemu 5.0 are still enough good today and it still worth to work on the project. More challenging it is,more interesting it is. (for sure there are limitations to this assumption,because a newbie can't afford too much complicated projects,but one thing is to enjoy trying,another one is to surrend without).

Marietto2008 commented 2 years ago

I began to work on this :

# tar -xvzf linux-stable.tar.gz
# cd /home/linux/Desktop/Work/linux-stable
# git checkout origin/linux-5.4.y -b linux-5.4.y
Updating files: 100% (65261/65261), done.
Branch 'linux-5.4.y' set up to track remote branch 'linux-5.4.y' from 'origin'.
Switched to a new branch 'linux-5.4.y'
patch -p1 < /home/linux/Desktop/Work/misc.cbe/patches/snow-v5-4-suspend-fix.patch

patching file drivers/input/keyboard/cros_ec_keyb.c
Hunk #1 succeeded at 630 (offset 4 lines).
patching file drivers/platform/chrome/cros_ec.c
Hunk #1 succeeded at 235 with fuzz 2 (offset 19 lines).
Hunk #2 succeeded at 260 (offset 20 lines).

patch -p1 < /home/linux/Desktop/Work/misc.cbe/patches/exynos5250-mali-complete.patch

patching file drivers/gpu/Makefile
patching file drivers/video/Kconfig

# cd /home/linux/Desktop/Work/misc.cbe
# git clone https://github.com/hexdump0815/kernel-extra-patches.git
# cd /home/linux/Desktop/Work/linux-stable
# nano multi-gen-lru.sh

for i in /home/linux/Desktop/Work/misc.cbe/kernel-extra-patches/multi-gen-lru/v11/*.diff; do
  echo === $i
  patch -p1 < $i
done

# chmod +x multi-gen-lru.sh
# ./multi-gen-lru.sh

=== /home/linux/Desktop/Work/misc.cbe/kernel-extra-patches/multi-gen-lru/v11/v11-01-14-mm-x86-arm64-add-arch_has_hw_pte_young.diff
patching file arch/arm64/include/asm/pgtable.h
Hunk #1 FAILED at 999.
1 out of 1 hunk FAILED -- saving rejects to file arch/arm64/include/asm/pgtable.h.rej
patching file arch/x86/include/asm/pgtable.h
Hunk #1 FAILED at 1424.
1 out of 1 hunk FAILED -- saving rejects to file arch/x86/include/asm/pgtable.h.rej
can't find file to patch at input line 53
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/include/linux/pgtable.h b/include/linux/pgtable.h
|index f4f4077b97aa..79f64dcff07d 100644
|--- a/include/linux/pgtable.h
|+++ b/include/linux/pgtable.h
--------------------------
File to patch: 

# patch -p1 < /home/linux/Desktop/Work/misc.cbe/patches/disable-panfrost-gpu-node-v5.4.patch
patching file arch/arm/boot/dts/exynos5250.dtsi

# patch -p1 < /home/linux/Desktop/Work/misc.cbe/patches/disable-usb3.patch
patching file arch/arm/boot/dts/exynos5250-snow-common.dtsi
Hunk #3 succeeded at 622 (offset 5 lines).
Hunk #4 succeeded at 698 (offset 5 lines).

# patch -p1 < /home/linux/Desktop/Work/misc.cbe/patches/fix-arm-errata-766421.patch
patching file arch/arm/Kconfig
Hunk #1 succeeded at 1118 (offset -2 lines).
patching file arch/arm/mach-exynos/Kconfig
Hunk #1 succeeded at 69 with fuzz 2 (offset -1 lines).
patching file arch/arm/mm/proc-v7-2level.S

# patch -p1 < /home/linux/Desktop/Work/misc.cbe/patches/fix-atmel-touchpad.patch
patching file arch/arm/boot/dts/exynos5250-snow-common.dtsi

# export ARCH=arm

# make olddefconfig
  HOSTCC  scripts/basic/fixdep
  HOSTCC  scripts/kconfig/conf.o
  HOSTCC  scripts/kconfig/confdata.o
  HOSTCC  scripts/kconfig/expr.o
  LEX     scripts/kconfig/lexer.lex.c
  YACC    scripts/kconfig/parser.tab.[ch]
  HOSTCC  scripts/kconfig/lexer.lex.o
  HOSTCC  scripts/kconfig/parser.tab.o
  HOSTCC  scripts/kconfig/preprocess.o
  HOSTCC  scripts/kconfig/symbol.o
  HOSTLD  scripts/kconfig/conf
scripts/kconfig/conf  --olddefconfig Kconfig
drivers/video/Kconfig:22: can't open file "drivers/gpu/arm/Kconfig"
make[1]: *** [scripts/kconfig/Makefile:73: olddefconfig] Error 1
make: *** [Makefile:590: olddefconfig] Error 2

/home/linux/Desktop/Work/linux-stable/drivers/gpu/arm does not exists. Instead,it exists : /home/linux/Desktop/Work/linux-5.4.210/drivers/gpu/drm. I don't know why. 

to be continued....

Marietto2008 commented 2 years ago

I've recompiled the kernel to enable kvm for my arm chromebook and I found that the latest kernel version where it is still supported is the 5.6.19 and not the 5.4. I've used ubuntu 14 virtualized with bhyve under freebsd 13.1-RELEASE to recompile the kernel).

Screenshot_2022-08-19_03-11-46

hexdump0815 commented 2 years ago

@Marietto2008 - you'll have to skip the mglru patches as they are not supported well back in v5.4 ... better use v5.4 than v5.6 as v5.4 is an lts kernel which still gets fixes (and that for a few years still even) while v5.6 is a dead end - they are both old, so those two version numbers should not matter much ... good progress so far - good luck

Marietto2008 commented 2 years ago

the mali complete patch can't be applied :

root@marietto-BHYVE:/home/marietto/Scrivania/Files/cb/linux-5.4.210# patch -p1 < /home/marietto/Scrivania/Files/cb/misc.cbe/patches/exynos5250-mali-complete.patch

patching file drivers/gpu/Makefile
patching file drivers/video/Kconfig

root@marietto-BHYVE:/home/marietto/Scrivania/Files/cb/linux-5.4.210# make menuconfig
scripts/kconfig/mconf  Kconfig
drivers/video/Kconfig:22: can't open file "drivers/gpu/arm/Kconfig"
make[2]: *** [menuconfig] Errore 1
make[1]: *** [menuconfig] Errore 2
make: *** [sub-make] Errore 2
Marietto2008 commented 2 years ago

ok. Next step,next error to fix :

root@marietto-BHYVE:/home/marietto/Scrivania/Files/cb/linux-5.4.210# make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- uImage dtbs

 LD      arch/arm/boot/compressed/vmlinux
  OBJCOPY arch/arm/boot/zImage
  Kernel: arch/arm/boot/zImage is ready
multiple (or no) load addresses: 
This is incompatible with uImages
Specify LOADADDR on the commandline to build an uImage
make[2]: *** [arch/arm/boot/uImage] Errore 1
make[1]: *** [uImage] Errore 2
make: *** [sub-make] Errore 2

maybe fixed like this :

root@marietto-BHYVE:/home/marietto/Scrivania/Files/cb/linux-5.4.210/arch/arm/boot# mkimage -A arm -O linux -T kernel -C none -a 0x80008000 -e 0x80008000 -n "Linux kernel" -d zImage uImage

hexdump0815 commented 2 years ago

at which command this happend? i'm building all my kernels walways following the corresponding readme files (readme.cbt in this case), so the notes should be correct in principle.

Marietto2008 commented 2 years ago

I haven't applied none of your patches. Maybe only one of your patches works good. I mean. Most of them can be applied,but later,they don't allow the kernel to be compiled without errors. For the last error I don't care,since I have converted zImage to uImage. Now I have another problem to fix. When I give this command :

# make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- dtbs

it does not produce any dtb file. Below you can see the files produced by the command :

Istantanea_2022-08-20_16-25-21

I don't see the file I need. So,I've been forced to get it from this site :

$ wget http://www.virtualopensystems.com/downloads/guides/kvm_on_chromebook/exynos5250-snow.dtb

I don't know if it will work,because I suspect that it is tailored for the kernel 3.13....

and ... what should I do to boot the new kernel ? I see that to swap the old kernel with the new one is not enough. And,where I can get the ubuntu 20.04 for arm32 ? I see that the kernel 5.4 belongs to this ubuntu version. I'm not sure that it works for the ubuntu 22.04 that I have installed on the sd card.

hexdump0815 commented 2 years ago

you definitely need a proper dtb for this kernel version - setting config options should not affect the dtb, so the dtb from some of my older v5.4 kernel builds should work too (https://github.com/hexdump0815/linux-mainline-and-mali-generic-stable-kernel/releases/tag/5.4.58-stb-cbe%2B maybe), but i think if making the dtbs is a problem when cross compiling it should be possible to find a solution for it on the net somewhere

hexdump0815 commented 2 years ago

btw. working patches for v5.4 you should find at this tagged version of the tree: https://github.com/hexdump0815/linux-mainline-and-mali-generic-stable-kernel/tree/5.4.58-stb-cbe+

Marietto2008 commented 2 years ago

I've installed your "ready to go" ubuntu 18.04 image file on the sd card instead of the 22.04. The 18.04 runs with the proper kernel,5.4. So,I suppose that ubuntu 20.04 runs with an higher kernel and it is not good. I don't know if an higher ubuntu version can run with a lower kernel. For example,can ubuntu 21.04 runs with the kernel 5.4 ? Again,I suppose that your ubuntu 18.04 is already patched and it has the proper config files in place,including the dtb file. What I need to do is only to recompile its current installed kernel adding the KVM flags and it should go. Is this correct ?

hexdump0815 commented 2 years ago

yes, that should work as well ... ubuntu/debian versions and kernel versions are usually quite flexible - there might be minor problems but most of the time it just works - for some older chromebook images i have working debian bullseye / ubuntu focal images with the legacy chromeos kernel which is v3.8 or similar (like for instance for snow) and only some minimal hacks were required to make it work

Marietto2008 commented 2 years ago

ok. anyway,I'm going to try with the 18.04 : maybe I can upgrade it,keeping everything already configured on the 20.04 and 22.04 :P ; that's because In this case things are easier. If I use the same kernel version used by you,I suppose that I should swap only the kernel file. If I use ubuntu 22.04,there are more files to swap and I don't know what they are. I was confused about what to do when I was running 22.04.

Marietto2008 commented 2 years ago

I'm frozen with this problem : https://askubuntu.com/questions/1424888/how-to-expand-the-space-of-the-partition-dev-sdf4-until-the-end-of-the-sdcard/1424891?noredirect=1#comment2481148_1424891 ; if you want to help me,I appreciate.

hexdump0815 commented 2 years ago

extending the rootfs to the end of the disk should simpy work by booting your snow from my image and then run /scripts/extend-rootfs.sh as root asuming you have inserted the sd card into the sd card slot of the snow

hexdump0815 commented 2 years ago

btw. using the older ubuntu image might have the advantage that it will most problably also have an older version of qemu which should still support 32bit arm ...

Marietto2008 commented 2 years ago

here :

https://installati.one/ubuntu/22.04/qemu-efi-arm/

it says that qemu-efi-arm can be installed on Ubuntu 22.04 and it is the UEFI firmware for 32-bit ARM virtual machines

Marietto2008 commented 2 years ago

ubuntu 18.04 root fs can't be expanded,ubuntu 22.04 yes. check the log below. And the expand root script is not on the ubuntu 18.04 image,but only on the 22.04.

root@changeme:/home/linux/Desktop# ./extend-rootfs.sh

resizing root filesystem

GPT PMBR size mismatch (14682111 != 384503807) will be corrected by w(rite).
GPT PMBR size mismatch (14682111 != 384503807) will be corrected by w(rite).

Welcome to fdisk (util-linux 2.31.1).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.

GPT PMBR size mismatch (14682111 != 384503807) will be corrected by w(rite).
GPT PMBR size mismatch (14682111 != 384503807) will be corrected by w(rite).

Command (m for help): Partition number (1-4, default 4):
Partition 4 has been deleted.

Command (m for help): Partition number (4-128, default 4): First sector (34-14682078, default 5283840): Last sector, +sectors or +size{K,M,G,T,P} (5283840-14682078, default 14682078):
Created a new partition 4 of type 'Linux filesystem' and of size 4.5 GiB.
Partition #4 contains a ext4 signature.

Command (m for help):
Expert command (m for help): Partition number (1-4, default 4):
New UUID (in 8-4-4-4-12 format):
Partition UUID changed from 4239DF9B-09E7-B148-9135-19BD4D6299C4 to 77B032BB-8642-B04A-A2DD-CC066E8F7CA5.

Expert command (m for help):
Command (m for help): Disk /dev/mmcblk1: 183.4 GiB, 196865949696 bytes, 384503808 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 1476FABD-1E9B-4B8E-B55E-5BD7E8EB66FF

Device           Start      End Sectors  Size Type
/dev/mmcblk1p1    8192    40959   32768   16M ChromeOS kernel
/dev/mmcblk1p2   40960  1089535 1048576  512M Linux filesystem
/dev/mmcblk1p3 1089536  5283839 4194304    2G Linux swap
/dev/mmcblk1p4 5283840 14682078 9398239  4.5G Linux filesystem

Command (m for help): GPT PMBR size mismatch (14682111 != 384503807) will be corrected by w(rite).
fdisk: failed to write disklabel: Invalid argument
resize2fs 1.44.1 (24-Mar-2018)
The filesystem is already 1174779 (4k) blocks long.  Nothing to do!
Marietto2008 commented 2 years ago

this is the kernel that I'm running right now :


root@changeme:/home/linux/Desktop/linux-5.4.3/linux-mainline-and-mali-generic-stable-kernel/misc.cbe/patches# uname -a

Linux changeme 5.4.3-stb-cbe+ #1 SMP PREEMPT Sat Dec 14 11:19:06 CET 2019 armv7l armv7l armv7l GNU/Linux

after having cloned this repo :

git clone https://github.com/hexdump0815/linux-mainline-and-mali-generic-stable-kernel.git

I've found on my chromebook this folder where should be the patches to apply :

root@changeme:/home/linux/Desktop/linux-5.4.3/linux-mainline-and-mali-generic-stable-kernel/misc.cbe/patches# ls

disable-panfrost-gpu-node-v5.4.patch  fix-atmel-touchpad.patch
disable-usb3.patch                    fix-mali-compile-v5.15.patch
disable-usb3-v5.18.patch              fix-mali-compile-v5.18.patch
exynos5250-mali-complete              fix-mali-compile-v5.9.patch
exynos5250-mali-complete.patch        snow-v5-4-suspend-fix.patch
fix-arm-errata-766421.patch

the problem is that these patches seem to belong to another kernel version,the 5.4.58-stb-cbe+,as you can see from the screenshot below :

Istantanea_2022-08-26_11-52-47

so,should I apply those patches anyway ?

Marietto2008 commented 2 years ago

the exynos5250-mali-complete.patch does not work neither with kernel 5.4.3 nor with the cross compiling or with the native gcc 7 compiler for arm32. maybe it works with the kernel 3.13,but I don't want to use a such old kernel version.

root@changeme:/home/linux/Desktop/linux-5.4.3# make olddefconfig
  LEX     scripts/kconfig/lexer.lex.c
  YACC    scripts/kconfig/parser.tab.[ch]
  HOSTCC  scripts/kconfig/lexer.lex.o
  HOSTCC  scripts/kconfig/parser.tab.o
  HOSTCC  scripts/kconfig/preprocess.o
  HOSTCC  scripts/kconfig/symbol.o
  HOSTLD  scripts/kconfig/conf
scripts/kconfig/conf  --olddefconfig Kconfig
drivers/video/Kconfig:22: can't open file "drivers/gpu/arm/Kconfig"
scripts/kconfig/Makefile:73: recipe for target 'olddefconfig' failed
make[1]: *** [olddefconfig] Error 1
Makefile:567: recipe for target 'olddefconfig' failed
make: *** [olddefconfig] Error 2
Marietto2008 commented 2 years ago

I tried to enable the KVM flags in this way :

root@changeme:/home/linux/Desktop/linux-5.4.3# make menuconfig
scripts/kconfig/mconf  Kconfig
.config:5384:warning: override: reassigning to symbol VIRTUALIZATION

but I realized that they don't stick. I don't know why. It sticked when I used the cross compilation,but they don't stick if I use the native arm compiler.

I've added the KVM flags inside the .config file :

Istantanea_2022-08-26_12-40-31

but when I make menuconfig,I see that KVM is set to no :

Istantanea_2022-08-26_12-38-47

Marietto2008 commented 2 years ago

this patch (mali complete patch) :

diff --git a/drivers/gpu/Makefile b/drivers/gpu/Makefile
index f17d01f076c7..43c37d08dac6 100644
--- a/drivers/gpu/Makefile
+++ b/drivers/gpu/Makefile
@@ -3,5 +3,5 @@
 # taken to initialize them in the correct order. Link order is the only way
 # to ensure this currently.
 obj-$(CONFIG_TEGRA_HOST1X) += host1x/
-obj-y          += drm/ vga/
+obj-y          += drm/ vga/ arm/
 obj-$(CONFIG_IMX_IPUV3_CORE)   += ipu-v3/
diff --git a/drivers/video/Kconfig b/drivers/video/Kconfig
index 427a993c7f57..c844d513537e 100644
--- a/drivers/video/Kconfig
+++ b/drivers/video/Kconfig
@@ -19,6 +19,8 @@ source "drivers/gpu/ipu-v3/Kconfig"

 source "drivers/gpu/drm/Kconfig"

+source "drivers/gpu/arm/Kconfig"
+
 menu "Frame buffer Devices"
 source "drivers/video/fbdev/Kconfig"
 endmenu

does not work.

Marietto2008 commented 2 years ago

this is the end of the challenge. I've recompiled the kernel,I have the uImage and the zImage file. I've renamed the old zImage file located on the /boot folder of the ubuntu 18,04 such as zImage-5.4.3-stb-cbe+_ and I've copied the recompiled kernel at the same place with the old name (zImage-5.4.3-stb-cbe+) and I've rebooted. Unfortunately it freezes on boot :

WhatsApp Image 2022-08-26 at 15 38 17

WhatsApp Image 2022-08-26 at 15 38 28

I haven't recompiled the dtbs file because it won't do that using "ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf-" ; so I have re used the old file already present on the boot folder (and created by you,using the same kernel that I've used).

hexdump0815 commented 2 years ago

i would recommend you to try to not cross compile but instead to build directly on the snow - for that you would first have to resolve the reason why your rootfs does not extend properly - its hard to debug remotely, but maybe have a look at /scripts/extend-rootfs.sh and try to see the steps it does and try to do them by hand to see where it does not work and maybe google might help to get it working ... once you have the rootfs extended do a "/scripts/install-buildtools.sh" and a /scripts/recreate-swapfile.sh 2G" - then checkout the 5.4.58-stb-cbe+ branch to /compile/doc/stable via "git clone -b 5.4.58-stb-cbe+ https://github.com/hexdump0815/linux-mainline-and-mali-generic-stable-kernel /compile/doc/stable" and do a "git clone --depth 1 -b v5.4.58 https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git /compile/source/linux-stable" and a "mkdir -p /compile/result/stable" - afterwards you should be able to build a kernel simply following https://github.com/hexdump0815/linux-mainline-and-mali-generic-stable-kernel/blob/5.4.58-stb-cbe%2B/readme.cbe - then create an entry for this new kernel in /boot/extlinux/extlinux.conf and try to boot it ... if all the above works (which it should as this is what i used to build all this) the next steps would be trying to add the kvm options, rebuilding the kernel and maybe later using the latest v5.4 kernel sources as a base

good luck and best wishes - hexdump

Marietto2008 commented 2 years ago

I have fixed the problem of the root fs that didn't want to extend. I've used a Windows 10 repartitioning tool and it did the job,even if it caused a lot of errors inside the file system. But later I have fixed all these errors with fsck. It worked. Anyway,the method that I have used is a little bit un-orthodox. I suggest you to give a look at the reasons. I don't know if you know that the scripts you are talking about are on the root of the ubuntu 22.04 filesystem,but not on the root of the ubuntu 18.04 fs. Another problem that I'm experimenting is that as soon as I start the kernel recompilation (with the linaro cross compiler and with your build tools),the KVM flags that I have added inside the .config file disappear if I use the kernel sources 5.4. But it does not happens if I use the 3.12.

Marietto2008 commented 2 years ago

tell me if I'm going well,please :

root@changeme:/compile/source# cd linux-stable

root@changeme:/compile/source/linux-stable# ls

arch   COPYING  Documentation  include  Kbuild   lib          Makefile  README   security  usr
block  CREDITS  drivers        init     Kconfig  LICENSES     mm        samples  sound     virt
certs  crypto   fs             ipc      kernel   MAINTAINERS  net       scripts  tools

root@changeme:/compile/source/linux-stable# patch -p1 < /compile/doc/stable/misc.cbe/snow-v5-4-suspend-fix.patch

patching file drivers/input/keyboard/cros_ec_keyb.c
Hunk #1 succeeded at 629 (offset 3 lines).
patching file drivers/platform/chrome/cros_ec.c
Hunk #1 succeeded at 235 with fuzz 2 (offset 19 lines).
Hunk #2 succeeded at 260 (offset 20 lines).

root@changeme:/compile/source/linux-stable# patch -p1 < /compile/doc/stable/misc.cbe/disable-usb3.patch
patching file arch/arm/boot/dts/exynos5250-snow-common.dtsi
Hunk #3 succeeded at 622 (offset 5 lines).
Hunk #4 succeeded at 698 (offset 5 lines).

root@changeme:/compile/source/linux-stable# patch -p1 < /compile/doc/stable/misc.cbe/exynos5250-mali-complete.patch
patching file arch/arm/boot/dts/exynos5250-snow-common.dtsi
Hunk #1 succeeded at 534 (offset 5 lines).
patching file arch/arm/boot/dts/exynos5250.dtsi
Hunk #1 succeeded at 1137 (offset 40 lines).
patching file drivers/gpu/Makefile
patching file drivers/video/Kconfig

root@changeme:/compile/source/linux-stable# cp -r /compile/doc/stable/misc.cbe/exynos5250-mali-complete/drivers/gpu/arm drivers/gpu

root@changeme:/compile/source/linux-stable# patch -p1 < /compile/doc/stable/misc.cbe/disable-panfrost-gpu-node-v5.4.patch
patching file arch/arm/boot/dts/exynos5250.dtsi

root@changeme:/compile/source/linux-stable# cp /compile/doc/stable/config.cbe /compile/source/linux-stable/.config

root@changeme:/compile/source/linux-stable# export ARCH=arm

root@changeme:/compile/source/linux-stable# nano .config (and added the KVM flags)

root@changeme:/compile/source/linux-stable# export ARCH=arm

root@changeme:/compile/source/linux-stable# make oldconfig
  HOSTCC  scripts/basic/fixdep
  HOSTCC  scripts/kconfig/conf.o
  HOSTCC  scripts/kconfig/confdata.o
  HOSTCC  scripts/kconfig/expr.o
  LEX     scripts/kconfig/lexer.lex.c
  YACC    scripts/kconfig/parser.tab.[ch]
  HOSTCC  scripts/kconfig/lexer.lex.o
  HOSTCC  scripts/kconfig/parser.tab.o
  HOSTCC  scripts/kconfig/preprocess.o
  HOSTCC  scripts/kconfig/symbol.o
  HOSTLD  scripts/kconfig/conf
scripts/kconfig/conf  --oldconfig Kconfig
.config:5411:warning: override: reassigning to symbol VIRTUALIZATION
*
* Restart config...
*
*
* Virtualization
*
Virtualization (VIRTUALIZATION) [Y/n/?] y
  Host kernel accelerator for virtio net (VHOST_NET) [N/m/y/?] (NEW) y
  Cross-endian support for vhost (VHOST_CROSS_ENDIAN_LEGACY) [N/y/?] (NEW) y
#
# configuration written to .config
#
root@changeme:/compile/source/linux-stable# nano .config 

at this point I've realized that inside the .config file all the KVM flags are disappeared and I don't know if it is good. Infact I did "make menuconfig" and boom,as you see KVM has been put to n"

Screenshot_2022-08-27_00-15-39

Screenshot_2022-08-27_00-20-47

Screenshot_2022-08-27_00-22-43

I suspect that the kernel 5.4.58 does not support kvm on arm32....

Marietto2008 commented 2 years ago

I've been able to produce the new kernel and the new dtb file,but sound and wi-fi don't work anymore with the new kernel 5.4.58.

hexdump0815 commented 2 years ago

maybe kvm is disabled automatically - see the "depends on" section in the make menuconfig help for it - maybe some other options have to be turned on to be able to enable it? - otherwise i have no real idea - i think v5.4 should still have kvm support - maybe its not supported on snow? but i think i read something about people using it on older kernels, so it should still work

wifi, sound: any erros or warning in dmesg on boot?

Marietto2008 commented 2 years ago

wi-fi and sounds work. I'd missed some command lines :P ; but kvm does not :


root@changeme:/home/linux# kvm-ok
INFO: /dev/kvm does not exist
HINT:   sudo modprobe kvm
modprobe: FATAL: Module msr not found in directory /lib/modules/5.4.58-stb-cbe+
root@changeme:/home/linux# sudo modprobe kvm
modprobe: FATAL: Module kvm not found in directory /lib/modules/5.4.58-stb-cbe+

infact the kvm flags inside the config file are disappeared.

hexdump0815 commented 2 years ago

i just had a quick look: it looks like you are missing CONFIG_ARM_LPAE - CONFIG_KVM help text: "Depends on: VIRTUALIZATION [=y] && MMU [=y] && OF [=y] && ARM_VIRT_EXT [=y] && ARM_LPAE [=n] && ARM_ARCH_TIMER [=y]" ... if CONFIG_ARM_LPAE is enabled then CONFIG_KVM stays ... not sure if the kernel with CONFIG_ARM_LPAE will still work - you'll have to try it out - good luck

Marietto2008 commented 2 years ago

Tried. At some point the screen of the chromebook becomes black and nothing happens anymore (yes,the KVM flags stick). This is the log of what I did :

export ARCH=arm
make oldconfig
make -j 4 zImage dtbs modules
export kver=`make kernelrelease`
echo ${kver}
# remove debug info if there and not wanted
# find . -type f -name '*.ko' | sudo xargs -n 1 objcopy --strip-unneeded
make modules_install
# make headers_install INSTALL_HDR_PATH=/usr

  HDRINST usr/include/asm-generic/swab.h
  HDRINST usr/include/asm-generic/termbits.h
  HDRINST usr/include/asm-generic/mman.h
  HDRINST usr/include/asm-generic/unistd.h
  HDRINST usr/include/asm-generic/signal-defs.h
  HDRINST usr/include/asm-generic/sockios.h
  HDRINST usr/include/asm-generic/setup.h
  HDRINST usr/include/asm-generic/bitsperlong.h
  HDRINST usr/include/asm-generic/types.h
  HDRINST usr/include/asm-generic/bpf_perf_event.h
  HDRINST usr/include/rdma/ib_user_sa.h
  HDRINST usr/include/rdma/ocrdma-abi.h
  HDRINST usr/include/rdma/ib_user_verbs.h
  HDRINST usr/include/rdma/qedr-abi.h
  HDRINST usr/include/rdma/efa-abi.h
  HDRINST usr/include/rdma/rdma_user_rxe.h
  HDRINST usr/include/rdma/siw-abi.h
  HDRINST usr/include/rdma/hns-abi.h
  HDRINST usr/include/rdma/mlx5_user_ioctl_verbs.h
  HDRINST usr/include/rdma/i40iw-abi.h
  HDRINST usr/include/rdma/ib_user_mad.h
  HDRINST usr/include/rdma/vmw_pvrdma-abi.h
  HDRINST usr/include/rdma/rdma_user_cm.h
  HDRINST usr/include/rdma/cxgb4-abi.h
  HDRINST usr/include/rdma/mlx5_user_ioctl_cmds.h
  HDRINST usr/include/rdma/mthca-abi.h
  HDRINST usr/include/rdma/rdma_user_ioctl_cmds.h
  HDRINST usr/include/rdma/rdma_netlink.h
  HDRINST usr/include/rdma/mlx5-abi.h
  HDRINST usr/include/rdma/hfi/hfi1_ioctl.h
  HDRINST usr/include/rdma/hfi/hfi1_user.h
  HDRINST usr/include/rdma/rdma_user_ioctl.h
  HDRINST usr/include/rdma/mlx4-abi.h
  HDRINST usr/include/rdma/ib_user_ioctl_cmds.h
  HDRINST usr/include/rdma/ib_user_ioctl_verbs.h
  HDRINST usr/include/rdma/rvt-abi.h
  HDRINST usr/include/rdma/bnxt_re-abi.h
  HDRINST usr/include/rdma/cxgb3-abi.h
  HDRINST usr/include/misc/ocxl.h
  HDRINST usr/include/misc/habanalabs.h
  HDRINST usr/include/misc/cxl.h
  HDRINST usr/include/misc/xilinx_sdfec.h
  HDRINST usr/include/misc/fastrpc.h
  HDRINST usr/include/linux/v4l2-subdev.h
  HDRINST usr/include/linux/in.h
  HDRINST usr/include/linux/hash_info.h
  HDRINST usr/include/linux/input-event-codes.h
  HDRINST usr/include/linux/timex.h
  HDRINST usr/include/linux/virtio_iommu.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_mark_t.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_nflog.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_nat.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_ip6.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_log.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_pkttype.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_limit.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_arpreply.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_among.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_802_3.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_redirect.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_mark_m.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_ip.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_arp.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_vlan.h
  HDRINST usr/include/linux/netfilter_bridge/ebt_stp.h
  HDRINST usr/include/linux/netfilter_bridge/ebtables.h
  HDRINST usr/include/linux/ptrace.h
  HDRINST usr/include/linux/tipc_sockets_diag.h
  HDRINST usr/include/linux/quota.h
  HDRINST usr/include/linux/errno.h
  HDRINST usr/include/linux/netlink_diag.h
  HDRINST usr/include/linux/atmlec.h
  HDRINST usr/include/linux/netfilter_ipv4/ipt_LOG.h
  HDRINST usr/include/linux/netfilter_ipv4/ipt_CLUSTERIP.h
  HDRINST usr/include/linux/netfilter_ipv4/ip_tables.h
  HDRINST usr/include/linux/netfilter_ipv4/ipt_ah.h
  HDRINST usr/include/linux/netfilter_ipv4/ipt_REJECT.h
  HDRINST usr/include/linux/netfilter_ipv4/ipt_ttl.h
  HDRINST usr/include/linux/netfilter_ipv4/ipt_ecn.h
  HDRINST usr/include/linux/netfilter_ipv4/ipt_ECN.h
  HDRINST usr/include/linux/netfilter_ipv4/ipt_TTL.h
  HDRINST usr/include/linux/nfc.h
  HDRINST usr/include/linux/fd.h
  HDRINST usr/include/linux/atmdev.h
  HDRINST usr/include/linux/if_arcnet.h
  HDRINST usr/include/linux/nvram.h
  HDRINST usr/include/linux/nfsacl.h
  HDRINST usr/include/linux/virtio_crypto.h
  HDRINST usr/include/linux/elfcore.h
  HDRINST usr/include/linux/ip.h
  HDRINST usr/include/linux/reboot.h
  HDRINST usr/include/linux/dvb/frontend.h
  HDRINST usr/include/linux/dvb/net.h
  HDRINST usr/include/linux/dvb/osd.h
  HDRINST usr/include/linux/dvb/video.h
  HDRINST usr/include/linux/dvb/audio.h
  HDRINST usr/include/linux/dvb/ca.h
  HDRINST usr/include/linux/dvb/dmx.h
  HDRINST usr/include/linux/dvb/version.h
  HDRINST usr/include/linux/atalk.h
  HDRINST usr/include/linux/if.h
  HDRINST usr/include/linux/virtio_9p.h
  HDRINST usr/include/linux/patchkey.h
  HDRINST usr/include/linux/uinput.h
  HDRINST usr/include/linux/sonypi.h
  HDRINST usr/include/linux/blkpg.h
  HDRINST usr/include/linux/mtio.h
  HDRINST usr/include/linux/zorro_ids.h
  HDRINST usr/include/linux/atmclip.h
  HDRINST usr/include/linux/auto_fs.h
  HDRINST usr/include/linux/ipmi_bmc.h
  HDRINST usr/include/linux/tipc.h
  HDRINST usr/include/linux/netlink.h
  HDRINST usr/include/linux/atm_zatm.h
  HDRINST usr/include/linux/nubus.h
  HDRINST usr/include/linux/am437x-vpfe.h
  HDRINST usr/include/linux/coff.h
  HDRINST usr/include/linux/can/netlink.h
  HDRINST usr/include/linux/can/error.h
  HDRINST usr/include/linux/can/raw.h
  HDRINST usr/include/linux/can/vxcan.h
  HDRINST usr/include/linux/can/bcm.h
  HDRINST usr/include/linux/can/gw.h
  HDRINST usr/include/linux/can/j1939.h
  HDRINST usr/include/linux/atmsvc.h
  HDRINST usr/include/linux/usbip.h
  HDRINST usr/include/linux/erspan.h
  HDRINST usr/include/linux/nbd-netlink.h
  HDRINST usr/include/linux/tipc_netlink.h
  HDRINST usr/include/linux/signal.h
  HDRINST usr/include/linux/hsr_netlink.h
  HDRINST usr/include/linux/netfilter_ipv6.h
  HDRINST usr/include/linux/virtio_ids.h
  HDRINST usr/include/linux/if_ltalk.h
  HDRINST usr/include/linux/pmu.h
  HDRINST usr/include/linux/in6.h
  HDRINST usr/include/linux/utime.h
  HDRINST usr/include/linux/kdev_t.h
  HDRINST usr/include/linux/kd.h
  HDRINST usr/include/linux/atmbr2684.h
  HDRINST usr/include/linux/batadv_packet.h
  HDRINST usr/include/linux/if_addr.h
  HDRINST usr/include/linux/atmapi.h
  HDRINST usr/include/linux/ppp-comp.h
  HDRINST usr/include/linux/kvm_para.h
  HDRINST usr/include/linux/if_xdp.h
  HDRINST usr/include/linux/net.h
  HDRINST usr/include/linux/io_uring.h
  HDRINST usr/include/linux/sonet.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_opts.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_rt.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_srh.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_LOG.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_REJECT.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_frag.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_ah.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6_tables.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_ipv6header.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_hl.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_mh.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_NPT.h
  HDRINST usr/include/linux/netfilter_ipv6/ip6t_HL.h
  HDRINST usr/include/linux/i2o-dev.h
  HDRINST usr/include/linux/signalfd.h
  HDRINST usr/include/linux/ethtool.h
  HDRINST usr/include/linux/ipmi_msgdefs.h
  HDRINST usr/include/linux/udf_fs_i.h
  HDRINST usr/include/linux/connector.h
  HDRINST usr/include/linux/veth.h
  HDRINST usr/include/linux/param.h
  HDRINST usr/include/linux/smc.h
  HDRINST usr/include/linux/rtc.h
  HDRINST usr/include/linux/mei.h
  HDRINST usr/include/linux/if_fddi.h
  HDRINST usr/include/linux/cec.h
  HDRINST usr/include/linux/icmpv6.h
  HDRINST usr/include/linux/route.h
  HDRINST usr/include/linux/igmp.h
  HDRINST usr/include/linux/cciss_ioctl.h
  HDRINST usr/include/linux/blktrace_api.h
  HDRINST usr/include/linux/icmp.h
  HDRINST usr/include/linux/sock_diag.h
  HDRINST usr/include/linux/tc_act/tc_tunnel_key.h
  HDRINST usr/include/linux/tc_act/tc_mirred.h
  HDRINST usr/include/linux/tc_act/tc_connmark.h
  HDRINST usr/include/linux/tc_act/tc_mpls.h
  HDRINST usr/include/linux/tc_act/tc_ife.h
  HDRINST usr/include/linux/tc_act/tc_vlan.h
  HDRINST usr/include/linux/tc_act/tc_ipt.h
  HDRINST usr/include/linux/tc_act/tc_ctinfo.h
  HDRINST usr/include/linux/tc_act/tc_defact.h
  HDRINST usr/include/linux/tc_act/tc_skbedit.h
  HDRINST usr/include/linux/tc_act/tc_sample.h
  HDRINST usr/include/linux/tc_act/tc_gact.h
  HDRINST usr/include/linux/tc_act/tc_ct.h
  HDRINST usr/include/linux/tc_act/tc_nat.h
  HDRINST usr/include/linux/tc_act/tc_skbmod.h
  HDRINST usr/include/linux/tc_act/tc_csum.h
  HDRINST usr/include/linux/tc_act/tc_bpf.h
  HDRINST usr/include/linux/tc_act/tc_pedit.h
  HDRINST usr/include/linux/msg.h
  HDRINST usr/include/linux/target_core_user.h
  HDRINST usr/include/linux/string.h
  HDRINST usr/include/linux/fsverity.h
  HDRINST usr/include/linux/ptp_clock.h
  HDRINST usr/include/linux/if_bridge.h
  HDRINST usr/include/linux/irqnr.h
  HDRINST usr/include/linux/module.h
  HDRINST usr/include/linux/atmsap.h
  HDRINST usr/include/linux/if_tunnel.h
  HDRINST usr/include/linux/atmioc.h
  HDRINST usr/include/linux/genwqe/genwqe_card.h
  HDRINST usr/include/linux/rseq.h
  HDRINST usr/include/linux/lwtunnel.h
  HDRINST usr/include/linux/binfmts.h
  HDRINST usr/include/linux/fanotify.h
  HDRINST usr/include/linux/futex.h
  HDRINST usr/include/linux/virtio_input.h
  HDRINST usr/include/linux/rds.h
  HDRINST usr/include/linux/netfilter.h
  HDRINST usr/include/linux/edd.h
  HDRINST usr/include/linux/limits.h
  HDRINST usr/include/linux/atmmpc.h
  HDRINST usr/include/linux/llc.h
  HDRINST usr/include/linux/pr.h
  HDRINST usr/include/linux/input.h
  HDRINST usr/include/linux/omap3isp.h
  HDRINST usr/include/linux/rfkill.h
  HDRINST usr/include/linux/if_vlan.h
  HDRINST usr/include/linux/firewire-constants.h
  HDRINST usr/include/linux/if_ether.h
  HDRINST usr/include/linux/pkt_cls.h
  HDRINST usr/include/linux/fuse.h
  HDRINST usr/include/linux/cciss_defs.h
  HDRINST usr/include/linux/arm_sdei.h
  HDRINST usr/include/linux/bcm933xx_hcs.h
  HDRINST usr/include/linux/netfilter_decnet.h
  HDRINST usr/include/linux/hysdn_if.h
  HDRINST usr/include/linux/packet_diag.h
  HDRINST usr/include/linux/tty_flags.h
  HDRINST usr/include/linux/rpmsg.h
  HDRINST usr/include/linux/auto_dev-ioctl.h
  HDRINST usr/include/linux/atm.h
  HDRINST usr/include/linux/netconf.h
  HDRINST usr/include/linux/inotify.h
  HDRINST usr/include/linux/seg6_iptunnel.h
  HDRINST usr/include/linux/serial_core.h
  HDRINST usr/include/linux/virtio_fs.h
  HDRINST usr/include/linux/reiserfs_xattr.h
  HDRINST usr/include/linux/chio.h
  HDRINST usr/include/linux/parport.h
  HDRINST usr/include/linux/cycx_cfm.h
  HDRINST usr/include/linux/random.h
  HDRINST usr/include/linux/cdrom.h
  HDRINST usr/include/linux/cec-funcs.h
  HDRINST usr/include/linux/fiemap.h
  HDRINST usr/include/linux/adb.h
  HDRINST usr/include/linux/fsl_hypervisor.h
  HDRINST usr/include/linux/dlm_netlink.h
  HDRINST usr/include/linux/if_x25.h
  HDRINST usr/include/linux/cuda.h
  HDRINST usr/include/linux/rio_cm_cdev.h
  HDRINST usr/include/linux/smc_diag.h
  HDRINST usr/include/linux/romfs_fs.h
  HDRINST usr/include/linux/bcache.h
  HDRINST usr/include/linux/cgroupstats.h
  HDRINST usr/include/linux/tipc_config.h
  HDRINST usr/include/linux/mpls.h
  HDRINST usr/include/linux/elf.h
  HDRINST usr/include/linux/in_route.h
  HDRINST usr/include/linux/bfs_fs.h
  HDRINST usr/include/linux/virtio_net.h
  HDRINST usr/include/linux/sched/types.h
  HDRINST usr/include/linux/if_ppp.h
  HDRINST usr/include/linux/sctp.h
  HDRINST usr/include/linux/fsmap.h
  HDRINST usr/include/linux/gtp.h
  HDRINST usr/include/linux/nilfs2_ondisk.h
  HDRINST usr/include/linux/v4l2-mediabus.h
  HDRINST usr/include/linux/bpfilter.h
  HDRINST usr/include/linux/phonet.h
  HDRINST usr/include/linux/bsg.h
  HDRINST usr/include/linux/scc.h
  HDRINST usr/include/linux/sched.h
  HDRINST usr/include/linux/serio.h
  HDRINST usr/include/linux/kfd_ioctl.h
  HDRINST usr/include/linux/netfilter_arp.h
  HDRINST usr/include/linux/uvcvideo.h
  HDRINST usr/include/linux/resource.h
  HDRINST usr/include/linux/uio.h
  HDRINST usr/include/linux/dccp.h
  HDRINST usr/include/linux/i8k.h
  HDRINST usr/include/linux/hdlcdrv.h
  HDRINST usr/include/linux/virtio_balloon.h
  HDRINST usr/include/linux/hiddev.h
  HDRINST usr/include/linux/v4l2-common.h
  HDRINST usr/include/linux/fs.h
  HDRINST usr/include/linux/nsfs.h
  HDRINST usr/include/linux/nfs2.h
  HDRINST usr/include/linux/netrom.h
  HDRINST usr/include/linux/ultrasound.h
  HDRINST usr/include/linux/dlm.h
  HDRINST usr/include/linux/gen_stats.h
  HDRINST usr/include/linux/isst_if.h
  HDRINST usr/include/linux/if_frad.h
  HDRINST usr/include/linux/coda.h
  HDRINST usr/include/linux/atm_he.h
  HDRINST usr/include/linux/l2tp.h
  HDRINST usr/include/linux/if_slip.h
  HDRINST usr/include/linux/const.h
  HDRINST usr/include/linux/vm_sockets.h
  HDRINST usr/include/linux/psample.h
  HDRINST usr/include/linux/n_r3964.h
  HDRINST usr/include/linux/atm_eni.h
  HDRINST usr/include/linux/usb/charger.h
  HDRINST usr/include/linux/usb/video.h
  HDRINST usr/include/linux/usb/g_uvc.h
  HDRINST usr/include/linux/usb/tmc.h
  HDRINST usr/include/linux/usb/functionfs.h
  HDRINST usr/include/linux/usb/audio.h
  HDRINST usr/include/linux/usb/midi.h
  HDRINST usr/include/linux/usb/ch9.h
  HDRINST usr/include/linux/usb/cdc.h
  HDRINST usr/include/linux/usb/g_printer.h
  HDRINST usr/include/linux/usb/cdc-wdm.h
  HDRINST usr/include/linux/usb/gadgetfs.h
  HDRINST usr/include/linux/usb/ch11.h
  HDRINST usr/include/linux/if_bonding.h
  HDRINST usr/include/linux/virtio_gpu.h
  HDRINST usr/include/linux/seg6.h
  HDRINST usr/include/linux/joystick.h
  HDRINST usr/include/linux/if_team.h
  HDRINST usr/include/linux/if_tun.h
  HDRINST usr/include/linux/cn_proc.h
  HDRINST usr/include/linux/wimax/i2400m.h
  HDRINST usr/include/linux/kernelcapi.h
  HDRINST usr/include/linux/sed-opal.h
  HDRINST usr/include/linux/shm.h
  HDRINST usr/include/linux/virtio_types.h
  HDRINST usr/include/linux/if_addrlabel.h
  HDRINST usr/include/linux/isdn/capicmd.h
  HDRINST usr/include/linux/dlm_plock.h
  HDRINST usr/include/linux/hid.h
  HDRINST usr/include/linux/aio_abi.h
  HDRINST usr/include/linux/smiapp.h
  HDRINST usr/include/linux/pps.h
  HDRINST usr/include/linux/netfilter_ipv4.h
  HDRINST usr/include/linux/byteorder/little_endian.h
  HDRINST usr/include/linux/byteorder/big_endian.h
  HDRINST usr/include/linux/netfilter/xt_tcpmss.h
  HDRINST usr/include/linux/netfilter/xt_pkttype.h
  HDRINST usr/include/linux/netfilter/xt_RATEEST.h
  HDRINST usr/include/linux/netfilter/xt_state.h
  HDRINST usr/include/linux/netfilter/xt_esp.h
  HDRINST usr/include/linux/netfilter/x_tables.h
  HDRINST usr/include/linux/netfilter/xt_tcpudp.h
  HDRINST usr/include/linux/netfilter/xt_CONNSECMARK.h
  HDRINST usr/include/linux/netfilter/xt_recent.h
  HDRINST usr/include/linux/netfilter/xt_hashlimit.h
  HDRINST usr/include/linux/netfilter/xt_comment.h
  HDRINST usr/include/linux/netfilter/xt_cgroup.h
  HDRINST usr/include/linux/netfilter/xt_TCPMSS.h
  HDRINST usr/include/linux/netfilter/nfnetlink.h
  HDRINST usr/include/linux/netfilter/xt_socket.h
  HDRINST usr/include/linux/netfilter/xt_owner.h
  HDRINST usr/include/linux/netfilter/nfnetlink_acct.h
  HDRINST usr/include/linux/netfilter/xt_CHECKSUM.h
  HDRINST usr/include/linux/netfilter/xt_conntrack.h
  HDRINST usr/include/linux/netfilter/xt_statistic.h
  HDRINST usr/include/linux/netfilter/xt_l2tp.h
  HDRINST usr/include/linux/netfilter/xt_time.h
  HDRINST usr/include/linux/netfilter/xt_AUDIT.h
  HDRINST usr/include/linux/netfilter/xt_rpfilter.h
  HDRINST usr/include/linux/netfilter/nf_conntrack_ftp.h
  HDRINST usr/include/linux/netfilter/nf_conntrack_tcp.h
  HDRINST usr/include/linux/netfilter/xt_mac.h
  HDRINST usr/include/linux/netfilter/xt_physdev.h
  HDRINST usr/include/linux/netfilter/xt_string.h
  HDRINST usr/include/linux/netfilter/xt_devgroup.h
  HDRINST usr/include/linux/netfilter/xt_IDLETIMER.h
  HDRINST usr/include/linux/netfilter/xt_TCPOPTSTRIP.h
  HDRINST usr/include/linux/netfilter/nf_conntrack_common.h
  HDRINST usr/include/linux/netfilter/xt_dscp.h
  HDRINST usr/include/linux/netfilter/xt_ipcomp.h
  HDRINST usr/include/linux/netfilter/xt_length.h
  HDRINST usr/include/linux/netfilter/xt_DSCP.h
  HDRINST usr/include/linux/netfilter/xt_osf.h
  HDRINST usr/include/linux/netfilter/xt_LED.h
  HDRINST usr/include/linux/netfilter/xt_cluster.h
  HDRINST usr/include/linux/netfilter/nfnetlink_log.h
  HDRINST usr/include/linux/netfilter/nf_conntrack_tuple_common.h
  HDRINST usr/include/linux/netfilter/nfnetlink_osf.h
  HDRINST usr/include/linux/netfilter/xt_CONNMARK.h
  HDRINST usr/include/linux/netfilter/xt_SECMARK.h
  HDRINST usr/include/linux/netfilter/xt_connbytes.h
  HDRINST usr/include/linux/netfilter/xt_sctp.h
  HDRINST usr/include/linux/netfilter/nf_tables_compat.h
  HDRINST usr/include/linux/netfilter/nf_conntrack_sctp.h
  HDRINST usr/include/linux/netfilter/xt_CLASSIFY.h
  HDRINST usr/include/linux/netfilter/xt_realm.h
  HDRINST usr/include/linux/netfilter/xt_limit.h
  HDRINST usr/include/linux/netfilter/xt_mark.h
  HDRINST usr/include/linux/netfilter/xt_bpf.h
  HDRINST usr/include/linux/netfilter/xt_quota.h
  HDRINST usr/include/linux/netfilter/xt_ipvs.h
  HDRINST usr/include/linux/netfilter/xt_rateest.h
  HDRINST usr/include/linux/netfilter/nfnetlink_cttimeout.h
  HDRINST usr/include/linux/netfilter/xt_TPROXY.h
  HDRINST usr/include/linux/netfilter/nfnetlink_cthelper.h
  HDRINST usr/include/linux/netfilter/xt_LOG.h
  HDRINST usr/include/linux/netfilter/xt_NFLOG.h
  HDRINST usr/include/linux/netfilter/xt_nfacct.h
  HDRINST usr/include/linux/netfilter/xt_MARK.h
  HDRINST usr/include/linux/netfilter/nf_synproxy.h
  HDRINST usr/include/linux/netfilter/nf_nat.h
  HDRINST usr/include/linux/netfilter/xt_helper.h
  HDRINST usr/include/linux/netfilter/xt_CT.h
  HDRINST usr/include/linux/netfilter/xt_TEE.h
  HDRINST usr/include/linux/netfilter/xt_HMARK.h
  HDRINST usr/include/linux/netfilter/xt_addrtype.h
  HDRINST usr/include/linux/netfilter/xt_SYNPROXY.h
  HDRINST usr/include/linux/netfilter/ipset/ip_set_list.h
  HDRINST usr/include/linux/netfilter/ipset/ip_set_bitmap.h
  HDRINST usr/include/linux/netfilter/ipset/ip_set.h
  HDRINST usr/include/linux/netfilter/ipset/ip_set_hash.h
  HDRINST usr/include/linux/netfilter/nf_tables.h
  HDRINST usr/include/linux/netfilter/xt_cpu.h
  HDRINST usr/include/linux/netfilter/xt_iprange.h
  HDRINST usr/include/linux/netfilter/nfnetlink_queue.h
  HDRINST usr/include/linux/netfilter/xt_policy.h
  HDRINST usr/include/linux/netfilter/xt_dccp.h
  HDRINST usr/include/linux/netfilter/xt_connlimit.h
  HDRINST usr/include/linux/netfilter/xt_u32.h
  HDRINST usr/include/linux/netfilter/nfnetlink_conntrack.h
  HDRINST usr/include/linux/netfilter/xt_multiport.h
  HDRINST usr/include/linux/netfilter/xt_set.h
  HDRINST usr/include/linux/netfilter/nfnetlink_compat.h
  HDRINST usr/include/linux/netfilter/xt_NFQUEUE.h
  HDRINST usr/include/linux/netfilter/xt_ecn.h
  HDRINST usr/include/linux/netfilter/nf_log.h
  HDRINST usr/include/linux/netfilter/xt_connmark.h
  HDRINST usr/include/linux/netfilter/xt_connlabel.h
  HDRINST usr/include/linux/android/binderfs.h
  HDRINST usr/include/linux/android/binder.h
  HDRINST usr/include/linux/stat.h
  HDRINST usr/include/linux/securebits.h
  HDRINST usr/include/linux/map_to_7segment.h
  HDRINST usr/include/linux/coresight-stm.h
  HDRINST usr/include/linux/gpio.h
  HDRINST usr/include/linux/capability.h
  HDRINST usr/include/linux/auxvec.h
  HDRINST usr/include/linux/fb.h
  HDRINST usr/include/linux/hyperv.h
  HDRINST usr/include/linux/dcbnl.h
  HDRINST usr/include/linux/taskstats.h
  HDRINST usr/include/linux/ip_vs.h
  HDRINST usr/include/linux/reiserfs_fs.h
  HDRINST usr/include/linux/virtio_console.h
  HDRINST usr/include/linux/qnxtypes.h
  HDRINST usr/include/linux/kvm.h
  HDRINST usr/include/linux/elf-fdpic.h
  HDRINST usr/include/linux/mpls_iptunnel.h
  HDRINST usr/include/linux/radeonfb.h
  HDRINST usr/include/linux/auto_fs4.h
  HDRINST usr/include/linux/poll.h
  HDRINST usr/include/linux/soundcard.h
  HDRINST usr/include/linux/rose.h
  HDRINST usr/include/linux/personality.h
  HDRINST usr/include/linux/uleds.h
  HDRINST usr/include/linux/fdreg.h
  HDRINST usr/include/linux/media.h
  HDRINST usr/include/linux/if_pppox.h
  HDRINST usr/include/linux/fscrypt.h
  HDRINST usr/include/linux/screen_info.h
  HDRINST usr/include/linux/nbd.h
  HDRINST usr/include/linux/videodev2.h
  HDRINST usr/include/linux/sdla.h
  HDRINST usr/include/linux/hw_breakpoint.h
  HDRINST usr/include/linux/tee.h
  HDRINST usr/include/linux/qnx4_fs.h
  HDRINST usr/include/linux/atmppp.h
  HDRINST usr/include/linux/virtio_rng.h
  HDRINST usr/include/linux/udmabuf.h
  HDRINST usr/include/linux/cifs/cifs_mount.h
  HDRINST usr/include/linux/ppp-ioctl.h
  HDRINST usr/include/linux/arcfb.h
  HDRINST usr/include/linux/eventpoll.h
  HDRINST usr/include/linux/ipsec.h
  HDRINST usr/include/linux/atm_idt77105.h
  HDRINST usr/include/linux/netfilter_arp/arpt_mangle.h
  HDRINST usr/include/linux/netfilter_arp/arp_tables.h
  HDRINST usr/include/linux/hsi/hsi_char.h
  HDRINST usr/include/linux/hsi/cs-protocol.h
  HDRINST usr/include/linux/vhost_types.h
  HDRINST usr/include/linux/ipx.h
  HDRINST usr/include/linux/if_fc.h
  HDRINST usr/include/linux/stddef.h
  HDRINST usr/include/linux/adfs_fs.h
  HDRINST usr/include/linux/atmarp.h
  HDRINST usr/include/linux/iso_fs.h
  HDRINST usr/include/linux/pfkeyv2.h
  HDRINST usr/include/linux/fadvise.h
  HDRINST usr/include/linux/cyclades.h
  HDRINST usr/include/linux/ivtv.h
  HDRINST usr/include/linux/wmi.h
  HDRINST usr/include/linux/socket.h
  HDRINST usr/include/linux/raw.h
  HDRINST usr/include/linux/qrtr.h
  HDRINST usr/include/linux/gigaset_dev.h
  HDRINST usr/include/linux/sound.h
  HDRINST usr/include/linux/ndctl.h
  HDRINST usr/include/linux/major.h
  HDRINST usr/include/linux/aspeed-lpc-ctrl.h
  HDRINST usr/include/linux/vsockmon.h
  HDRINST usr/include/linux/toshiba.h
  HDRINST usr/include/linux/gfs2_ondisk.h
  HDRINST usr/include/linux/apm_bios.h
  HDRINST usr/include/linux/matroxfb.h
  HDRINST usr/include/linux/vt.h
  HDRINST usr/include/linux/tiocl.h
  HDRINST usr/include/linux/vfio_ccw.h
  HDRINST usr/include/linux/fsi.h
  HDRINST usr/include/linux/devlink.h
  HDRINST usr/include/linux/nexthop.h
  HDRINST usr/include/linux/virtio_scsi.h
  HDRINST usr/include/linux/if_infiniband.h
  HDRINST usr/include/linux/oom.h
  HDRINST usr/include/linux/nfs4.h
  HDRINST usr/include/linux/mroute6.h
  HDRINST usr/include/linux/ppdev.h
  HDRINST usr/include/linux/seg6_hmac.h
  HDRINST usr/include/linux/ife.h
  HDRINST usr/include/linux/netfilter_bridge.h
  HDRINST usr/include/linux/hpet.h
  HDRINST usr/include/linux/ioctl.h
  HDRINST usr/include/linux/iio/events.h
  HDRINST usr/include/linux/iio/types.h
  HDRINST usr/include/linux/filter.h
  HDRINST usr/include/linux/seg6_genl.h
  HDRINST usr/include/linux/if_alg.h
  HDRINST usr/include/linux/kexec.h
  HDRINST usr/include/linux/ipmi.h
  HDRINST usr/include/linux/suspend_ioctls.h
  HDRINST usr/include/linux/fcntl.h
  HDRINST usr/include/linux/uuid.h
  HDRINST usr/include/linux/fib_rules.h
  HDRINST usr/include/linux/netdevice.h
  HDRINST usr/include/linux/kcov.h
  HDRINST usr/include/linux/net_namespace.h
  HDRINST usr/include/linux/mount.h
  HDRINST usr/include/linux/caif/if_caif.h
  HDRINST usr/include/linux/caif/caif_socket.h
  HDRINST usr/include/linux/timerfd.h
  HDRINST usr/include/linux/bpf.h
  HDRINST usr/include/linux/rio_mport_cdev.h
  HDRINST usr/include/linux/virtio_pci.h
  HDRINST usr/include/linux/tcp_metrics.h
  HDRINST usr/include/linux/if_eql.h
  HDRINST usr/include/linux/ppp_defs.h
  HDRINST usr/include/linux/posix_types.h
  HDRINST usr/include/linux/max2175.h
  HDRINST usr/include/linux/pcitest.h
  HDRINST usr/include/linux/prctl.h
  HDRINST usr/include/linux/atm_nicstar.h
  HDRINST usr/include/linux/virtio_blk.h
  HDRINST usr/include/linux/nfs_mount.h
  HDRINST usr/include/linux/fou.h
  HDRINST usr/include/linux/if_macsec.h
  HDRINST usr/include/linux/ipc.h
  HDRINST usr/include/linux/userio.h
  HDRINST usr/include/linux/synclink.h
  HDRINST usr/include/linux/mmtimer.h
  HDRINST usr/include/linux/tcp.h
  HDRINST usr/include/linux/v4l2-dv-timings.h
  HDRINST usr/include/linux/hdreg.h
  HDRINST usr/include/linux/if_phonet.h
  HDRINST usr/include/linux/time_types.h
  HDRINST usr/include/linux/wireless.h
  HDRINST usr/include/linux/watchdog.h
  HDRINST usr/include/linux/gsmmux.h
  HDRINST usr/include/linux/if_link.h
  HDRINST usr/include/linux/affs_hardblocks.h
  HDRINST usr/include/linux/mic_ioctl.h
  HDRINST usr/include/linux/neighbour.h
  HDRINST usr/include/linux/errqueue.h
  HDRINST usr/include/linux/mii.h
  HDRINST usr/include/linux/vm_sockets_diag.h
  HDRINST usr/include/linux/if_arp.h
  HDRINST usr/include/linux/termios.h
  HDRINST usr/include/linux/wait.h
  HDRINST usr/include/linux/xfrm.h
  HDRINST usr/include/linux/mroute.h
  HDRINST usr/include/linux/agpgart.h
  HDRINST usr/include/linux/lirc.h
  HDRINST usr/include/linux/kernel-page-flags.h
  HDRINST usr/include/linux/kcmp.h
  HDRINST usr/include/linux/nfs_idmap.h
  HDRINST usr/include/linux/nvme_ioctl.h
  HDRINST usr/include/linux/virtio_vsock.h
  HDRINST usr/include/linux/perf_event.h
  HDRINST usr/include/linux/nfs.h
  HDRINST usr/include/linux/membarrier.h
  HDRINST usr/include/linux/vbox_err.h
  HDRINST usr/include/linux/firewire-cdev.h
  HDRINST usr/include/linux/snmp.h
  HDRINST usr/include/linux/mempolicy.h
  HDRINST usr/include/linux/if_pppol2tp.h
  HDRINST usr/include/linux/media-bus-format.h
  HDRINST usr/include/linux/ncsi.h
  HDRINST usr/include/linux/vmcore.h
  HDRINST usr/include/linux/dn.h
  HDRINST usr/include/linux/userfaultfd.h
  HDRINST usr/include/linux/un.h
  HDRINST usr/include/linux/ip6_tunnel.h
  HDRINST usr/include/linux/phantom.h
  HDRINST usr/include/linux/stm.h
  HDRINST usr/include/linux/switchtec_ioctl.h
  HDRINST usr/include/linux/virtio_ring.h
  HDRINST usr/include/linux/tls.h
  HDRINST usr/include/linux/pci_regs.h
  HDRINST usr/include/linux/atm_tcp.h
  HDRINST usr/include/linux/mdio.h
  HDRINST usr/include/linux/capi.h
  HDRINST usr/include/linux/btrfs_tree.h
  HDRINST usr/include/linux/i2c-dev.h
  HDRINST usr/include/linux/serial_reg.h
  HDRINST usr/include/linux/nfsd/debug.h
  HDRINST usr/include/linux/nfsd/export.h
  HDRINST usr/include/linux/nfsd/cld.h
  HDRINST usr/include/linux/nfsd/stats.h
  HDRINST usr/include/linux/nfsd/nfsfh.h
  HDRINST usr/include/linux/spi/spidev.h
  HDRINST usr/include/linux/sunrpc/debug.h
  HDRINST usr/include/linux/dqblk_xfs.h
  HDRINST usr/include/linux/scif_ioctl.h
  HDRINST usr/include/linux/nilfs2_api.h
  HDRINST usr/include/linux/mic_common.h
  HDRINST usr/include/linux/blkzoned.h
  HDRINST usr/include/linux/aspeed-p2a-ctrl.h
  HDRINST usr/include/linux/psci.h
  HDRINST usr/include/linux/inet_diag.h
  HDRINST usr/include/linux/sysctl.h
  HDRINST usr/include/linux/ila.h
  HDRINST usr/include/linux/dma-buf.h
  HDRINST usr/include/linux/thermal.h
  HDRINST usr/include/linux/loop.h
  HDRINST usr/include/linux/qemu_fw_cfg.h
  HDRINST usr/include/linux/swab.h
  HDRINST usr/include/linux/baycom.h
  HDRINST usr/include/linux/jffs2.h
  HDRINST usr/include/linux/xdp_diag.h
  HDRINST usr/include/linux/wimax.h
  HDRINST usr/include/linux/net_dropmon.h
  HDRINST usr/include/linux/libc-compat.h
  HDRINST usr/include/linux/serial.h
  HDRINST usr/include/linux/nl80211.h
  HDRINST usr/include/linux/net_tstamp.h
  HDRINST usr/include/linux/usbdevice_fs.h
  HDRINST usr/include/linux/gameport.h
  HDRINST usr/include/linux/minix_fs.h
  HDRINST usr/include/linux/udp.h
  HDRINST usr/include/linux/openvswitch.h
  HDRINST usr/include/linux/vboxguest.h
  HDRINST usr/include/linux/nfs4_mount.h
  HDRINST usr/include/linux/omapfb.h
  HDRINST usr/include/linux/posix_acl_xattr.h
  HDRINST usr/include/linux/seccomp.h
  HDRINST usr/include/linux/ipv6.h
  HDRINST usr/include/linux/magic.h
  HDRINST usr/include/linux/iommu.h
  HDRINST usr/include/linux/dns_resolver.h
  HDRINST usr/include/linux/mman.h
  HDRINST usr/include/linux/hidraw.h
  HDRINST usr/include/linux/xattr.h
  HDRINST usr/include/linux/audit.h
  HDRINST usr/include/linux/batman_adv.h
  HDRINST usr/include/linux/sync_file.h
  HDRINST usr/include/linux/hdlc/ioctl.h
  HDRINST usr/include/linux/dm-ioctl.h
  HDRINST usr/include/linux/sem.h
  HDRINST usr/include/linux/ivtvfb.h
  HDRINST usr/include/linux/efs_fs_sb.h
  HDRINST usr/include/linux/unistd.h
  HDRINST usr/include/linux/ax25.h
  HDRINST usr/include/linux/elf-em.h
  HDRINST usr/include/linux/lp.h
  HDRINST usr/include/linux/cramfs_fs.h
  HDRINST usr/include/linux/if_cablemodem.h
  HDRINST usr/include/linux/pkt_sched.h
  HDRINST usr/include/linux/virtio_pmem.h
  HDRINST usr/include/linux/posix_acl.h
  HDRINST usr/include/linux/bpqether.h
  HDRINST usr/include/linux/if_packet.h
  HDRINST usr/include/linux/kernel.h
  HDRINST usr/include/linux/vfio.h
  HDRINST usr/include/linux/kcm.h
  HDRINST usr/include/linux/times.h
  HDRINST usr/include/linux/psp-sev.h
  HDRINST usr/include/linux/vbox_vmmdev_types.h
  HDRINST usr/include/linux/selinux_netlink.h
  HDRINST usr/include/linux/if_hippi.h
  HDRINST usr/include/linux/b1lli.h
  HDRINST usr/include/linux/virtio_config.h
  HDRINST usr/include/linux/fpga-dfl.h
  HDRINST usr/include/linux/bt-bmc.h
  HDRINST usr/include/linux/sysinfo.h
  HDRINST usr/include/linux/tc_ematch/tc_em_ipt.h
  HDRINST usr/include/linux/tc_ematch/tc_em_cmp.h
  HDRINST usr/include/linux/tc_ematch/tc_em_meta.h
  HDRINST usr/include/linux/tc_ematch/tc_em_nbyte.h
  HDRINST usr/include/linux/tc_ematch/tc_em_text.h
  HDRINST usr/include/linux/cm4000_cs.h
  HDRINST usr/include/linux/hdlc.h
  HDRINST usr/include/linux/virtio_mmio.h
  HDRINST usr/include/linux/uhid.h
  HDRINST usr/include/linux/sockios.h
  HDRINST usr/include/linux/i2c.h
  HDRINST usr/include/linux/btf.h
  HDRINST usr/include/linux/memfd.h
  HDRINST usr/include/linux/dlm_device.h
  HDRINST usr/include/linux/dm-log-userspace.h
  HDRINST usr/include/linux/if_plip.h
  HDRINST usr/include/linux/falloc.h
  HDRINST usr/include/linux/pci.h
  HDRINST usr/include/linux/dlmconstants.h
  HDRINST usr/include/linux/tty.h
  HDRINST usr/include/linux/time.h
  HDRINST usr/include/linux/keyboard.h
  HDRINST usr/include/linux/unix_diag.h
  HDRINST usr/include/linux/ipv6_route.h
  HDRINST usr/include/linux/raid/md_p.h
  HDRINST usr/include/linux/raid/md_u.h
  HDRINST usr/include/linux/utsname.h
  HDRINST usr/include/linux/rxrpc.h
  HDRINST usr/include/linux/vhost.h
  HDRINST usr/include/linux/mmc/ioctl.h
  HDRINST usr/include/linux/msdos_fs.h
  HDRINST usr/include/linux/mqueue.h
  HDRINST usr/include/linux/acct.h
  HDRINST usr/include/linux/v4l2-controls.h
  HDRINST usr/include/linux/btrfs.h
  HDRINST usr/include/linux/types.h
  HDRINST usr/include/linux/keyctl.h
  HDRINST usr/include/linux/pg.h
  HDRINST usr/include/linux/x25.h
  HDRINST usr/include/linux/vtpm_proxy.h
  HDRINST usr/include/linux/nfs3.h
  HDRINST usr/include/linux/nfs_fs.h
  HDRINST usr/include/linux/genetlink.h
  HDRINST usr/include/linux/pktcdvd.h
  HDRINST usr/include/linux/can.h
  HDRINST usr/include/linux/bpf_common.h
  HDRINST usr/include/linux/lightnvm.h
  HDRINST usr/include/linux/cryptouser.h
  HDRINST usr/include/linux/seg6_local.h
  HDRINST usr/include/linux/rtnetlink.h
  HDRINST usr/include/linux/meye.h
  HDRINST usr/include/linux/bpf_perf_event.h
  HDRINST usr/include/linux/zorro.h
  HDRINST usr/include/linux/xilinx-v4l2-controls.h
  HDRINST usr/include/sound/emu10k1.h
  HDRINST usr/include/sound/sb16_csp.h
  HDRINST usr/include/sound/skl-tplg-interface.h
  HDRINST usr/include/sound/asound.h
  HDRINST usr/include/sound/usb_stream.h
  HDRINST usr/include/sound/compress_offload.h
  HDRINST usr/include/sound/asoc.h
  HDRINST usr/include/sound/compress_params.h
  HDRINST usr/include/sound/asequencer.h
  HDRINST usr/include/sound/snd_sst_tokens.h
  HDRINST usr/include/sound/firewire.h
  HDRINST usr/include/sound/sof/header.h
  HDRINST usr/include/sound/sof/fw.h
  HDRINST usr/include/sound/sof/abi.h
  HDRINST usr/include/sound/sof/tokens.h
  HDRINST usr/include/sound/tlv.h
  HDRINST usr/include/sound/hdsp.h
  HDRINST usr/include/sound/sfnt_info.h
  HDRINST usr/include/sound/hdspm.h
  HDRINST usr/include/sound/asound_fm.h
  HDRINST usr/include/scsi/cxlflash_ioctl.h
  HDRINST usr/include/scsi/scsi_netlink.h
  HDRINST usr/include/scsi/fc/fc_els.h
  HDRINST usr/include/scsi/fc/fc_gs.h
  HDRINST usr/include/scsi/fc/fc_ns.h
  HDRINST usr/include/scsi/fc/fc_fs.h
  HDRINST usr/include/scsi/scsi_netlink_fc.h
  HDRINST usr/include/scsi/scsi_bsg_ufs.h
  HDRINST usr/include/scsi/scsi_bsg_fc.h
  HDRINST usr/include/linux/version.h
  HDRINST usr/include/asm/ioctls.h
  HDRINST usr/include/asm/ptrace.h
  HDRINST usr/include/asm/signal.h
  HDRINST usr/include/asm/sigcontext.h
  HDRINST usr/include/asm/hwcap.h
  HDRINST usr/include/asm/stat.h
  HDRINST usr/include/asm/auxvec.h
  HDRINST usr/include/asm/kvm.h
  HDRINST usr/include/asm/fcntl.h
  HDRINST usr/include/asm/posix_types.h
  HDRINST usr/include/asm/perf_regs.h
  HDRINST usr/include/asm/statfs.h
  HDRINST usr/include/asm/swab.h
  HDRINST usr/include/asm/mman.h
  HDRINST usr/include/asm/unistd.h
  HDRINST usr/include/asm/byteorder.h
  HDRINST usr/include/asm/setup.h
  HDRINST usr/include/asm/types.h
  HDRINST usr/include/asm/errno.h
  HDRINST usr/include/asm/kvm_para.h
  HDRINST usr/include/asm/param.h
  HDRINST usr/include/asm/msgbuf.h
  HDRINST usr/include/asm/resource.h
  HDRINST usr/include/asm/unistd-common.h
  HDRINST usr/include/asm/ipcbuf.h
  HDRINST usr/include/asm/poll.h
  HDRINST usr/include/asm/unistd-oabi.h
  HDRINST usr/include/asm/socket.h
  HDRINST usr/include/asm/ioctl.h
  HDRINST usr/include/asm/unistd-eabi.h
  HDRINST usr/include/asm/siginfo.h
  HDRINST usr/include/asm/termios.h
  HDRINST usr/include/asm/shmbuf.h
  HDRINST usr/include/asm/sembuf.h
  HDRINST usr/include/asm/termbits.h
  HDRINST usr/include/asm/sockios.h
  HDRINST usr/include/asm/bitsperlong.h
  HDRINST usr/include/asm/bpf_perf_event.h
  INSTALL /usr/include
/bin/sh: 1: rsync: not found
Makefile:1189: recipe for target 'headers_install' failed
make: *** [headers_install] Error 127

root@changeme:/compile/source/linux-stable# apt install rsync

Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following packages were automatically installed and are no longer required:
  ca-certificates-java default-jre default-jre-headless efibootmgr fonts-crosextra-caladea
  fonts-crosextra-carlito fonts-dejavu fonts-dejavu-extra fonts-liberation2 fonts-linuxlibertine
  fonts-sil-gentium fonts-sil-gentium-basic gstreamer1.0-gtk3 java-common libabw-0.1-1
  libapache-pom-java libatk-wrapper-java libatk-wrapper-java-jni libboost-date-time1.65.1
  libboost-filesystem1.65.1 libboost-iostreams1.65.1 libboost-locale1.65.1 libbsh-java
  libcdr-0.1-1 libclucene-contribs1v5 libclucene-core1v5 libcmis-0.5-5v5 libcolamd2
  libcommons-logging-java libcommons-parent-java libdrm-etnaviv1 libe-book-0.1-1 libel-api-java
  libeot0 libepubgen-0.1-1 libetonyek-0.1-1 libexttextcat-2.0-0 libexttextcat-data
  libfreehand-0.1-1 libfwup1 libgif7 libgpgmepp6 libhsqldb1.8.0-java libjsp-api-java
  liblangtag-common liblangtag1 libllvm8 libmhash2 libmspub-0.1-1 libmwaw-0.3-3 libmythes-1.2-0
  libneon27-gnutls libodfgen-0.1-1 liborcus-0.13-0 libpagemaker-0.0-0 libpq5 libraptor2-0
  librasqal3 librdf0 librevenge-0.0-0 libservlet-api-java libservlet3.1-java libsuitesparseconfig5
  libvisio-0.1-1 libwebsocket-api-java libwpd-0.10-10 libwpg-0.3-3 libwps-0.4-4 libxmlsec1
  libxmlsec1-nss libyajl2 lp-solve openjdk-11-jre openjdk-11-jre-headless uno-libs3 ure
Use 'apt autoremove' to remove them.
The following NEW packages will be installed:
  rsync
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 315 kB of archives.
After this operation, 574 kB of additional disk space will be used.
Get:1 http://ports.ubuntu.com/ubuntu-ports bionic-security/main armhf rsync armhf 3.1.2-2.1ubuntu1.5 [315 kB]
Fetched 315 kB in 0s (881 kB/s)
Selecting previously unselected package rsync.
(Reading database ... 122364 files and directories currently installed.)
Preparing to unpack .../rsync_3.1.2-2.1ubuntu1.5_armhf.deb ...
Unpacking rsync (3.1.2-2.1ubuntu1.5) ...
Setting up rsync (3.1.2-2.1ubuntu1.5) ...
Created symlink /etc/systemd/system/multi-user.target.wants/rsync.service → /lib/systemd/system/rsync.service.
Processing triggers for man-db (2.8.3-2ubuntu0.1) ...
Processing triggers for systemd (237-3ubuntu10.53) ...

root@changeme:/compile/source/linux-stable# make headers_install INSTALL_HDR_PATH=/usr

  INSTALL /usr/include

root@changeme:/compile/source/linux-stable# cp -v .config /boot/config-${kver}
'.config' -> '/boot/config-5.4.58-dirty'

root@changeme:/compile/source/linux-stable# cp -v arch/arm/boot/zImage /boot/zImage-${kver}
'arch/arm/boot/zImage' -> '/boot/zImage-5.4.58-dirty'

root@changeme:/compile/source/linux-stable# mkdir -p /boot/dtb-${kver}

root@changeme:/compile/source/linux-stable# cp -v arch/arm/boot/dts/exynos5250-snow.dtb /boot/dtb-${kver}
'arch/arm/boot/dts/exynos5250-snow.dtb' -> '/boot/dtb-5.4.58-dirty/exynos5250-snow.dtb'

root@changeme:/compile/source/linux-stable# cp -v arch/arm/boot/dts/exynos5250-snow-rev5.dtb /boot/dtb-${kver}
'arch/arm/boot/dts/exynos5250-snow-rev5.dtb' -> '/boot/dtb-5.4.58-dirty/exynos5250-snow-rev5.dtb'

root@changeme:/compile/source/linux-stable# cp -v System.map /boot/System.map-${kver}
'System.map' -> '/boot/System.map-5.4.58-dirty'

root@changeme:/compile/source/linux-stable# cd /boot

root@changeme:/boot# update-initramfs -c -k ${kver}
update-initramfs: Generating /boot/initrd.img-5.4.58-dirty
I: The initramfs will attempt to resume from /dev/mmcblk1p3
I: (UUID=a956c0e7-62fb-441f-9ab5-2a2a529f82dd)
I: Set the RESUME variable to override this.

root@changeme:/boot# mkimage -A arm -O linux -T ramdisk -a 0x0 -e 0x0 -n initrd.img-${kver} -d initrd.img-${kver} uInitrd-${kver}

Image Name:   initrd.img-5.4.58-dirty
Created:      Sun Aug 28 00:30:02 2022
Image Type:   ARM Linux RAMDisk Image (gzip compressed)
Data Size:    5813599 Bytes = 5677.34 KiB = 5.54 MiB
Load Address: 00000000
Entry Point:  00000000

root@changeme:/boot# tar cvzf /compile/source/linux-stable/${kver}.tar.gz /boot/*-${kver} /lib/modules/${kver}

tar: Removing leading `/' from member names
/boot/config-5.4.58-dirty
/boot/dtb-5.4.58-dirty/
/boot/dtb-5.4.58-dirty/exynos5250-snow-rev5.dtb
/boot/dtb-5.4.58-dirty/exynos5250-snow.dtb
/boot/initrd.img-5.4.58-dirty
/boot/System.map-5.4.58-dirty
/boot/uInitrd-5.4.58-dirty
/boot/zImage-5.4.58-dirty
/lib/modules/5.4.58-dirty/
/lib/modules/5.4.58-dirty/modules.alias
/lib/modules/5.4.58-dirty/modules.builtin.modinfo
/lib/modules/5.4.58-dirty/modules.order
/lib/modules/5.4.58-dirty/modules.symbols
/lib/modules/5.4.58-dirty/modules.devname
/lib/modules/5.4.58-dirty/modules.builtin.bin
/lib/modules/5.4.58-dirty/modules.symbols.bin
/lib/modules/5.4.58-dirty/source
/lib/modules/5.4.58-dirty/modules.dep.bin
/lib/modules/5.4.58-dirty/modules.softdep
/lib/modules/5.4.58-dirty/kernel/
/lib/modules/5.4.58-dirty/kernel/drivers/
/lib/modules/5.4.58-dirty/kernel/drivers/crypto/
/lib/modules/5.4.58-dirty/kernel/drivers/crypto/virtio/
/lib/modules/5.4.58-dirty/kernel/drivers/crypto/virtio/virtio_crypto.ko
/lib/modules/5.4.58-dirty/kernel/fs/
/lib/modules/5.4.58-dirty/kernel/fs/nfs/
/lib/modules/5.4.58-dirty/kernel/fs/nfs/flexfilelayout/
/lib/modules/5.4.58-dirty/kernel/fs/nfs/flexfilelayout/nfs_layout_flexfiles.ko
/lib/modules/5.4.58-dirty/kernel/crypto/
/lib/modules/5.4.58-dirty/kernel/crypto/crypto_engine.ko
/lib/modules/5.4.58-dirty/modules.builtin
/lib/modules/5.4.58-dirty/modules.alias.bin
/lib/modules/5.4.58-dirty/build
/lib/modules/5.4.58-dirty/modules.dep

root@changeme:/boot# cp -v /compile/doc/stable/config.cbe /compile/doc/stable/config.cbe.old
'/compile/doc/stable/config.cbe' -> '/compile/doc/stable/config.cbe.old'

root@changeme:/boot# cp -v /compile/source/linux-stable/.config /compile/doc/stable/config.cbe
'/compile/source/linux-stable/.config' -> '/compile/doc/stable/config.cbe'

root@changeme:/boot# cp -v /compile/source/linux-stable/.config /compile/doc/stable/config.cbe-${kver}
'/compile/source/linux-stable/.config' -> '/compile/doc/stable/config.cbe-5.4.58-dirty'

root@changeme:/boot# cp -v /compile/source/linux-stable/*.tar.gz /compile/result/stable
'/compile/source/linux-stable/5.4.58-dirty.tar.gz' -> '/compile/result/stable/5.4.58-dirty.tar.gz'
'/compile/source/linux-stable/5.4.58-stb-cbe+.tar.gz' -> '/compile/result/stable/5.4.58-stb-cbe+.tar.gz'

root@changeme:/boot# ls

config-5.4.3-stb-cbe+   initrd.img-5.4.3-stb-cbe+   uInitrd-5.4.3-stb-cbe+
config-5.4.58-dirty     initrd.img-5.4.58-dirty     uInitrd-5.4.58-dirty
config-5.4.58-stb-cbe+  initrd.img-5.4.58-stb-cbe+  uInitrd-5.4.58-stb-cbe+
dtb-5.4.3-stb-cbe+      lost+found                  zImage-5.4.3-stb-cbe+
dtb-5.4.58-dirty        System.map-5.4.3-stb-cbe+   zImage-5.4.58-dirty
dtb-5.4.58-stb-cbe+     System.map-5.4.58-dirty     zImage-5.4.58-stb-cbe+
extlinux                System.map-5.4.58-stb-cbe+

root@changeme:/boot/extlinux# nano extlinux.conf

TIMEOUT 30
DEFAULT v5458-dirty
MENU TITLE snow sd boot options
LABEL v543
      MENU LABEL v5.4.3 kernel mmcblk0
      LINUX ../zImage-5.4.3-stb-cbe+
      # rev4 snow chromebook
      FDT ../dtb-5.4.3-stb-cbe+/exynos5250-snow.dtb
      # rev5 snow chromebook
      #FDT ../dtb-5.4.3-stb-cbe+/exynos5250-snow-rev5.dtb
      APPEND console=tty1 init=/sbin/init root=PARTUUID=77b032bb-8642-b04a-a2dd-cc066e8f7ca5 ro rootwait noinitrd net.ifnames=0 ipv6.disable=1 fsck.repair=yes

LABEL v5458-dirty
      MENU LABEL v5.4.58-dirty kernel mmcblk0
      LINUX ../zImage-5.4.58-dirty
      # rev4 snow chromebook
      FDT ../dtb-5.4.58-dirty/exynos5250-snow.dtb
      # rev5 snow chromebook
      #FDT ../dtb-5.4.58-dirty/exynos5250-snow-rev5.dtb
      APPEND console=tty1 init=/sbin/init root=PARTUUID=77b032bb-8642-b04a-a2dd-cc066e8f7ca5 ro rootwait noinitrd net.ifnames=0 ipv6.disable=1 fsck.repair=yes
hexdump0815 commented 2 years ago

it could be that kvm already was simply broken in v5.4 for snow - bitrot is quite a bit of a problem for not so frequently used arm platforms ... i just checked my old snow build notes from before i started to record them in github repos and i had mainline running on snow back to v4.9, so that is proven to work at least to some degree (but some things like sound for instance did not work back then) - so some ideas what you could still try:

things might or might not work out in the end ... i think i'm out of ideas and out of this topic for now

good luck and best wishes - hexdump

Marietto2008 commented 2 years ago

I tried to follow this guide,using the kernel 3.13 :

http://www.virtualopensystems.com/en/solutions/guides/kvm-on-chromebook/

this is what happened : (I've installed your buildtools and the ubuntu package gcc-arm-none-eabi)

cd /compile/source
git clone https://github.com/virtualopensystems/linux-kvm-arm.git
cd linux-kvm-arm
git checkout origin/chromebook-3.13 -b chromebook-3.13
cp /home/linux/Desktop/Files/chromebook-KVM/VOS/OLD/config-host /compile/source/linux-kvm-arm/.config
export ARCH=arm
make oldconfig

  HOSTCC  scripts/basic/fixdep
  HOSTCC  scripts/kconfig/conf.o
  SHIPPED scripts/kconfig/zconf.tab.c
  SHIPPED scripts/kconfig/zconf.lex.c
  SHIPPED scripts/kconfig/zconf.hash.c
  HOSTCC  scripts/kconfig/zconf.tab.o
In file included from scripts/kconfig/zconf.tab.c:2537:0:
scripts/kconfig/menu.c: In function ‘get_symbol_str’:
scripts/kconfig/menu.c:587:18: warning: ‘jump’ may be used uninitialized in this function [-Wmaybe-uninitialized]
     jump->offset = strlen(r->s);
     ~~~~~~~~~~~~~^~~~~~~~~~~~~~
scripts/kconfig/menu.c:548:19: note: ‘jump’ was declared here
  struct jump_key *jump;
                   ^~~~
  HOSTLD  scripts/kconfig/conf
scripts/kconfig/conf --oldconfig Kconfig
#
# configuration written to .config
#

root@changeme:/compile/source/linux-kvm-arm# nano .config

root@changeme:/compile/source/linux-kvm-arm# make -j 4 zImage dtbs modules

scripts/kconfig/conf --silentoldconfig Kconfig
  CHK     include/config/kernel.release
  WRAP    arch/arm/include/generated/asm/cputime.h
  WRAP    arch/arm/include/generated/asm/bitsperlong.h
  WRAP    arch/arm/include/generated/asm/auxvec.h
  WRAP    arch/arm/include/generated/asm/current.h
  WRAP    arch/arm/include/generated/asm/emergency-restart.h
  WRAP    arch/arm/include/generated/asm/errno.h
  WRAP    arch/arm/include/generated/asm/exec.h
  WRAP    arch/arm/include/generated/asm/ipcbuf.h
  WRAP    arch/arm/include/generated/asm/ioctl.h
  WRAP    arch/arm/include/generated/asm/irq_regs.h
  WRAP    arch/arm/include/generated/asm/kdebug.h
  WRAP    arch/arm/include/generated/asm/local.h
  WRAP    arch/arm/include/generated/asm/local64.h
  WRAP    arch/arm/include/generated/asm/msgbuf.h
  WRAP    arch/arm/include/generated/asm/parport.h
  WRAP    arch/arm/include/generated/asm/param.h
  WRAP    arch/arm/include/generated/asm/poll.h
  WRAP    arch/arm/include/generated/asm/sections.h
  WRAP    arch/arm/include/generated/asm/resource.h
  WRAP    arch/arm/include/generated/asm/sembuf.h
  WRAP    arch/arm/include/generated/asm/segment.h
  WRAP    arch/arm/include/generated/asm/serial.h
  WRAP    arch/arm/include/generated/asm/shmbuf.h
  WRAP    arch/arm/include/generated/asm/siginfo.h
  WRAP    arch/arm/include/generated/asm/simd.h
  CHK     include/generated/uapi/linux/version.h
  WRAP    arch/arm/include/generated/asm/sizes.h
  UPD     include/generated/uapi/linux/version.h
  WRAP    arch/arm/include/generated/asm/socket.h
  WRAP    arch/arm/include/generated/asm/sockios.h
  WRAP    arch/arm/include/generated/asm/termbits.h
  WRAP    arch/arm/include/generated/asm/termios.h
  WRAP    arch/arm/include/generated/asm/trace_clock.h
  WRAP    arch/arm/include/generated/asm/timex.h
  WRAP    arch/arm/include/generated/asm/unaligned.h
  WRAP    arch/arm/include/generated/asm/preempt.h

The present kernel configuration has modules disabled.
Type 'make config' and enable loadable module support.
Then build a kernel with module support enabled.

Makefile:1024: recipe for target 'modules' failed
make: *** [modules] Error 1
make: *** Waiting for unfinished jobs....
  UPD     include/config/kernel.release

root@changeme:/compile/source/linux-kvm-arm# nano .config
Use "fg" to return to nano.

[1]+  Stopped                 nano .config (enabled modules inside .config)

root@changeme:/compile/source/linux-kvm-arm# make -j 4 zImage dtbs modules

scripts/kconfig/conf --silentoldconfig Kconfig
*
* Restart config...
*
*
* General setup
*
Cross-compiler tool prefix (CROSS_COMPILE) [] 
Compile also drivers which will not load (COMPILE_TEST) [N/y/?] n
Local version - append to kernel release (LOCALVERSION) [] 
Automatically append version information to the version string (LOCALVERSION_AUTO) [Y/n/?] y
Kernel compression mode
> 1. Gzip (KERNEL_GZIP)
  2. LZMA (KERNEL_LZMA)
  3. XZ (KERNEL_XZ)
  4. LZO (KERNEL_LZO)
  5. LZ4 (KERNEL_LZ4)
choice[1-5?]: 1
Default hostname (DEFAULT_HOSTNAME) [(none)] (none)
Support for paging of anonymous memory (swap) (SWAP) [Y/n/?] y
System V IPC (SYSVIPC) [Y/n/?] y
POSIX Message Queues (POSIX_MQUEUE) [N/y/?] n
open by fhandle syscalls (FHANDLE) [N/y/?] n
Auditing support (AUDIT) [N/y/?] n
Kernel .config support (IKCONFIG) [N/m/y/?] n
Kernel log buffer size (16 => 64KB, 17 => 128KB) (LOG_BUF_SHIFT) [17] 17
Require conversions between uid/gids and their internal representation (UIDGID_STRICT_TYPE_CHECKS) [N/y/?] n
Automatic process group scheduling (SCHED_AUTOGROUP) [N/y/?] n
Enable deprecated sysfs features to support old userspace tools (SYSFS_DEPRECATED) [N/y/?] n
Kernel->user space relay support (formerly relayfs) (RELAY) [N/y/?] n
Initial RAM filesystem and RAM disk (initramfs/initrd) support (BLK_DEV_INITRD) [Y/n/?] y
  Initramfs source file(s) (INITRAMFS_SOURCE) [] 
Optimize for size (CC_OPTIMIZE_FOR_SIZE) [N/y/?] n
Embedded system (EMBEDDED) [N/y/?] n
Disable heap randomization (COMPAT_BRK) [Y/n/?] y
Choose SLAB allocator
  1. SLAB (SLAB)
> 2. SLUB (Unqueued Allocator) (SLUB)
choice[1-2?]: 2
SLUB per cpu partial cache (SLUB_CPU_PARTIAL) [Y/n/?] y
Profiling support (PROFILING) [N/y/?] n
Kprobes (KPROBES) [N/y/?] (NEW) 
Optimize very unlikely/likely branches (JUMP_LABEL) [N/y/?] n
*
* Enable loadable module support
*
Enable loadable module support (MODULES) [Y/n/?] y
  Forced module loading (MODULE_FORCE_LOAD) [N/y/?] (NEW) 
  Module unloading (MODULE_UNLOAD) [N/y/?] (NEW) 
  Module versioning support (MODVERSIONS) [N/y/?] (NEW) 
  Source checksum for all modules (MODULE_SRCVERSION_ALL) [N/y/?] (NEW) 
  Module signature verification (MODULE_SIG) [N/y/?] (NEW) 

*
* Networking options
*
Packet socket (PACKET) [Y/n/m/?] y
  Packet: sockets monitoring interface (PACKET_DIAG) [N/m/y/?] n
Unix domain sockets (UNIX) [Y/n/m/?] y
  UNIX: socket monitoring interface (UNIX_DIAG) [N/m/y/?] n
Transformation user configuration interface (XFRM_USER) [N/m/y/?] n
Transformation sub policy support (XFRM_SUB_POLICY) [N/y/?] n
Transformation migrate database (XFRM_MIGRATE) [N/y/?] n
Transformation statistics (XFRM_STATISTICS) [N/y/?] n
PF_KEY sockets (NET_KEY) [Y/n/m/?] y
  PF_KEY MIGRATE (NET_KEY_MIGRATE) [N/y/?] n
TCP/IP networking (INET) [Y/n/?] y
  IP: multicasting (IP_MULTICAST) [N/y/?] n
  IP: advanced router (IP_ADVANCED_ROUTER) [N/y/?] n
  IP: kernel level autoconfiguration (IP_PNP) [N/y/?] n
  IP: tunneling (NET_IPIP) [N/m/y/?] n
  IP: GRE demultiplexer (NET_IPGRE_DEMUX) [N/m/y/?] n
  IP: TCP syncookie support (SYN_COOKIES) [N/y/?] n
  Virtual (secure) IP: tunneling (NET_IPVTI) [N/m/y/?] n
  IP: AH transformation (INET_AH) [N/m/y/?] n
  IP: ESP transformation (INET_ESP) [N/m/y/?] n
  IP: IPComp transformation (INET_IPCOMP) [N/m/y/?] n
  IP: IPsec transport mode (INET_XFRM_MODE_TRANSPORT) [Y/n/m/?] y
  IP: IPsec tunnel mode (INET_XFRM_MODE_TUNNEL) [Y/n/m/?] y
  IP: IPsec BEET mode (INET_XFRM_MODE_BEET) [Y/n/m/?] y
  Large Receive Offload (ipv4/tcp) (INET_LRO) [Y/n/m/?] y
  INET: socket monitoring interface (INET_DIAG) [Y/n/m/?] y
    UDP: socket monitoring interface (INET_UDP_DIAG) [N/m/y/?] n
  TCP: MD5 Signature Option support (RFC2385) (TCP_MD5SIG) [N/y/?] n
Security Marking (NETWORK_SECMARK) [N/y/?] n
Timestamping in PHY devices (NETWORK_PHY_TIMESTAMPING) [N/y/?] n
The RDS Protocol (RDS) [N/m/y/?] n
Asynchronous Transfer Mode (ATM) (ATM) [N/m/y/?] n
802.1d Ethernet Bridging (BRIDGE) [Y/n/m/?] y
  IGMP/MLD snooping (BRIDGE_IGMP_SNOOPING) [Y/n/?] y
802.1Q/802.1ad VLAN Support (VLAN_8021Q) [N/m/y/?] n
DECnet Support (DECNET) [N/m/y/?] n
ANSI/IEEE 802.2 LLC type 2 Support (LLC2) [N/m/y/?] n
The IPX protocol (IPX) [N/m/y/?] n
Appletalk protocol support (ATALK) [N/m/y/?] n
CCITT X.25 Packet Layer (X25) [N/m/y/?] n
LAPB Data Link Driver (LAPB) [N/m/y/?] n
Phonet protocols family (PHONET) [N/m/y/?] n
IEEE Std 802.15.4 Low-Rate Wireless Personal Area Networks support (IEEE802154) [N/m/y/?] n
Data Center Bridging support (DCB) [N/y/?] n
DNS Resolver support (DNS_RESOLVER) [Y/?] y
B.A.T.M.A.N. Advanced Meshing Protocol (BATMAN_ADV) [N/m/y/?] n
Open vSwitch (OPENVSWITCH) [N/m/y/?] n
Virtual Socket protocol (VSOCKETS) [N/m/y/?] n
NETLINK: mmaped IO (NETLINK_MMAP) [N/y/?] n
NETLINK: socket monitoring interface (NETLINK_DIAG) [N/m/y/?] n
MPLS: GSO support (NET_MPLS_GSO) [N/m/y/?] n
High-availability Seamless Redundancy (HSR) (HSR) [N/m/y/?] n
enable BPF Just In Time compiler (BPF_JIT) [N/y/?] (NEW) *
* I2C support
*
I2C support (I2C) [Y/n/m/?] y
  Enable compatibility bits for old user-space (I2C_COMPAT) [Y/n/?] y
  I2C device interface (I2C_CHARDEV) [N/m/y/?] n
  I2C bus multiplexing support (I2C_MUX) [Y/n/m/?] y
  Autoselect pertinent helper modules (I2C_HELPER_AUTO) [Y/n/?] y
  I2C/SMBus Test Stub (I2C_STUB) [N/m/?] (NEW) 
  I2C Core debugging messages (I2C_DEBUG_CORE) [N/y/?] n
  I2C Algorithm debugging messages (I2C_DEBUG_ALGO) [N/y/?] n
  I2C Bus debugging messages (I2C_DEBUG_BUS) [N/y/?] n
*
* Runtime Testing
*
Linked list sorting test (TEST_LIST_SORT) [N/y/?] n
Self test for the backtrace code (BACKTRACE_SELF_TEST) [N/m/y/?] n
Red-Black tree test (RBTREE_TEST) [N/m/y/?] n
Interval tree test (INTERVAL_TREE_TEST) [N/m/?] (NEW) 
Per cpu operations test (PERCPU_TEST) [N/m/?] (NEW) 
Perform an atomic64_t self-test at boot (ATOMIC64_SELFTEST) [N/y/?] n
Test functions located in the string_helpers module at runtime (TEST_STRING_HELPERS) [N/m/y] n
Test kstrto*() family of functions at runtime (TEST_KSTRTOX) [N/m/y] n
*
* Cryptographic API
*
Cryptographic API (CRYPTO) [Y/?] y
  *
  * Crypto core or helper
  *
  Cryptographic algorithm manager (CRYPTO_MANAGER) [Y/?] y
  Userspace cryptographic algorithm configuration (CRYPTO_USER) [N/m/y/?] n
  Disable run-time self tests (CRYPTO_MANAGER_DISABLE_TESTS) [Y/n/?] y
  GF(2^128) multiplication functions (CRYPTO_GF128MUL) [N/m/y/?] n
  Null algorithms (CRYPTO_NULL) [N/m/y/?] n
  Parallel crypto engine (CRYPTO_PCRYPT) [N/m/y/?] n
  Software async crypto daemon (CRYPTO_CRYPTD) [N/m/y/?] n
  Authenc support (CRYPTO_AUTHENC) [N/m/y/?] n
  Testing module (CRYPTO_TEST) [N/m/?] (NEW)   *
  * Authenticated Encryption with Associated Data
  *
  CCM support (CRYPTO_CCM) [Y/?] y
  GCM/GMAC support (CRYPTO_GCM) [N/m/y/?] n
  Sequence Number IV Generator (CRYPTO_SEQIV) [Y/?] y
  *
  * Block modes
  *
  CBC support (CRYPTO_CBC) [Y/?] y
  CTR support (CRYPTO_CTR) [Y/?] y
  CTS support (CRYPTO_CTS) [N/m/y/?] n
  ECB support (CRYPTO_ECB) [N/m/y/?] n
  LRW support (CRYPTO_LRW) [N/m/y/?] n
  PCBC support (CRYPTO_PCBC) [N/m/y/?] n
  XTS support (CRYPTO_XTS) [N/m/y/?] n
  *
  * Hash modes
  *
  CMAC support (CRYPTO_CMAC) [N/m/y/?] n
  HMAC support (CRYPTO_HMAC) [N/m/y/?] n
  XCBC support (CRYPTO_XCBC) [N/m/y/?] n
  VMAC support (CRYPTO_VMAC) [N/m/y/?] n
  *
  * Digest
  *
  CRC32c CRC algorithm (CRYPTO_CRC32C) [Y/?] y
  CRC32 CRC algorithm (CRYPTO_CRC32) [N/m/y/?] n
  CRCT10DIF algorithm (CRYPTO_CRCT10DIF) [N/m/y/?] n
  GHASH digest algorithm (CRYPTO_GHASH) [N/m/y/?] n
  MD4 digest algorithm (CRYPTO_MD4) [N/m/y/?] n
  MD5 digest algorithm (CRYPTO_MD5) [N/m/y/?] n
  Michael MIC keyed digest algorithm (CRYPTO_MICHAEL_MIC) [N/m/y/?] n
  RIPEMD-128 digest algorithm (CRYPTO_RMD128) [N/m/y/?] n
  RIPEMD-160 digest algorithm (CRYPTO_RMD160) [N/m/y/?] n
  RIPEMD-256 digest algorithm (CRYPTO_RMD256) [N/m/y/?] n
  RIPEMD-320 digest algorithm (CRYPTO_RMD320) [N/m/y/?] n
  SHA1 digest algorithm (CRYPTO_SHA1) [N/m/y/?] n
  SHA1 digest algorithm (ARM-asm) (CRYPTO_SHA1_ARM) [N/m/y/?] n
  SHA224 and SHA256 digest algorithm (CRYPTO_SHA256) [Y/n/m/?] y
  SHA384 and SHA512 digest algorithms (CRYPTO_SHA512) [N/m/y/?] n
  Tiger digest algorithms (CRYPTO_TGR192) [N/m/y/?] n
  Whirlpool digest algorithms (CRYPTO_WP512) [N/m/y/?] n
  *
  * Ciphers
  *
  AES cipher algorithms (CRYPTO_AES) [Y/?] y
  AES cipher algorithms (ARM-asm) (CRYPTO_AES_ARM) [N/m/y/?] n
  Anubis cipher algorithm (CRYPTO_ANUBIS) [N/m/y/?] n
  ARC4 cipher algorithm (CRYPTO_ARC4) [Y/?] y
  Blowfish cipher algorithm (CRYPTO_BLOWFISH) [N/m/y/?] n
  Camellia cipher algorithms (CRYPTO_CAMELLIA) [N/m/y/?] n
  CAST5 (CAST-128) cipher algorithm (CRYPTO_CAST5) [N/m/y/?] n
  CAST6 (CAST-256) cipher algorithm (CRYPTO_CAST6) [N/m/y/?] n
  DES and Triple DES EDE cipher algorithms (CRYPTO_DES) [N/m/y/?] n
  FCrypt cipher algorithm (CRYPTO_FCRYPT) [N/m/y/?] n
  Khazad cipher algorithm (CRYPTO_KHAZAD) [N/m/y/?] n
  Salsa20 stream cipher algorithm (CRYPTO_SALSA20) [N/m/y/?] n
  SEED cipher algorithm (CRYPTO_SEED) [N/m/y/?] n
  Serpent cipher algorithm (CRYPTO_SERPENT) [N/m/y/?] n
  TEA, XTEA and XETA cipher algorithms (CRYPTO_TEA) [N/m/y/?] n
  Twofish cipher algorithm (CRYPTO_TWOFISH) [N/m/y/?] n
  *
  * Compression
  *
  Deflate compression algorithm (CRYPTO_DEFLATE) [N/m/y/?] n
  Zlib compression algorithm (CRYPTO_ZLIB) [N/m/y/?] n
  LZO compression algorithm (CRYPTO_LZO) [N/m/y/?] n
  LZ4 compression algorithm (CRYPTO_LZ4) [N/m/y/?] n
  LZ4HC compression algorithm (CRYPTO_LZ4HC) [N/m/y/?] n
  *
  * Random Number Generation
  *
  Pseudo Random Number Generation for Cryptographic modules (CRYPTO_ANSI_CPRNG) [Y/n/m/?] y
  User-space interface for hash algorithms (CRYPTO_USER_API_HASH) [N/m/y/?] n
  User-space interface for symmetric key cipher algorithms (CRYPTO_USER_API_SKCIPHER) [N/m/y/?] n
#
# configuration written to .config
#

  CHK     include/config/kernel.release
  CHK     include/generated/uapi/linux/version.h
  HOSTCC  scripts/dtc/checks.o
  HOSTCC  scripts/dtc/data.o
  SHIPPED scripts/dtc/dtc-lexer.lex.c
  SHIPPED scripts/dtc/dtc-parser.tab.h
  SHIPPED scripts/dtc/dtc-parser.tab.c
  HOSTCC  scripts/dtc/dtc.o
  HOSTCC  scripts/dtc/flattree.o
  HOSTCC  scripts/dtc/fstree.o
  CHK     include/generated/utsrelease.h
  UPD     include/generated/utsrelease.h
  HOSTCC  scripts/dtc/livetree.o
  Generating include/generated/mach-types.h
  HOSTCC  scripts/dtc/srcpos.o
  CC      kernel/bounds.s
In file included from include/linux/compiler.h:54:0,
                 from include/uapi/linux/stddef.h:1,
                 from include/linux/stddef.h:4,
                 from /compile/source/linux-kvm-arm/include/uapi/linux/posix_types.h:4,
                 from include/uapi/linux/types.h:13,
                 from include/linux/types.h:5,
                 from include/linux/page-flags.h:8,
                 from kernel/bounds.c:9:
include/linux/compiler-gcc.h:103:1: fatal error: linux/compiler-gcc7.h: No such file or directory
 #include gcc_header(__GNUC__)
 ^~~~
compilation terminated.
/compile/source/linux-kvm-arm/./Kbuild:35: recipe for target 'kernel/bounds.s' failed
make[1]: *** [kernel/bounds.s] Error 1
Makefile:859: recipe for target 'prepare0' failed
make: *** [prepare0] Error 2
make: *** Waiting for unfinished jobs....
  HOSTCC  scripts/dtc/treesource.o
  HOSTCC  scripts/dtc/util.o
  HOSTCC  scripts/dtc/dtc-lexer.lex.o
  HOSTCC  scripts/dtc/dtc-parser.tab.o
  HOSTCC  scripts/mod/mk_elfconfig
  CC      scripts/mod/empty.o
  HOSTCC  scripts/kallsyms
  CC      scripts/mod/devicetable-offsets.s
In file included from include/linux/compiler.h:54:0,
                 from include/uapi/linux/stddef.h:1,
                 from include/linux/stddef.h:4,
                 from /compile/source/linux-kvm-arm/include/uapi/linux/posix_types.h:4,
                 from include/uapi/linux/types.h:13,
                 from include/linux/types.h:5,
                 from include/linux/mod_devicetable.h:11,
                 from scripts/mod/devicetable-offsets.c:2:
include/linux/compiler-gcc.h:103:1: fatal error: linux/compiler-gcc7.h: No such file or directory
 #include gcc_header(__GNUC__)
 ^~~~
compilation terminated.
scripts/Makefile.build:204: recipe for target 'scripts/mod/devicetable-offsets.s' failed
make[2]: *** [scripts/mod/devicetable-offsets.s] Error 1
scripts/Makefile.build:455: recipe for target 'scripts/mod' failed
make[1]: *** [scripts/mod] Error 2
make[1]: *** Waiting for unfinished jobs....
  HOSTLD  scripts/dtc/dtc
Makefile:521: recipe for target 'scripts' failed
make: *** [scripts] Error 2

I don't understand. Im using gcc 7 :

root@changeme:/compile/source/linux-kvm-arm# gcc --version
gcc (Ubuntu/Linaro 7.5.0-3ubuntu1~18.04) 7.5.0
Marietto2008 commented 2 years ago

another update. I've used the precompiled files provided by the virtual open system website and this is what happened :

Screenshot_2022-08-29_18-14-38

Marietto2008 commented 2 years ago

Instead this is what happens when I try to compile the kernel 3.13 using ubuntu 22.04 as host os and this version of gcc :

gcc --version
gcc (Ubuntu 11.2.0-19ubuntu1) 11.2.0

(i've installed your build-tools)

root@changeme:/compile/source/linux-kvm-arm# make -j 4 zImage dtbs modules
scripts/kconfig/conf --silentoldconfig Kconfig
*
* Restart config...
*
*
* General setup
*
Cross-compiler tool prefix (CROSS_COMPILE) [] 
Compile also drivers which will not load (COMPILE_TEST) [N/y/?] n
Local version - append to kernel release (LOCALVERSION) [] 
Automatically append version information to the version string (LOCALVERSION_AUTO) [Y/n/?] y
Kernel compression mode
> 1. Gzip (KERNEL_GZIP)
  2. LZMA (KERNEL_LZMA)
  3. XZ (KERNEL_XZ)
  4. LZO (KERNEL_LZO)
  5. LZ4 (KERNEL_LZ4)
choice[1-5?]: 1
Default hostname (DEFAULT_HOSTNAME) [(none)] (none)
Support for paging of anonymous memory (swap) (SWAP) [Y/n/?] y
System V IPC (SYSVIPC) [Y/n/?] y
POSIX Message Queues (POSIX_MQUEUE) [N/y/?] n
open by fhandle syscalls (FHANDLE) [N/y/?] n
Auditing support (AUDIT) [N/y/?] n
Kernel .config support (IKCONFIG) [N/m/y/?] n
Kernel log buffer size (16 => 64KB, 17 => 128KB) (LOG_BUF_SHIFT) [17] 17
Require conversions between uid/gids and their internal representation (UIDGID_STRICT_TYPE_CHECKS) [N/y/?] n
Automatic process group scheduling (SCHED_AUTOGROUP) [N/y/?] n
Enable deprecated sysfs features to support old userspace tools (SYSFS_DEPRECATED) [N/y/?] n
Kernel->user space relay support (formerly relayfs) (RELAY) [N/y/?] n
Initial RAM filesystem and RAM disk (initramfs/initrd) support (BLK_DEV_INITRD) [Y/n/?] y
  Initramfs source file(s) (INITRAMFS_SOURCE) [] 
Optimize for size (CC_OPTIMIZE_FOR_SIZE) [N/y/?] n
Embedded system (EMBEDDED) [N/y/?] n
Disable heap randomization (COMPAT_BRK) [Y/n/?] y
Choose SLAB allocator
  1. SLAB (SLAB)
> 2. SLUB (Unqueued Allocator) (SLUB)
choice[1-2?]: 2
SLUB per cpu partial cache (SLUB_CPU_PARTIAL) [Y/n/?] y
Profiling support (PROFILING) [N/y/?] n
Kprobes (KPROBES) [N/y/?] (NEW) 
Optimize very unlikely/likely branches (JUMP_LABEL) [N/y/?] n
*
* Enable loadable module support
*
Enable loadable module support (MODULES) [Y/n/?] y
  Forced module loading (MODULE_FORCE_LOAD) [N/y/?] (NEW) 
  Module unloading (MODULE_UNLOAD) [N/y/?] (NEW) 
  Module versioning support (MODVERSIONS) [N/y/?] (NEW) 
  Source checksum for all modules (MODULE_SRCVERSION_ALL) [N/y/?] (NEW) 
  Module signature verification (MODULE_SIG) [N/y/?] (NEW) 
*
* Networking options
*
Packet socket (PACKET) [Y/n/m/?] y
  Packet: sockets monitoring interface (PACKET_DIAG) [N/m/y/?] n
Unix domain sockets (UNIX) [Y/n/m/?] y
  UNIX: socket monitoring interface (UNIX_DIAG) [N/m/y/?] n
Transformation user configuration interface (XFRM_USER) [N/m/y/?] n
Transformation sub policy support (XFRM_SUB_POLICY) [N/y/?] n
Transformation migrate database (XFRM_MIGRATE) [N/y/?] n
Transformation statistics (XFRM_STATISTICS) [N/y/?] n
PF_KEY sockets (NET_KEY) [Y/n/m/?] y
  PF_KEY MIGRATE (NET_KEY_MIGRATE) [N/y/?] n
TCP/IP networking (INET) [Y/n/?] y
  IP: multicasting (IP_MULTICAST) [N/y/?] n
  IP: advanced router (IP_ADVANCED_ROUTER) [N/y/?] n
  IP: kernel level autoconfiguration (IP_PNP) [N/y/?] n
  IP: tunneling (NET_IPIP) [N/m/y/?] n
  IP: GRE demultiplexer (NET_IPGRE_DEMUX) [N/m/y/?] n
  IP: TCP syncookie support (SYN_COOKIES) [N/y/?] n
  Virtual (secure) IP: tunneling (NET_IPVTI) [N/m/y/?] n
  IP: AH transformation (INET_AH) [N/m/y/?] n
  IP: ESP transformation (INET_ESP) [N/m/y/?] n
  IP: IPComp transformation (INET_IPCOMP) [N/m/y/?] n
  IP: IPsec transport mode (INET_XFRM_MODE_TRANSPORT) [Y/n/m/?] y
  IP: IPsec tunnel mode (INET_XFRM_MODE_TUNNEL) [Y/n/m/?] y
  IP: IPsec BEET mode (INET_XFRM_MODE_BEET) [Y/n/m/?] y
  Large Receive Offload (ipv4/tcp) (INET_LRO) [Y/n/m/?] y
  INET: socket monitoring interface (INET_DIAG) [Y/n/m/?] y
    UDP: socket monitoring interface (INET_UDP_DIAG) [N/m/y/?] n
  TCP: MD5 Signature Option support (RFC2385) (TCP_MD5SIG) [N/y/?] n
Security Marking (NETWORK_SECMARK) [N/y/?] n
Timestamping in PHY devices (NETWORK_PHY_TIMESTAMPING) [N/y/?] n
The RDS Protocol (RDS) [N/m/y/?] n
Asynchronous Transfer Mode (ATM) (ATM) [N/m/y/?] n
802.1d Ethernet Bridging (BRIDGE) [Y/n/m/?] y
  IGMP/MLD snooping (BRIDGE_IGMP_SNOOPING) [Y/n/?] y
802.1Q/802.1ad VLAN Support (VLAN_8021Q) [N/m/y/?] n
DECnet Support (DECNET) [N/m/y/?] n
ANSI/IEEE 802.2 LLC type 2 Support (LLC2) [N/m/y/?] n
The IPX protocol (IPX) [N/m/y/?] n
Appletalk protocol support (ATALK) [N/m/y/?] n
CCITT X.25 Packet Layer (X25) [N/m/y/?] n
LAPB Data Link Driver (LAPB) [N/m/y/?] n
Phonet protocols family (PHONET) [N/m/y/?] n
IEEE Std 802.15.4 Low-Rate Wireless Personal Area Networks support (IEEE802154) [N/m/y/?] n
Data Center Bridging support (DCB) [N/y/?] n
DNS Resolver support (DNS_RESOLVER) [Y/?] y
B.A.T.M.A.N. Advanced Meshing Protocol (BATMAN_ADV) [N/m/y/?] n
Open vSwitch (OPENVSWITCH) [N/m/y/?] n
Virtual Socket protocol (VSOCKETS) [N/m/y/?] n
NETLINK: mmaped IO (NETLINK_MMAP) [N/y/?] n
NETLINK: socket monitoring interface (NETLINK_DIAG) [N/m/y/?] n
MPLS: GSO support (NET_MPLS_GSO) [N/m/y/?] n
High-availability Seamless Redundancy (HSR) (HSR) [N/m/y/?] n
enable BPF Just In Time compiler (BPF_JIT) [N/y/?] (NEW) 
*
* I2C support
*
I2C support (I2C) [Y/n/m/?] y
  Enable compatibility bits for old user-space (I2C_COMPAT) [Y/n/?] y
  I2C device interface (I2C_CHARDEV) [N/m/y/?] n
  I2C bus multiplexing support (I2C_MUX) [Y/n/m/?] y
  Autoselect pertinent helper modules (I2C_HELPER_AUTO) [Y/n/?] y
  I2C/SMBus Test Stub (I2C_STUB) [N/m/?] (NEW) 
  I2C Core debugging messages (I2C_DEBUG_CORE) [N/y/?] n
  I2C Algorithm debugging messages (I2C_DEBUG_ALGO) [N/y/?] n
  I2C Bus debugging messages (I2C_DEBUG_BUS) [N/y/?] n
*
* Runtime Testing
*
Linked list sorting test (TEST_LIST_SORT) [N/y/?] n
Self test for the backtrace code (BACKTRACE_SELF_TEST) [N/m/y/?] n
Red-Black tree test (RBTREE_TEST) [N/m/y/?] n
Interval tree test (INTERVAL_TREE_TEST) [N/m/?] (NEW) 
Per cpu operations test (PERCPU_TEST) [N/m/?] (NEW) 
Perform an atomic64_t self-test at boot (ATOMIC64_SELFTEST) [N/y/?] n
Test functions located in the string_helpers module at runtime (TEST_STRING_HELPERS) [N/m/y] n
Test kstrto*() family of functions at runtime (TEST_KSTRTOX) [N/m/y] n
*
* Cryptographic API
*
Cryptographic API (CRYPTO) [Y/?] y
  *
  * Crypto core or helper
  *
  Cryptographic algorithm manager (CRYPTO_MANAGER) [Y/?] y
  Userspace cryptographic algorithm configuration (CRYPTO_USER) [N/m/y/?] n
  Disable run-time self tests (CRYPTO_MANAGER_DISABLE_TESTS) [Y/n/?] y
  GF(2^128) multiplication functions (CRYPTO_GF128MUL) [N/m/y/?] n
  Null algorithms (CRYPTO_NULL) [N/m/y/?] n
  Parallel crypto engine (CRYPTO_PCRYPT) [N/m/y/?] n
  Software async crypto daemon (CRYPTO_CRYPTD) [N/m/y/?] n
  Authenc support (CRYPTO_AUTHENC) [N/m/y/?] n
  Testing module (CRYPTO_TEST) [N/m/?] (NEW) 
  *
  * Authenticated Encryption with Associated Data
  *
  CCM support (CRYPTO_CCM) [Y/?] y
  GCM/GMAC support (CRYPTO_GCM) [N/m/y/?] n
  Sequence Number IV Generator (CRYPTO_SEQIV) [Y/?] y
  *
  * Block modes
  *
  CBC support (CRYPTO_CBC) [Y/?] y
  CTR support (CRYPTO_CTR) [Y/?] y
  CTS support (CRYPTO_CTS) [N/m/y/?] n
  ECB support (CRYPTO_ECB) [N/m/y/?] n
  LRW support (CRYPTO_LRW) [N/m/y/?] n
  PCBC support (CRYPTO_PCBC) [N/m/y/?] n
  XTS support (CRYPTO_XTS) [N/m/y/?] n
  *
  * Hash modes
  *
  CMAC support (CRYPTO_CMAC) [N/m/y/?] n
  HMAC support (CRYPTO_HMAC) [N/m/y/?] n
  XCBC support (CRYPTO_XCBC) [N/m/y/?] n
  VMAC support (CRYPTO_VMAC) [N/m/y/?] n
  *
  * Digest
  *
  CRC32c CRC algorithm (CRYPTO_CRC32C) [Y/?] y
  CRC32 CRC algorithm (CRYPTO_CRC32) [N/m/y/?] n
  CRCT10DIF algorithm (CRYPTO_CRCT10DIF) [N/m/y/?] n
  GHASH digest algorithm (CRYPTO_GHASH) [N/m/y/?] n
  MD4 digest algorithm (CRYPTO_MD4) [N/m/y/?] n
  MD5 digest algorithm (CRYPTO_MD5) [N/m/y/?] n
  Michael MIC keyed digest algorithm (CRYPTO_MICHAEL_MIC) [N/m/y/?] n
  RIPEMD-128 digest algorithm (CRYPTO_RMD128) [N/m/y/?] n
  RIPEMD-160 digest algorithm (CRYPTO_RMD160) [N/m/y/?] n
  RIPEMD-256 digest algorithm (CRYPTO_RMD256) [N/m/y/?] n
  RIPEMD-320 digest algorithm (CRYPTO_RMD320) [N/m/y/?] n
  SHA1 digest algorithm (CRYPTO_SHA1) [N/m/y/?] n
  SHA1 digest algorithm (ARM-asm) (CRYPTO_SHA1_ARM) [N/m/y/?] n
  SHA224 and SHA256 digest algorithm (CRYPTO_SHA256) [Y/n/m/?] y
  SHA384 and SHA512 digest algorithms (CRYPTO_SHA512) [N/m/y/?] n
  Tiger digest algorithms (CRYPTO_TGR192) [N/m/y/?] n
  Whirlpool digest algorithms (CRYPTO_WP512) [N/m/y/?] n
  *
  * Ciphers
  *
  AES cipher algorithms (CRYPTO_AES) [Y/?] y
  AES cipher algorithms (ARM-asm) (CRYPTO_AES_ARM) [N/m/y/?] n
  Anubis cipher algorithm (CRYPTO_ANUBIS) [N/m/y/?] n
  ARC4 cipher algorithm (CRYPTO_ARC4) [Y/?] y
  Blowfish cipher algorithm (CRYPTO_BLOWFISH) [N/m/y/?] n
  Camellia cipher algorithms (CRYPTO_CAMELLIA) [N/m/y/?] n
  CAST5 (CAST-128) cipher algorithm (CRYPTO_CAST5) [N/m/y/?] n
  CAST6 (CAST-256) cipher algorithm (CRYPTO_CAST6) [N/m/y/?] n
  DES and Triple DES EDE cipher algorithms (CRYPTO_DES) [N/m/y/?] n
  FCrypt cipher algorithm (CRYPTO_FCRYPT) [N/m/y/?] n
  Khazad cipher algorithm (CRYPTO_KHAZAD) [N/m/y/?] n
  Salsa20 stream cipher algorithm (CRYPTO_SALSA20) [N/m/y/?] n
  SEED cipher algorithm (CRYPTO_SEED) [N/m/y/?] n
  Serpent cipher algorithm (CRYPTO_SERPENT) [N/m/y/?] n
  TEA, XTEA and XETA cipher algorithms (CRYPTO_TEA) [N/m/y/?] n
  Twofish cipher algorithm (CRYPTO_TWOFISH) [N/m/y/?] n
  *
  * Compression
  *
  Deflate compression algorithm (CRYPTO_DEFLATE) [N/m/y/?] n
  Zlib compression algorithm (CRYPTO_ZLIB) [N/m/y/?] n
  LZO compression algorithm (CRYPTO_LZO) [N/m/y/?] n
  LZ4 compression algorithm (CRYPTO_LZ4) [N/m/y/?] n
  LZ4HC compression algorithm (CRYPTO_LZ4HC) [N/m/y/?] n
  *
  * Random Number Generation
  *
  Pseudo Random Number Generation for Cryptographic modules (CRYPTO_ANSI_CPRNG) [Y/n/m/?] y
  User-space interface for hash algorithms (CRYPTO_USER_API_HASH) [N/m/y/?] n
  User-space interface for symmetric key cipher algorithms (CRYPTO_USER_API_SKCIPHER) [N/m/y/?] n
#
# configuration written to .config
#

  CHK     include/config/kernel.release
  CHK     include/generated/uapi/linux/version.h
  HOSTLD  scripts/dtc/dtc
**/usr/bin/ld: scripts/dtc/dtc-parser.tab.o:(.bss+0x0): multiple definition of `yylloc'; scripts/dtc/dtc-lexer.lex.o:(.bss+0x38): first defined here**
collect2: error: ld returned 1 exit status
make[2]: *** [scripts/Makefile.host:127: scripts/dtc/dtc] Error 1
make[1]: *** [scripts/Makefile.build:455: scripts/dtc] Error 2
make: *** [Makefile:521: scripts] Error 2
make: *** Waiting for unfinished jobs....
Marietto2008 commented 2 years ago

the reason :

https://stackoverflow.com/questions/38287313/error-when-compiling-linux-kernel-3-2-for-arm

hexdump0815 commented 2 years ago

yes all this is getting far from easy and will require quite a bit of effort to get it working ... also it might be that a v3 kernel does not work well with u-boot - at least the v3.8 chromeos kernel cannot be booted via u-boot and one needs to write the vmlinux kpart file to the kernel partition directly instead ...

Marietto2008 commented 2 years ago

I think that on ubuntu 18 and 22 the gcc compiler is too new for the kernel 3.2. I should install ggc-4 as explained here :

Your kernel version (3.2.0) is too old and not compatible with used gcc (gcc-5). You may use gcc-4 to compile kernel, or use newer kernel version. (Actually I'm trying to follow the tutorials that I know it will work for sure and they use the kernel 3.2 and 3.3).

So maybe I can try this version :

http://releases.linaro.org/components/toolchain/gcc-linaro/4.9-2016.02/

Marietto2008 commented 2 years ago

I've got linaro gcc-arm-none-eabi-4_9-2014q4 and I've added the path at the bottom of the ~/.bashrc file and then I did :

root@changeme:/compile/source/linux-kvm-arm# mv /usr/bin/gcc /usr/bin/gcc_

root@changeme:/compile/source/linux-kvm-arm# sudo ln -f -s /compile/source/gcc-arm-none-eabi-4_9-2014q4/bin/arm-none-eabi-gcc-4.9.3 /usr/bin/gcc

root@changeme:/compile/source/linux-kvm-arm# gcc --version
bash: /usr/bin/gcc: cannot execute binary file: Exec format error

where is the error ? it seems the wrong gcc version :

root@changeme:/compile/source/linux-kvm-arm# update-alternatives --install /usr/bin/gcc gcc /compile/source/gcc-arm-none-eabi-4_9-2014q4/bin/arm-none-eabi-gcc-4.9.3 50

update-alternatives: using /compile/source/gcc-arm-none-eabi-4_9-2014q4/bin/arm-none-eabi-gcc-4.9.3 to provide /usr/bin/gcc (gcc) in auto mode

root@changeme:/compile/source/linux-kvm-arm# update-alternatives --query gcc
Name: gcc
Link: /usr/bin/gcc
Status: auto
Best: /compile/source/gcc-arm-none-eabi-4_9-2014q4/bin/arm-none-eabi-gcc-4.9.3
Value: /compile/source/gcc-arm-none-eabi-4_9-2014q4/bin/arm-none-eabi-gcc-4.9.3

Alternative: /compile/source/gcc-arm-none-eabi-4_9-2014q4/bin/arm-none-eabi-gcc-4.9.3
Priority: 50

root@changeme:/compile/source/linux-kvm-arm# gcc --version
bash: /usr/bin/gcc: cannot execute binary file: Exec format error
Marietto2008 commented 2 years ago

I'm reading here : http://www.virtualopensystems.com/en/solutions/guides/kvm-on-chromebook/ ; on the bootloader section,he says :

Bootloader

If you wish to skip this chapter you can download a pre-compiled binary of the bootloader:

$ wget http://www.virtualopensystems.com/downloads/guides/kvm_on_chromebook/nv_u-boot-snow.kpart

To be able to run KVM on ARM platforms, the kernel has to be booted in hypervisor mode. Because of this relatively recent requirement (due to the introduction of the virtualization extensions), up until now all booting methods would boot the kernel in the standard Supervisor mode.

For the ARM Chromebook the default boot procedure doesn't allow us to boot in hypervisor mode. Although the laptop's boot mechanism is based on the frequently used u-boot, the binary is located in RO memory. Fortunately, a chained u-boot mechanism can be used (i.e. starting another u-boot after the original). We can then enter hypervisor mode from the our custom iteration of u-boot and subsequently load our kernel and userspace.

Checkout the needed u-boot code:

$ git clone git://github.com/virtualopensystems/u-boot.git
$ cd u-boot
$ ./scripts/build.sh

If successful, a message about how to copy the bootloader on the USB flash disk or SD card will appear. We will use it later when preparing the boot medium to start our system. If you have followed the [Setting up the boot medium](http://www.virtualopensystems.com/en/solutions/guides/kvm-on-chromebook/#setting-up-the-boot-medium) chapter and you have a prepared boot device, then you can update u-boot by running:

$ sudo dd if=nv_uboot-snow.kpart of=/dev/sdX1

so,I've downloaded the nv_uboot-snow.kpart file from the tutorial and a new sd card and I did :

sudo dd if=nv_uboot-snow.kpart of=/dev/vdg1

but this command destroyed the partition table of the sd card. Do you know why ? I'm doing this experiment because I would like to try to use the unlocked bootloader provided by the virtual open system with the kernel 5.4 to check if it freezes because I've used the wrong u-boot file some days ago.

hexdump0815 commented 2 years ago

you'll have to write the kpart file to the first partition of the disk - i'm not familiar with vdg devices, but maybe its vdg1p1? (after creating a proper partition table of course)

Marietto2008 commented 2 years ago

there is nothing special with /dev/vdg. This is :

Disk /dev/vdg: 3.69 GiB, 3965190144 bytes, 7744512 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x00229c3a

Dispositivo Avvio Start    Fine Settori  Size Id Tipo
/dev/vdg1          2048 7743487 7741440  3.7G  b W95 FAT32

It seems that I did it correctly.

Marietto2008 commented 2 years ago

ok. I've created a gpt partition table and I've formatted the sd card with the ext4 fs and it hasn't been destroyed...

Marietto2008 commented 2 years ago

So,let's say that the real disk where it is installed ubuntu 18.04 running with the kernel 5.4 is the following :


Disk /dev/vdg: 183.35 GiB, 196865949696 bytes, 384503808 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 1476FABD-1E9B-4B8E-B55E-5BD7E8EB66FF

Dispositivo   Start      Fine   Settori   Size Tipo
/dev/vdg1      8192     40959     32768    16M ChromeOS kernel
/dev/vdg2     40960   1089535   1048576   512M Linux filesystem
/dev/vdg3   1089536   5283839   4194304     2G Linux swap
/dev/vdg4   5283840 384499711 379215872 180.8G Linux filesystem

should I do : sudo dd if=nv_uboot-snow.kpart of=/dev/vdg1 ? is that correct ?

Marietto2008 commented 2 years ago

Ok I did that. This is what happened :

index

do you know what's missing ? I see that the bootpart is intact as before :

Screenshot_2022-08-31_12-57-38

Marietto2008 commented 2 years ago

This is the reason of the error,I think :

Screenshot_2022-08-31_13-03-34