From: Jamie Lokier <jamie@shareable.org>
To: Andi Kleen <ak@suse.de>
Cc: Linus Torvalds <torvalds@osdl.org>,
Nick Piggin <piggin@cyberone.com.au>,
Andrew Morton <akpm@osdl.org>,
linux-kernel@vger.kernel.org, richard.brunner@amd.com
Subject: Re: [PATCH] Athlon/Opteron Prefetch Fix for 2.6.0test5 + numbers
Date: Thu, 18 Sep 2003 16:38:31 +0100 [thread overview]
Message-ID: <20030918153831.GA7548@mail.jlokier.co.uk> (raw)
In-Reply-To: <20030917211200.GA5997@wotan.suse.de>
Andi Kleen wrote:
> I added a check for LDT entries now. This means prefetch exceptions
> inside non standard code segments will be not handled (I will fix
> that in a follow up patch)
> + /* Don't check for LDT code segments because they could have
> + non zero bases. Better would be to add in the base in this case. */
> + if (regs->xcs & (1<<2))
> + return 0;
It is possible to have a non-standard code segment in the GDT, too.
Thus a better to check is "unlikely((regs->xcs & 0xffff) != __USER_CS)".
One way to add in the correct base would be to use the real segment
register. Don't call __get_user: call your own special function which
uses %gs, and temporarily load regs->xcs into %gs.
Alternatively you can just calculate the base and add it.
-- Jamie
next prev parent reply other threads:[~2003-09-18 15:39 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-09-17 2:22 [PATCH] Athlon/Opteron Prefetch Fix for 2.6.0test5 + numbers Andi Kleen
2003-09-17 2:44 ` Andrew Morton
2003-09-17 3:25 ` Andi Kleen
2003-09-17 4:53 ` Nick Piggin
2003-09-17 5:08 ` Andrew Morton
2003-09-17 5:19 ` Nick Piggin
2003-09-17 7:15 ` Dave Hansen
2003-09-17 5:26 ` Andi Kleen
2003-09-17 5:44 ` Nick Piggin
2003-09-17 19:53 ` Linus Torvalds
2003-09-17 20:21 ` Andi Kleen
2003-09-17 20:50 ` Linus Torvalds
2003-09-17 21:12 ` Andi Kleen
2003-09-18 15:38 ` Jamie Lokier [this message]
2003-09-18 16:04 ` Jamie Lokier
2003-09-18 17:06 ` Andi Kleen
2003-09-18 19:48 ` Jamie Lokier
2003-09-19 6:55 ` Kai Henningsen
2003-09-19 10:02 ` Andreas Schwab
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=20030918153831.GA7548@mail.jlokier.co.uk \
--to=jamie@shareable.org \
--cc=ak@suse.de \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=piggin@cyberone.com.au \
--cc=richard.brunner@amd.com \
--cc=torvalds@osdl.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