I'm trying to find the kernel address space where my loadable kernel module is relocated by insmod.
I came to know that by using the -m, -O switches while insmod'ing the module, we can only see the symbol table and the executable's sections' addresses from the view-point of the module and not their relocated addresses, as that process of relocation is carried out when we do an insmod.
Can anyone
I've attempted to install drivers for an FPGA device, but require that I remove the usbserial module. This happens to be impossible because usbserial is a built-in module. It was suggested that I compile a new kernel to make usbserial dynamically loadable and unloadable.
I'm now trying to compile a custom kernel w/ Fedora.
LunaVorax wrote:Why in the world can't this be simple?I actually tried what I posted before to make sure it works...But I can't really read the errors you posted since I don't speak that language...
This is the first in a series of articles aimed at the beginning kernel programmer, designed to lead the kernel newbie through the basics of writing and compiling their first kernel module, and getting increasingly sophisticated from there.
I've built a kernel with loadable module support for various reasons, one of them the possibility to compile modules and load them without rebooting. This is supposed to be useful when I need a module that I had not enabled in the kernel config.
Now, with drivers like nouveau, it's as easy as going to the source directory, and running make M=drivers/gpu/drm/nouveau.
Assuming that i have Loadable-Kernel-Module inserted in linux-kernel and have hooked read, write, open and close functions. So now i can stop access to any file but i want to stop files from being copied outside the device like to a usb device, card, disk etc.
I am facing an issue in trying to load an LKM into the RedHat kernel using insmod, but it returns me the following error:-
Insmod –f tmdq.o
tmdq.o: unresolved symbol sleep
Why should sleep() system call from within the LKM cause an issue?
my server system is low on disk. To install a new kernel I think i shall do the following:
1. compile the kernel on another system.
2. copy bzImage along with config, System.map and of course the laodable module in /lib/modules and transfer them to the server.
3.
I'm writing a Loadable Kernel Module for Linux that overwrites data in the memory address of another process. I want to overwrite a 4-byte integer.
Upon looking at ptrace(), I noticed a function named copy_from_user which, according to some documentation I found, seemed to fit the bill. However, when I try to load the module into the kernel (for a specific PID and address), it crashes.