* Type checking for write_pda()
@ 2006-09-01 1:37 Jeremy Fitzhardinge
2006-09-01 7:56 ` Andi Kleen
0 siblings, 1 reply; 2+ messages in thread
From: Jeremy Fitzhardinge @ 2006-09-01 1:37 UTC (permalink / raw)
To: Andi Kleen; +Cc: Linux Kernel Mailing List
I just added type checking for assignments the PDA in the i386 PDA code.
Here's the x86-64 equivalent. (Obviously this doesn't contain the latest
x86-64 PDA change.)
Signed-off-by: Jeremy Fitzhardinge <jeremy@goop.org>
diff -r 77945c3646ac include/asm-x86_64/pda.h
--- a/include/asm-x86_64/pda.h Thu Aug 31 18:30:26 2006 -0700
+++ b/include/asm-x86_64/pda.h Thu Aug 31 18:34:49 2006 -0700
@@ -47,6 +47,7 @@ extern void __bad_pda_field(void);
#define pda_to_op(op,field,val) do { \
typedef typeof_field(struct x8664_pda, field) T__; \
+ if (0) { T__ tmp__; tmp__ = (val); } \
switch (sizeof_field(struct x8664_pda, field)) { \
case 2: \
asm volatile(op "w %0,%%gs:%P1"::"ri" ((T__)val),"i"(pda_offset(field)):"memory"); break; \
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Type checking for write_pda()
2006-09-01 1:37 Type checking for write_pda() Jeremy Fitzhardinge
@ 2006-09-01 7:56 ` Andi Kleen
0 siblings, 0 replies; 2+ messages in thread
From: Andi Kleen @ 2006-09-01 7:56 UTC (permalink / raw)
To: Jeremy Fitzhardinge; +Cc: Linux Kernel Mailing List
On Friday 01 September 2006 03:37, Jeremy Fitzhardinge wrote:
> I just added type checking for assignments the PDA in the i386 PDA code.
> Here's the x86-64 equivalent. (Obviously this doesn't contain the latest
> x86-64 PDA change.)
Added thanks
-Andi
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2006-09-01 8:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-01 1:37 Type checking for write_pda() Jeremy Fitzhardinge
2006-09-01 7:56 ` Andi Kleen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox