kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
From: greg@kroah.com (Greg KH)
To: kernelnewbies@lists.kernelnewbies.org
Subject: EXPORT_SYMBOL and rebinding functions
Date: Mon, 2 Jun 2014 20:57:46 -0700	[thread overview]
Message-ID: <20140603035746.GC13130@kroah.com> (raw)
In-Reply-To: <1401766156.2748.6.camel@mwynne-laptop>

On Mon, Jun 02, 2014 at 08:29:16PM -0700, Peter Tosh wrote:
> Hey guys,
> 
> I have a module which defines a specific print function, and another
> module that uses said function. From the first module I have used
> EXPORT_SYMBOL(function_1). From within the second module I would like to
> rebind that function to another printing function, and once I'm
> finished, rebind it back to the original function.

Wait, why?

Don't have modules messing with the function pointers of other modules,
that way lies madness.

Or root kits, which honestly, there are better ways of making money if
you have Linux kernel skills.

don't do this.

greg k-h

  reply	other threads:[~2014-06-03  3:57 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-03  3:29 EXPORT_SYMBOL and rebinding functions Peter Tosh
2014-06-03  3:57 ` Greg KH [this message]
2014-06-03  4:19   ` Peter Tosh
2014-06-03  4:47     ` Greg KH
2014-06-03  5:10       ` Peter Tosh
2014-06-03  5:21         ` Greg KH
2014-06-03  8:57           ` AYAN KUMAR HALDER
2014-06-03 13:03 ` Valdis.Kletnieks at vt.edu

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=20140603035746.GC13130@kroah.com \
    --to=greg@kroah.com \
    --cc=kernelnewbies@lists.kernelnewbies.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;
as well as URLs for NNTP newsgroup(s).