Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I load a kernel driver at a specific memory address?

How could it be done with the following methods?

  1. commands/scripts like insmod or modprobe
  2. using C code (not sure if there may exist such an option)
share|improve this question
You can't. Why do you want to do that anyway? – Gilles Jan 9 '14 at 22:48
Not sure who put a -1 to that question. Customer wants that, there are controlled details to the project, it may be military, so we are not allowed to ask further on the criteria. – Ursa Major Jan 9 '14 at 23:22

You can't load a kernel module at a specific physical address. You can't load a kernel module at a specific virtual address. The kernel decides where it loads the module.

Inside the kernel, of course, you can do what you want. But I think arranging to load a driver at a specific address would require a lot of deep changes.

I fail to see what would require loading a driver at a specific physical or virtual address. Devices may need to be mapped at specific physical addresses (and there are mechanisms for that), but code doesn't care.

share|improve this answer
yes, the base kernel may be able to do something about the loading process of the loadable kernel modules (LKM), however, we are not allow to touch that. I wonder why they set the game like this. You are not going anywhere without a +1 for you, @Gilles. :) – Ursa Major Jan 10 '14 at 18:44

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.