Questions tagged [insmod]

insmod tries to link a module into the running kernel by resolving all symbols from the kernel's exported symbol table.

81 questions
0
votes
1 answer

why module_param_hw( ) macro is more secure than module_param( )?

I'm starting to learn kernel modules programming. To pass any parameter to the kernel module you use module_param( ) macro which i guess work something like dynamic linking method in user space (deffer symbols relocation to run time by kernel…
KMG
  • 1,433
  • 1
  • 8
  • 19
0
votes
0 answers

accidentally removed kernel module and don't know how to re enable

i recently had a issue that decreases my internet speed someone told me that i should use a proper driver so i saw a github page where they told to run this command modprobe -r b43 and more b43 in the line means my wifi driver so after that i didn't…
Clerick X
  • 1
  • 2
0
votes
0 answers

insmod error, invalid module format on debian 9.5

i have an original module in debian 10 on a beaglebone black and now i am running it on debian 9.5 with a different kernel. So when i try to insert the module i get this error: insmod: ERROR: could not insert module gpio_test.ko: Invalid module…
0
votes
1 answer

modprobe/insmod - ERROR: could not insert module Operation not permitted installing a kernel space module with root privileges

So, I was trying to install a hello world kernel shown the book "Linux Device Drivers" by Corbet, Jonathan. This is the code for the file hello.c #include #include MODULE_LICENSE("Dual BSD/GPL"); static int…
Werem
  • 534
  • 2
  • 5
  • 16
0
votes
1 answer

insmod fails with “Unknown symbol in module”

I am working on Linuxmint Cinnamon 19 Ubuntu 18.04, kernel version 4.15.0-20-generic The following I see during compilation: make make -C /lib/modules/`uname -r`/build SUBDIRS=/home/lukas/Desktop/COP4610-Operating-Systems-Project-2-master/elevator…
Lukas
  • 3
  • 1
  • 4
0
votes
1 answer

Problem running "Hello World" linux module

I'm trying to compile and run a "Hello World" module from the book "Linux Device Drivers" the program ~/ldd3/hello.c I'm trying to compile is: /* * $Id: hello.c,v 1.5 2004/10/26 03:32:21 corbet…
korppu73
  • 237
  • 1
  • 2
  • 5
0
votes
0 answers

Can we add an entry to /proc/kallsyms?

I wanted to add a function lets say foo to my program my_pgm.c. I used it by extern foo(); When I run Makefile to run my_pgm.c it went fine, but as it is not there in /proc/kallsym while doing insmod my_pgm.ko it throws errror. insmod: ERROR: could…
satyaGolladi
  • 180
  • 13
0
votes
1 answer

insmod: 'error ... invalid module format' - cross compilation usage

I would like to solve this error which occurred, apparently, when updating and building a Kernel and using a previous Linux Device Driver Module (I changed one or two parameter setting to the kernel, compiled and built and get new Kernel image, for…
Itzik Chaimov
  • 89
  • 1
  • 10
0
votes
1 answer

Linux keyboard delay

So I want to build a kernel module (I suppose) which would insert little delay after a keyboard key is pressed (let's say 500ms). I managed to do this in Windows through hooks, but it seems to be different in Linux. Note that I do not wish to use…
dclaudiud
  • 324
  • 3
  • 10
0
votes
1 answer

insmod custom module fails with message : disagrees about version of symbol

I want to make a netfilter conntrack module for myself. So I copy all the source code about netfilter conntrack from kernel source tree to my external directory. It can be insmod after compiled. Then I add some members to the struct nf_conn, and it…
river
  • 694
  • 6
  • 22
0
votes
1 answer

kernel module insertion issue

We are running the latest raspibian on the raspberry pi board and have a kernel driver for a USB peripheral which is added externally (sudo insmod driverx.ko) after boot-up by connecting to the hardware using ssh (its a headless system). The…
0
votes
1 answer

Linux Kernel minor number vermagic comparison

I have a simple question about modules in the linux kernel. Is it guaranteed that my compiled module works throughout the whole X.Y kernel release. X: Kernel version Y: Major version Z: Minor version So for example: I compile my module.ko with the…
Appyx
  • 1,145
  • 1
  • 12
  • 21
0
votes
1 answer

Linux Driver -> insmod -> lsmod showing the driver, but no entry in /dev?

just making my first steps in Linux Driver creation. Got this finally working: #include #include #include #include #define DRIVER_AUTHOR "DirtyDiddy" #define DRIVER_DESC "Ein…
0
votes
1 answer

insmod: ERROR: could not insert module kprobe_example.ko: Operation not permitted

I was referring: http://www-users.cs.umn.edu/~boutcher/kprobes/kprobes.txt.html to understand kprobe. I used kprobe_example.c as given in the doc. I compiled it using the makefile (code taken from the same document) I got compilation errors because…
flyingunicorn
  • 26
  • 2
  • 7
0
votes
0 answers

Network hooks hanging the system

I was testing the network hook code given in https://en.wikipedia.org/wiki/Hooking . My kernel version is 3.11. #include #include #include #include #include #include…
BusyTraveller
  • 183
  • 3
  • 14