From: Benjamin LaHaise <bcrl@kvack.org>
To: "H. Peter Anvin" <hpa@zytor.com>
Cc: Ingo Molnar <mingo@redhat.com>,
Russell King <rmk@arm.linux.org.uk>,
Thomas Gleixner <tglx@linutronix.de>,
x86@kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] x86_32: add support for 64 bit __get_user()
Date: Wed, 9 Mar 2016 13:27:10 -0500 [thread overview]
Message-ID: <20160309182710.GR12913@kvack.org> (raw)
In-Reply-To: <56E069FA.7070700@zytor.com>
On Wed, Mar 09, 2016 at 10:22:50AM -0800, H. Peter Anvin wrote:
> On 03/09/2016 09:50 AM, Benjamin LaHaise wrote:
> > On Wed, Mar 09, 2016 at 09:36:30AM -0800, H. Peter Anvin wrote:
> >> On March 9, 2016 9:22:25 AM PST, Benjamin LaHaise <bcrl@kvack.org> wrote:
> >>> The existing __get_user() implementation does not support fetching
> >>> 64 bit values on 32 bit x86. Implement this in a way that does not
> >>> generate any incorrect warnings as cautioned by Russell King. Test
> >>> code available at http://www.kvack.org/~bcrl/x86_32-get_user.tar .
> > ...
> >> Weird. I could swear we had already fixed this a few years ago.
> >
> > That surprised me as well, but Russell raised the fact that the approaches
> > previously tried on 32 bit architectures had caused various incorrect
> > compiler warnings for certain obscure cases -- see the code in test_module.c
> > in that URL that Russell provided to demonstrate the problem across all the
> > corner cases.
>
> Oh, I see... I implemented it for put but not get... weird. You may
> want to look at the __inttype() macro defined earlier in this file; it
> might be useful.
Ah, interesting. I'll look at that.
> I presume you have already seen:
>
> >> fs/select.c:710: Error: operand type mismatch for `movq'
> >> fs/select.c:714: Error: incorrect register `%cx' used with `q' suffix
> fs/select.c:711: Error: operand type mismatch for `movq'
> >> fs/select.c:715: Error: incorrect register `%si' used with `q' suffix
> --
> fs/aio.c: Assembler messages:
> >> fs/aio.c:1606: Error: operand type mismatch for `movq'
> >> fs/aio.c:1610: Error: incorrect register `%si' used with `q' suffix
>
> ... which implies it used 16-bit registers for 64-bit operations when
> compiling for 64 bits.
Yup, will respin shortly.
-ben
--
"Thought is the essence of where you are now."
next prev parent reply other threads:[~2016-03-09 18:27 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-09 17:22 [PATCH] x86_32: add support for 64 bit __get_user() Benjamin LaHaise
2016-03-09 17:36 ` H. Peter Anvin
2016-03-09 17:50 ` Benjamin LaHaise
2016-03-09 18:22 ` H. Peter Anvin
2016-03-09 18:27 ` Benjamin LaHaise [this message]
2016-03-09 19:30 ` [PATCH] x86_32: add support for 64 bit __get_user() v2 Benjamin LaHaise
2016-03-09 19:41 ` kbuild test robot
2016-03-09 20:05 ` [PATCH] x86_32: add support for 64 bit __get_user() v3 Benjamin LaHaise
2016-03-14 15:37 ` Benjamin LaHaise
2016-03-14 16:39 ` Ingo Molnar
2016-03-09 20:24 ` [PATCH] x86_32: add support for 64 bit __get_user() v2 kbuild test robot
2016-03-09 18:17 ` [PATCH] x86_32: add support for 64 bit __get_user() kbuild test robot
2016-03-09 18:22 ` kbuild test robot
2016-03-09 18:23 ` kbuild test robot
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=20160309182710.GR12913@kvack.org \
--to=bcrl@kvack.org \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=rmk@arm.linux.org.uk \
--cc=tglx@linutronix.de \
--cc=x86@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.