kernel-module Questions

2

Solved

I followed some tutorials that explained how to write Linux kernel modules and I am a bit confused. Even after reading the official "documentation", I have poor understanding of the conce...

3

remap_pfn_range function (used in mmap call in driver) can be used to map kernel memory to user space. How is it done? Can anyone explain precise steps? Kernel Mode is a privileged mode (PM) while ...

3

I currently have my host system running Mac OS with docker. I have my Mac OS host system spawning a docker container. The spawned docker container is currently running ubuntu:19.10 I am trying to...
Hoarding asked 18/6, 2020 at 16:51

4

Solved

I have just made my first driver module, the hello world module following LDD3. However unfortunately encountered this error: insmod: error inserting './hello.ko': -1 Invalid module format. I am...

5

I'm trying to sign some kernel modules (for virtualbox) as explained here. As explained there, I create the new keys: openssl req -new -x509 -newkey rsa:2048 -keyout MOK.priv -outform DER -out MO...
Fluoresce asked 30/8, 2016 at 11:23

4

Solved

Unable to use snd-aloop audio driver in AWS EC2 ubuntu 16.04 instance On running modprobe on snd-aloop $modprobe snd-aloop modprobe: FATAL: Module snd-aloop not found in directory /lib/modules/4....
Bibliotherapy asked 28/3, 2018 at 15:28

4

Solved

I'm writing a loadable kernel module and trying to test it. After inserting it I was trying to remove it using rmmod xxx command, but I get an error saying module xxx is in use and the module gets ...
Sixfooter asked 22/6, 2013 at 14:29

2

Solved

Goal I want to add a touchscreen driver available in the linux kernel source tree to my Yocto image (The link takes you to goodix.c). I basically need to add it as a kernel module. Solution I follo...
Undress asked 22/6, 2021 at 13:25

2

Solved

I'm adding an external driver module to an android Gingerbread kernel (works similar to Linux). I've done it before and it worked but I have a problem this time. I follow the recipe found in O'Reil...
Trow asked 18/10, 2011 at 19:14

3

Solved

I am working in Ubuntu. I am trying to make two kernel modules which uses each other functions. My problem is that I got modules properly compiled, but the symbol is not resolved for one of them. ...
Demythologize asked 15/11, 2015 at 9:51

3

Solved

I copy and paste code from this URL for creating and reading/writing a proc file using a kernel module and get the error that proc_root is undeclared. This same example is on a few sites so I assum...
Jus asked 28/3, 2010 at 2:49

13

Solved

I am having problems getting any kernel modules to build on my machine. Whenever I build a module, modpost always says there are zero modules: MODPOST 0 modules To troubleshoot the problem, I wr...
Brower asked 17/1, 2011 at 16:10

2

Solved

There are many instances of __init calls in kernel both in drivers module_init and other functions of kernel. My doubt is how exactly kernel determines the sequence of the __init call. More importa...
Quarters asked 10/5, 2012 at 18:22

2

Solved

I am trying to compile a module against any source tree on the file system but I am having trouble with the Makefile. This was the original Makefile I had against the kernel specified: obj-m += ne...
Redmon asked 13/3, 2014 at 3:1

3

Solved

I try write simple kernel module (v3.6) in nasm, but insmod say me: $ sudo insmod ./hello.ko insmod: ERROR: could not insert module ./hello.ko: Invalid module format $ echo $? 1 I compile my cod...
Divertimento asked 2/12, 2012 at 10:28

0

I have some proprietary kernel module. And suddenly my system crashed in kdb with such bug: BUG: bad page state in process <kworker_name> pfn:37751 page:<page_address> count:-1 mapcount...

2

Solved

I am using QN9021 SoC working in controller mode (BLE Bluetooth core specification v4.0). It supports some standard HCI commands as well as some vendor specific commands. I am trying to attach it i...
Epiphytotic asked 30/1, 2017 at 20:27

1

Solved

So I'm playing around with reading system registers in the kernel and I've recently run into a bit of a roadblock. In ARM64, certain system registers (e.g. OSECCR_EL1) are not always implemented. ...
Lisp asked 15/4, 2020 at 21:31

2

Solved

I want to convert the source & destination IP addresses from a packet captured using netfilter to char *. In my netfilter hook function, I have: sock_buff = skb; // argument 2 of hook functio...
Jacintojack asked 15/2, 2012 at 16:7

1

Solved

What is wrong with this code (I guess with regard to compatibility with different kernel versions)? #define BUFFER_SIZE 2048 #define BUFFER_STEP 128 static char buffer[BUFFER_SIZE] = { 0 }; // th...
Durward asked 6/3, 2020 at 19:11

3

Solved

I need to compile custom kernel with dvb-t drivers as kernel modules on _rkm mk602_ android device with rk3066 processor. I have downloaded the kernel source for this processor, however I am havi...
Barbule asked 2/3, 2014 at 15:5

1

Solved

I am developing an embedded system with a touchscreen. The touchscreen operates as both input and output, with a "virtual" keyboard overlaying the graphical output. I have a working devic...
Amphipod asked 30/12, 2019 at 18:17

3

Solved

I have a kernel module for splitting incoming rtp packets and merging rtp outgoing packets. The program crashes once in 2/3 days. If would be very convenient for me if its possible to find the exac...
Acidosis asked 1/1, 2014 at 10:59

1

Solved

I am trying to insert a kernel module using depmod and modprobe utilities in-order to resolve any dependencies. When I build the module it throws "Warning: modules_install: missing 'System.map' fil...
Induna asked 16/8, 2019 at 8:12

5

I have a couple of doubts about how the kernel is loaded into memory. Upon inspecting /proc/kallsyms I'm able to find the address of various symbols in the kernel. $ cat /proc/kallsyms | head -n 1...
Sleuthhound asked 7/11, 2015 at 4:1

© 2022 - 2024 — McMap. All rights reserved.