From: Andi Kleen <ak@muc.de>
To: Jeremy Fitzhardinge <jeremy@goop.org>
Cc: Andrew Morton <akpm@osdl.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] i386-pda updates
Date: 9 Sep 2006 17:52:57 +0200
Date: Sat, 9 Sep 2006 17:52:57 +0200 [thread overview]
Message-ID: <20060909155257.GA50136@muc.de> (raw)
In-Reply-To: <45027822.2010906@goop.org>
On Sat, Sep 09, 2006 at 01:15:30AM -0700, Jeremy Fitzhardinge wrote:
>
> -/* Make sure %gs it initialized properly in idle threads */
> +/* Make sure %gs is initialized properly in idle threads */
Merged
> };
> @@ -20,7 +22,14 @@ extern struct i386_pda _proxy_pda;
> #define pda_to_op(op,field,val) \
> do { \
> typedef typeof(_proxy_pda.field) T__; \
> + if (0) { T__ tmp__; tmp__ = (val); } \
Merged into original patch
> switch (sizeof(_proxy_pda.field)) { \
> + case 1: \
> + asm(op "b %1,%%gs:%c2" \
> + : "+m" (_proxy_pda.field) \
> + :"ri" ((T__)val), \
> + "i"(pda_offset(field))); \
> + break; \
> case 2: \
> asm(op "w %1,%%gs:%c2" \
> : "+m" (_proxy_pda.field) \
> @@ -41,6 +50,12 @@ extern struct i386_pda _proxy_pda;
> ({ \
> typeof(_proxy_pda.field) ret__; \
> switch (sizeof(_proxy_pda.field)) { \
> + case 1: \
> + asm(op "b %%gs:%c1,%0" \
> + : "=r" (ret__) \
> + : "i" (pda_offset(field)), \
> + "m" (_proxy_pda.field)); \
> + break; \
> case 2: \
> asm(op "w %%gs:%c1,%0" \
> : "=r" (ret__) \
> @@ -57,6 +72,10 @@ extern struct i386_pda _proxy_pda;
> } \
> ret__; })
>
> +/* Return a pointer to a pda field */
> +#define pda_addr(field) \
> + ((typeof(_proxy_pda.field) *)((unsigned char *)read_pda(_pda) + \
> + pda_offset(field)))
I think i would prefer to merge that and the 1 byte one only
with actual users (x86-64 hasn't needed either for a long time)
-Andi
next prev parent reply other threads:[~2006-09-09 15:53 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-09-09 8:15 [PATCH] i386-pda updates Jeremy Fitzhardinge
2006-09-09 15:52 ` Andi Kleen [this message]
2006-09-09 23:07 ` Jeremy Fitzhardinge
2006-09-09 23:30 ` Jeremy Fitzhardinge
2006-09-10 6:18 ` Andi Kleen
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=20060909155257.GA50136@muc.de \
--to=ak@muc.de \
--cc=akpm@osdl.org \
--cc=jeremy@goop.org \
--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