[PATCH] x86/uaccess: Avoid barrier_nospec() in copy_from_user()
Linus Torvalds
torvalds at linux-foundation.org
Sat Oct 26 03:35:30 AEDT 2024
On Fri, 25 Oct 2024 at 01:56, David Laight <David.Laight at aculab.com> wrote:
>
> > > Especially if there is always a (PAGE sized) gap between the highest
> > > user address and the lowest kernel address so the 'size' argument
> > > to access_ok() can be ignored on the assumption that the accesses
> > > are (reasonably) linear.
> >
> > Yes, that's what we do right now for the inline code generation anyway.
>
> Is that gap there on all architectures?
All of the address checks are architecture-specific, so this page-size
gap is purely about x86-64.
Linus
More information about the Linuxppc-dev
mailing list