Problem with compiling ayufans linux kernel
Hi all

I tried to compile the ayufans kernel for the rockpro64 directly on the rockpro64 itself and on my x86 workstation. But in both cases I get a similar error:
In function 'hid_report_readreg.constprop',
   inlined from 'rkvr_dev_attr_debug_show' at drivers/hid/hid-rkvr.c:826:7:
drivers/hid/hid-rkvr.c:780:3: warning: 'memcpy' forming offset 2 is out of the bounds [0, 1] of object 'mpu6500_id' with type 'u8' {aka 'unsigned char'} [-Warray-bounds]
error, forbidden warning:hid-rkvr.c:780
  memcpy(data, &buf[1], readlen);
drivers/hid/hid-rkvr.c: In function 'rkvr_dev_attr_debug_show':
drivers/hid/hid-rkvr.c:822:5: note: 'mpu6500_id' declared here
 u8 mpu6500_id = 0;
make[2]: *** [scripts/ drivers/hid/hid-rkvr.o] Error 1
make[1]: *** [scripts/ drivers/hid] Error 2
make[1]: *** Waiting for unfinished jobs...

I got the source code from here and I used the branch release-4.4.190 which corresponds with the kernel running on my rockpro64. I used the config from arch/arm64/configs/rockchip_linux_defconfig.

I installed some packages on my workstation for cross compiling and tried to build the kernel with the following command, but I get the error from above.
make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- -j24 Image

I'm able to successfully build the current mainline kernel with this command, but I haven't tried to boot from it. Because I could't cross compile the kernel from ayufan, I tried to compile it on my rockpro64, which is running the buster-minimal Image from ayufan. I installed the following packages on it.
build-essential libncurses-dev bison flex libssl-dev fakeroot pkg-config python

And used this command to compile it, but I get a similar error message as above.
make -j6 Image

If anybody has an idea what is wrong with my setup or knows a guide on how to compile this kernel, I would be glad about an answer.

Thanks in advance

Messages In This Thread
Problem with compiling ayufans linux kernel - by voegelit - 12-31-2019, 01:48 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  RockPro64 linux console video mode callegar 0 63 09-06-2022, 02:32 PM
Last Post: callegar
Sad Problem with DD Re1L 2 385 07-24-2022, 04:27 AM
Last Post: CounterPillow
  [OS] SkiffOS and Buildroot for Rockpro64 w/ 5.17 kernel paralin1 1 638 05-08-2022, 03:26 PM
Last Post: paralin1
Brick Maintained Linux booting from eMMC ootoovak 10 3,886 04-30-2022, 03:57 PM
Last Post: TRS-80
  Kernel OOPs triggered by big writes to ext4 FS ajtravis 1 530 04-04-2022, 05:29 PM
Last Post: ajtravis
  How I Got Fedora Linux to Boot From eMMC (or microSD, for that matter) whitecat23 4 1,566 01-03-2022, 10:32 AM
Last Post: whitecat23
  Manjaro ARM - Built-in ethernet was broken with kernel 5.14.1-1 (over now) Dendrocalamus64 2 1,211 09-11-2021, 08:58 PM
Last Post: t4_4t
  Compiling ayufan mainline - DT-overlay missing Mentaluproar 0 861 07-24-2021, 09:46 PM
Last Post: Mentaluproar
  compiling a new kernel for overclocking on arch Mentaluproar 2 1,574 07-15-2021, 10:16 AM
Last Post: Mentaluproar
  Other boot options than Sdcard for linux 5.x kernel? MisterA 2 1,672 07-14-2021, 02:37 PM
Last Post: TRS-80

Forum Jump:

Users browsing this thread: 1 Guest(s)