Jump to content

Problem getting correct version of kernel headers


Recommended Posts

Hi all, 

 

First place, sorry if it´s a very basic question, I was searching info and reading topics, but I did not found a solution for my problem.

I`m working with Linux version 5.4.29-sunxi

 

I´m trying to compile my own char device driver. I noticed that I forgot adding kernel-headers in my build, so I tried to add them via

 

apt install linux-headers-next-sunxi


After that, I can see a new directory 

 

/usr/src/linux-headers-4.19.62-sunxi


but if I´m not wrong, modules compiled with this headers won´t work in my kernel, cause headers version does not match with my kernel version.

 

So, could please someone give me a hint about getting correct header version, or if I´m completelly wrong?

 

Many thanks in advances

 

Grettings

 

Mariano

Link to comment
Share on other sites

"next" does not exist anymore. It has been replaced with "current".

But regardless you can use armbian-config to install kernel headers

Link to comment
Share on other sites

Werner, kernel header update worked like a charm. I tried both ways

 

  • armbian-config -> Software -> Headers_install
  • apt install linux-headers-current-sunxi

So, I´m wondering if there is a way to just install headers that match current target´s kernel version if kernel version is not the last stable.

 

In my case, after installing headers I had to upgrade kernel to 5.4.35, no problem at all, but I guess sometimes we might want to keep kernel version unchanged.

 

One more time, thank you very much!

 

Link to comment
Share on other sites

14 minutes ago, mhc said:

if kernel version is not the last stable.


No, we don't have all older matched kernels and headers. 

 

We started to pay attention recently, after headers and DKMS process were improved ... and we are working on to improve CI processes. In case you have know-how and some time, you are welcome to help. We are drowning in work. https://armbian.atlassian.net/projects/AR/issues/AR-214

Link to comment
Share on other sites

Hi Igor, thank you very much for your answer.

 

I understand that you contribute by using time you could spend on other things, and I am completely grateful for that. 

 

I will help if I found something that " know how" from your link

 

Greetings

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines