[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <45FD619D.6030402@goop.org>
Date: Sun, 18 Mar 2007 08:58:21 -0700
From: Jeremy Fitzhardinge <jeremy@...p.org>
To: Andi Kleen <ak@....de>
CC: David Miller <davem@...emloft.net>, rusty@...tcorp.com.au,
mingo@...e.hu, akpm@...ux-foundation.org,
linux-kernel@...r.kernel.org, virtualization@...ts.osdl.org,
xen-devel@...ts.xensource.com, chrisw@...s-sol.org,
zach@...are.com, anthony@...emonkey.ws,
torvalds@...ux-foundation.org, netdev@...r.kernel.org
Subject: Re: [patch 13/26] Xen-paravirt_ops: Consistently wrap paravirt ops
callsites to make them patchable
Andi Kleen wrote:
>> The idea is _NOT_ that you go look for references to the paravirt_ops
>> members structure, that would be stupid and you wouldn't be able to
>> use the most efficient addressing mode on a given cpu, you'd be
>> patching up indirect calls and crap like that. Just say no...
>>
>
> That wouldn't handle inlines though. At least some of the current
> paravirtops like cli/sti are critical enough to require inlining.
>
You could special-case it in the thing handling the relocs; if you're
relocating to point to a function which you have an inline substitution,
then inline.
The bigger problem is that you don't know what registers you can
clobber. For the pv_ops in hand-written asm, that a big pain. The code
either has to assume the worst, or the "relocator" has to do something
more sophisticated (like look for push/pop pairs surrounding the call,
perhaps?).
J
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists