mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Alex Belits <abelits@phobos.illtel.denver.co.us>
To: Bosko Radivojevic <bosko.radivojevic@gmail.com>
Cc: lkml <linux-kernel@vger.kernel.org>
Subject: Re: Inserting code from userspace to kernel space
Date: Sat, 24 May 2008 22:44:37 -0700 (PDT)	[thread overview]
Message-ID: <alpine.DEB.1.00.0805242244290.2200@OLPC> (raw)
In-Reply-To: <d6c8ef150805220541v711c5acahc60541e3fd9f44fc@mail.gmail.com>

On Thu, 22 May 2008, Bosko Radivojevic wrote:

> I'm looking for a way to insert code from user space to the kernel
> space, but without using kernel module. Actually, we are working on a
> system that has to allow end user to change part of code (one or two
> functions) that is executed from the kernel space.
>
> For now we have two different kernel modules, one exporting a function
> which another module uses. Process of compiling kernel module is quite
> ineligible for standard end user (along with the requirement to
> support multi platform cross compiling) compared to just cross
> compiling a simple code that doesn't use any libraries than libc.

Why? You don't have to recompile everything, just link a module before 
loaing it -- a part containing the function can be one object file, the 
rest of the module (a wrapper) is compiled once for a particular kernel 
version, and both are linked together, producing a module valid for a 
particular kenel version.

This is how most of proprietary drivers are distributed, and Ubuntu has a 
whole infrastructure around that mechanism that simplifies transition 
between versions.

-- 
Alex

  parent reply	other threads:[~2008-05-25  6:18 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-22 12:41 Bosko Radivojevic
2008-05-22 13:06 ` Jan Engelhardt
2008-05-22 14:31 ` Helge Hafting
2008-05-22 16:04 ` Shuduo Sang
2008-05-25  5:44 ` Alex Belits [this message]
2008-05-25  7:18 ` Bart Van Assche
2008-05-26  6:48 ` Geert Uytterhoeven
2008-05-26  9:54 ` Jike Song
2008-05-23 14:30 devzero
2008-05-25  3:37 ` Shuduo Sang
2008-05-25  3:47   ` David Newall
2008-05-25 15:44     ` Shuduo Sang
2008-05-26  9:44     ` Jiri Kosina
2008-05-26 11:49       ` David Newall
2008-05-25  9:35 devzero
2008-05-25 12:21 ` David Newall
2008-05-25 13:14   ` Tom Spink

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.DEB.1.00.0805242244290.2200@OLPC \
    --to=abelits@phobos.illtel.denver.co.us \
    --cc=bosko.radivojevic@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®