Kernel builds

The SARPi project forum. For anything and everything relating to Slackware ARM on a Raspberry Pi 1, 2, and 3. This forum is NOT a replacement or substitute for the Slackware (ARM) forums on Linux Questions website! Please try to seek help there first about any issues you may be experiencing, or question you might have, before posting on here.
User avatar
linicks
Registered user
Registered user
Posts: 124
Joined: Mon Oct 27 2014 - 20:26:01
Location: Pompey, England

Kernel builds

Postby linicks » Sat Dec 10 2016 - 17:54:41

Well I am blowed.

After all this time, today when looking at updating 'ipset' I found I had to have a kernel version source. Googling revealed this:

https://github.com/notro/rpi-source/wiki

All well and good, except it couldn't find the source for my kernel? The reason (ha hah!) - I didn't have /boot mounted.

OK, got through that hurdle. It does some stuff, and downloads the source and other stuff... (more later on that in another post maybe).

But I noticed after a lot of messing that in /proc config.gz existed! It turns out in the builds that option in the kernel config is set as 'm' (i.e. a module). I looked at my other Pi's, and sure enough 'modprobe configs' sorts it!

I am currently building a raw source from kernel.org using the .config that is now available (that I didn't know was there - that always had me snookered).

Nick
https://linicks.net/

Q. What is the difference between a duck and an elephant?
A. You can't get down off an elephant.

User avatar
Exaga
FatDog Network Administrator
FatDog Network Administrator
Posts: 194
Joined: Wed Apr 18 2012 - 02:01:03
Location: England [UK]

Re: Kernel builds

Postby Exaga » Sat Dec 10 2016 - 21:05:11

If you're looking for the kernel .config ...

Code: Select all

cat /usr/doc/kernel_sarpi3-4.4.35_arm/config


Or if that doesn't exist ...

Code: Select all

explodepkg kernel_sarpi3-4.4.35-armv7-1_slackcurrent_fd0.txz
cd usr/doc/kernel_sarpi3-4.4.35_arm/
cat config


;)
Exaga

====
__ KEEP THE DOG ALIVE!!!
()'`; /
/\|` W00f W00f W00f
www.fatdog.eu

User avatar
linicks
Registered user
Registered user
Posts: 124
Joined: Mon Oct 27 2014 - 20:26:01
Location: Pompey, England

Re: Kernel builds

Postby linicks » Sun Dec 11 2016 - 12:03:19

No, what I meant was there is a kernel build option that adds the running kernel config in /proc (/proc/config.gz). I never understood why the ARM kernel guys didn't use it, until now I see it is compiled as a module. So 'modprobe configs' loads it.

The /proc/config.gz file will always be the right one for your running kernel - those other files may not be.

Nick
https://linicks.net/

Q. What is the difference between a duck and an elephant?
A. You can't get down off an elephant.

User avatar
glorsplitz
Registered user
Registered user
Posts: 35
Joined: Sun Aug 07 2016 - 22:54:24

Re: Kernel builds

Postby glorsplitz » Sun Dec 11 2016 - 19:38:31

I'm trying to understand srpi/rpi_update kernel stuff, I don't know if this related to what linicks is talking about but I looked at what Exaga said
/usr/doc/kernel and I see
kernel-firmware-20161001git/ kernel_sarpi3-4.4.21_arm/
with /usr/doc/kernel_sarpi3-4.4.21_arm/config

I'm doing what linicks pointed out to me PRUNE_MODULES=1 rpi-update, which works great, thanks linicks.
so uname -a says:
Linux slackrpi 4.4.37-v7+ #936 SMP Fri Dec 9 16:56:49 GMT 2016 armv7l BCM2709 GNU/Linux
I looked maybe not hard enough, where is config for running kernel? I don't seem to have /proc/config.gz.

Thanks

User avatar
Exaga
FatDog Network Administrator
FatDog Network Administrator
Posts: 194
Joined: Wed Apr 18 2012 - 02:01:03
Location: England [UK]

Re: Kernel builds

Postby Exaga » Mon Dec 12 2016 - 01:24:42

linicks wrote:The /proc/config.gz file will always be the right one for your running kernel - those other files may not be.


Sorry mate, I can only account for SARPi kernels. I get what you're saying about /proc/config.gz though. :D

Might be an idea to "CONFIG_IKCONFIG=y" in future builds because I've had a few questions about the current kernel .config lately. :think:
Exaga

====
__ KEEP THE DOG ALIVE!!!
()'`; /
/\|` W00f W00f W00f
www.fatdog.eu

User avatar
Exaga
FatDog Network Administrator
FatDog Network Administrator
Posts: 194
Joined: Wed Apr 18 2012 - 02:01:03
Location: England [UK]

Re: Kernel builds

Postby Exaga » Mon Dec 12 2016 - 01:26:11

glorsplitz wrote:I'm trying to understand srpi/rpi_update kernel stuff, I don't know if this related to what linicks is talking about but I looked at what Exaga said
/usr/doc/kernel and I see
kernel-firmware-20161001git/ kernel_sarpi3-4.4.21_arm/
with /usr/doc/kernel_sarpi3-4.4.21_arm/config

I'm doing what linicks pointed out to me PRUNE_MODULES=1 rpi-update, which works great, thanks linicks.
so uname -a says:
Linux slackrpi 4.4.37-v7+ #936 SMP Fri Dec 9 16:56:49 GMT 2016 armv7l BCM2709 GNU/Linux
I looked maybe not hard enough, where is config for running kernel? I don't seem to have /proc/config.gz.

Thanks


linicks wrote:No, what I meant was there is a kernel build option that adds the running kernel config in /proc (/proc/config.gz). I never understood why the ARM kernel guys didn't use it, until now I see it is compiled as a module. So 'modprobe configs' loads it.


@glorsplitz: What Nick said. lol

Try this...

~# modprobe configs
~# zcat /proc/config.gz
Exaga

====
__ KEEP THE DOG ALIVE!!!
()'`; /
/\|` W00f W00f W00f
www.fatdog.eu

User avatar
glorsplitz
Registered user
Registered user
Posts: 35
Joined: Sun Aug 07 2016 - 22:54:24

Re: Kernel builds

Postby glorsplitz » Mon Dec 12 2016 - 03:28:25

@Exaga Thanks! yea what Nick said LOL! that all slipped right by me

zcat /proc/config.gz
# Automatically generated file; DO NOT EDIT.
# Linux/arm 4.4.37 Kernel Configuration

User avatar
Exaga
FatDog Network Administrator
FatDog Network Administrator
Posts: 194
Joined: Wed Apr 18 2012 - 02:01:03
Location: England [UK]

Re: Kernel builds

Postby Exaga » Mon Dec 12 2016 - 20:01:32

glorsplitz wrote:@Exaga Thanks! yea what Nick said LOL! that all slipped right by me

zcat /proc/config.gz
# Automatically generated file; DO NOT EDIT.
# Linux/arm 4.4.37 Kernel Configuration


No problem, glorslitz. I'm going to save all of you the trouble in future. From this day forward all SARPi installers will include /proc/config.gz by default. As Nick indirectly pointed out, why it isn't enabled when you make "bcmrpi_defconfig" or "bcm2709_defconfig" from the RPi kernel source is only making things more difficult for end users. I've always had my reasons for not making it happen in the past, but now there's a few of you wanting access to that file. So, there's good reason for doing it.
Exaga

====
__ KEEP THE DOG ALIVE!!!
()'`; /
/\|` W00f W00f W00f
www.fatdog.eu

Return to “SARPi Project - Slackware ARM on a Raspberry Pi”

Who is online

Users browsing this forum: CommonCrawl [Bot] and 0 guests