[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFxQQsmy0wQrQeFPp_+M=y0qwyH8w3irij7RdcSREdWUzA@mail.gmail.com>
Date: Sat, 12 Mar 2016 17:12:38 -0800
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Ingo Molnar <mingo@...nel.org>
Cc: Tony Luck <tony.luck@...il.com>,
Mika Penttilä <mika.penttila@...tfour.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Thomas Gleixner <tglx@...utronix.de>,
Borislav Petkov <bp@...en8.de>,
Andrew Morton <akpm@...ux-foundation.org>,
Peter Zijlstra <a.p.zijlstra@...llo.nl>,
"H. Peter Anvin" <hpa@...or.com>,
Andy Lutomirski <luto@...capital.net>,
"Williams, Dan J" <dan.j.williams@...el.com>
Subject: Re: [PATCH v14] x86, mce: Add memcpy_mcsafe()
On Sat, Mar 12, 2016 at 9:16 AM, Ingo Molnar <mingo@...nel.org> wrote:
>
> Please use the copy_*_user() memory copying API semantics, which are: return
> negative code (-EFAULT) on error, 0 on success.
Those are the get_user/put_user() semantics.
copy_*_user() has those annoying "bytes left uncopied" return values
that I really wouldn't encourage anybody else use unless they really
have to. There are (good) reasons why it's done that way, but it's
still not something that should be aped without the same kind of major
reasons.
Linus
Powered by blists - more mailing lists