Hot answers tagged

327 votes
Accepted

What is rpikernelhack?

"rpikernelhack" is a fake package name and a directory name used as part of a hack (in the sense of a dirty but expedient solution to a problem) to work around the fact that the Raspberry Pi ...
Peter Green's user avatar
  • 6,406
53 votes

What is rpikernelhack?

It's just the directory name given by the developers who have created a Raspberry Pi specific set of patches to the Linux kernel. It is a fix by the Raspbian developers to fix a FAT file-system ...
Rebroad's user avatar
  • 665
25 votes
Accepted

How compile a loadable kernel module without recompiling kernel

First of all, make sure you use the proper kernel headers. I assume that your kernel headers and source code are more updated than the kernel you're running. Try to do an apt-get update && ...
Aloha's user avatar
  • 7,116
22 votes
Accepted

conflicting dtoverlays

As it turns out several overlays can be loaded by adding multiple dtoverlay variables: In this case: dtoverlay=4dpi-3x dtoverlay=w1-gpio
user1217949's user avatar
16 votes
Accepted

Pending kernel upgrade even after reboot my RPi4

Mixing @Dougie 's comment above and this post: https://www.raspberrypi.org/forums/viewtopic.php?t=270251&p=1639417 the v8 kernel is experimental and should not be used needrestart is confused by ...
Olivier's user avatar
  • 431
14 votes
Accepted

Control GPIO pins from C

sysfs has been deprecated and has been replaced with libgpiod. https://www.beyondlogic.org/an-introduction-to-chardev-gpio-and-libgpiod-on-the-raspberry-pi/ The interactions are with /dev/gpiochipx ...
joan's user avatar
  • 70.5k
13 votes
Accepted

failed to start udev kernel device manager

It might be interesting to know which version you are running, and if you happened to update packages recently. I encountered a similar error message on my raspberry pi2 after upgrading to raspbian ...
EThome's user avatar
  • 146
13 votes

kernel types in Raspbian 10 - Buster

kernel.img is 32-bit for BCM2835 (RPi1 & Zero) kernel7.img is 32-bit for BCM2836 (RPi2) and BCM2837 (RPi3) kernel7l.img is 32-bit for BCM2711 (RPi4) kernel8.img is 64-bit for BCM2837 (RPi3) or ...
Dougie's user avatar
  • 5,261
12 votes
Accepted

How to revert from rpi-update to stable build

"In normal circumstances there is NEVER a need to run rpi-update as it always gets you to the leading edge firmware and kernel and because that may be a testing version it could leave your RPi ...
Milliways's user avatar
  • 58.6k
11 votes
Accepted

iptables: nat table does not exist

Quick guess: You've upgraded the OS and the system has been up for a very long time, or managed to upgrade it without replacing the kernel, because the 4.4.11-v7+ modules have already been removed ...
goldilocks's user avatar
  • 58.5k
9 votes
Accepted

How does the pi know which kernel to load?

All the boot magic is in /boot/config.txt. kernel: The alternative filename on the boot partition to use when loading the kernel; the default value is kernel.img. from official documentation ...
SiKing's user avatar
  • 337
8 votes

How to build My own OS for the raspberry or configure an existing one

to take advantages on the performance This begs the question that the people who put "an existing OS" together were not concerned about performance, or that you understand it better than them (in ...
goldilocks's user avatar
  • 58.5k
8 votes
Accepted

Enable monitoring mode for RTL8188CUS via USB on Raspbian

Turns out the steps to recompile and load the rtlwifi module are correct. The problem is iwconfig not working to enable/determine monitoring mode in this situation. Instead, I used iw as outlined by ...
Matt M's user avatar
  • 331
8 votes
Accepted

Does Raspbian's `/proc/config.gz` contain the running kernel's settings?

Yes; /proc/config.gz, if it exists, always refers to the running kernel's configuration (but see the last few paragraph below) since procfs, like sysfs and devtmpfs, which are used to implement the ...
goldilocks's user avatar
  • 58.5k
8 votes

End kernel panic not syncing cannot allocate swiotlb buffer and cannot provide with dma bouncer buffer

I ran into this same issue with a new install of Pi OS after setting the GPU memory to 896 MB in raspi-config. To fix it without reinstalling: Put the SD card in another computer that can read the &...
Cole P's user avatar
  • 81
7 votes

How compile a loadable kernel module without recompiling kernel

There is a much simpler version here, tested on jessie and stretch. sudo apt-get install raspberrypi-kernel-headers and then when your files are in place : make -C /lib/modules/$(uname -r)/build M=...
pim's user avatar
  • 622
7 votes
Accepted

Raspberry Pi cannot create temp file for here-document: No space left on device

Run the command sudo raspi-config and select the Expand Filesystem option. Then you should be good to go.
Patrick Cook's user avatar
  • 6,365
7 votes

Pi 3 Raspbian "stretch" (testing) disables wifi

The package that provides the Wi-Fi firmware is called firmware-brcm80211. To downgrade this package to a version that works: sudo apt-get install firmware-brcm80211=0.43+rpi5 To prevent this ...
NobodyNada's user avatar
7 votes

failed to start udev kernel device manager

As of systemd 235-2 this still continues with the exact same error. For people landing here from google: If you see that after apt dist-upgrade that either udev, journald or even timesyncd are ...
wadge's user avatar
  • 171
6 votes

Low Energy Consumption Kernel

The kernel already consumes negligible power. The software loaded on the pi would be the ones munching the most power because of processor time (Apache, databases, networking, etc.) Here are some ...
Aloha's user avatar
  • 7,116
6 votes
Accepted

Linux headers generic package not found

I also came across this problem and solved it by following the instructions for a similar question on this forum. However I did need to make some changes. Specifically, I had to run the following ...
Sandro Gauci's user avatar
6 votes

Wireguard "Unknown device type" "Protocol not supported"

According to a comment on r/Wireguard, this error is caused by having the wrong kernel headers: dkms packages (wireguard-dkms this time) need kernel headers for current kernel you have loaded (uname -...
ki9's user avatar
  • 295
5 votes

Cross-compile x86-64 code on Raspberry Pi 2

It is possible to compile x86_64 code on the Raspberry Pi, and i have just built a cross-compile toolchain on my Pi 2 (with more than 27 hrs of compilation and some hours of bug fixing). You can ...
Kong Chun Ho's user avatar
5 votes
Accepted

Essential parts for booting the Raspberry Pi 2

What do I need to sucessfully boot my Raspberry Pi 2 until the init system is loaded? I think I need only the files on the boot partition, because /sbin/init is a symlink to e.g. systemd. /sbin/init ...
goldilocks's user avatar
  • 58.5k
5 votes
Accepted

Recover pi 2 from wrong kernel build?

All the boot files are on a FAT32 sector, which is readable and writeable by all common operating systems. You can place the SD card in an SD card reader, delete the bad kernel, and rename the good ...
joan's user avatar
  • 70.5k
5 votes

Raspberry Pi 1 Model B+ end of life?

The rainbow square is an under-voltage warning. You might consider upgrading to a more powerful power supply (more amps, not more volts). EDIT To further answer your question I have tried to ...
88weighed's user avatar
  • 895
5 votes
Accepted

How can I troubleshoot kernel panics?

Is there a way to view the entire logs...? Your Raspberry Pi typically has a serial console enabled (or can be configured to have a serial console) on one of the built-in UARTs, exposed on GPIO pins ...
larsks's user avatar
  • 656
4 votes

How to change the default governor?

I made a small programm to change it and let it be changed every boot by automatically creating an init.d script. Link to my project
MeisterD's user avatar
4 votes

Where is the kernel source for Raspbian's default 3.1.9+ kernel?

You can use rpi-source to automatically find and install kernel sources for your running kernel. Also see cross compiling from Linux, to avoid waiting for hours to compile your new kernel.
Mauro Lacy's user avatar
4 votes

Cannot Emulate Raspberry Pi using Qemu: Kernel Panic

As @dastaan said, the kernel version needs to match the img file. I was trying to use a 4.1 kernel version image file with a 3.18 kernel. Now that I am using the proper image, it works. Thanks! ...
Mike S's user avatar
  • 327

Only top scored, non community-wiki answers of a minimum length are eligible