Generic Linux architectural discussions
 help / color / mirror / Atom feed
From: Sam Ravnborg <sam@ravnborg.org>
To: linux arch <linux-arch@vger.kernel.org>
Cc: "David S. Miller" <davem@davemloft.net>
Subject: Do we use runtime patching of function calls somewhere?
Date: Sun, 13 May 2012 14:16:00 +0200	[thread overview]
Message-ID: <20120513121600.GA15708@merkur.ravnborg.org> (raw)

Do we have any archs that does runtime patching of function calls?

On sparc32 we have infrastructure to do so but this
requires an additional step after the final link
that I like to get rid of.

Basically what is required is to locate all
call-sites that for example call:

     cache_flush_all();

and replace this with a

    srmmu_cache_flush_all();

sparc32 has ~30 calls that is eligble for runtime patching.
sparc-next has seen some nice cleanup in this area,
so your regular kernel has much more.

We know early on the what to patch with as the only
paramters involved are platform and MMU type.

I could try to come up with something myself - but if we already
have it somewhere maybe there is something to be inspired by.

	Sam

             reply	other threads:[~2012-05-13 12:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-13 12:16 Sam Ravnborg [this message]
2012-05-13 14:29 ` Do we use runtime patching of function calls somewhere? Matthew Wilcox
2012-05-13 18:28   ` David Miller
2012-05-13 17:44 ` Mike Frysinger
2012-05-13 18:32 ` David Miller
2012-05-13 18:45   ` Sam Ravnborg
2012-05-13 20:01     ` David Miller
2012-05-14 16:56 ` Sam Ravnborg

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=20120513121600.GA15708@merkur.ravnborg.org \
    --to=sam@ravnborg.org \
    --cc=davem@davemloft.net \
    --cc=linux-arch@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