mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@osdl.org>
To: FabF <fabian.frederick@skynet.be>
Cc: viro@parcelfarce.linux.theplanet.co.uk, linux-kernel@vger.kernel.org
Subject: Re: [2.6.7-rc1-mm1] lp int copy_to_user replaced
Date: Thu, 27 May 2004 12:01:07 -0700	[thread overview]
Message-ID: <20040527120107.2d61a9f5.akpm@osdl.org> (raw)
In-Reply-To: <1085681215.2070.27.camel@localhost.localdomain>

FabF <fabian.frederick@skynet.be> wrote:
>
>  On Thu, 2004-05-27 at 20:01, viro@parcelfarce.linux.theplanet.co.uk
>  wrote:
>  > On Thu, May 27, 2004 at 07:32:08PM +0200, FabF wrote:
>  > > Andrew,
>  > > 
>  > > 	Here's a patch to have standard __put_user for integer transfers in lp
>  > > driver.Is it correct ?
>  > 
>  > What the hell for?  copy_to_user()/copy_from_user() is perfectly OK here.
>  > 
>  And why the hell use generic functions when we have neat small type
>  exchange macros ?

copy_*_user() has special-case code to handle 1, 2 and 4-byte copies, so
your patch should make no difference on x86.  Other architectures do not
have that optimisation.

So the patch is a tiny optimisation for some architectures.  However, it's
of very small benefit - we could make a million such changes.  Would prefer
more substantial things at this time, please.

  parent reply	other threads:[~2004-05-27 19:01 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-27 17:32 FabF
2004-05-27 17:39 ` Arjan van de Ven
2004-05-27 17:45   ` FabF
2004-05-27 17:43 ` Chris Wright
2004-05-27 18:01 ` viro
2004-05-27 18:06   ` FabF
2004-05-27 18:13     ` viro
2004-05-27 19:01     ` Andrew Morton [this message]
2004-05-27 18:15   ` Davide Libenzi

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=20040527120107.2d61a9f5.akpm@osdl.org \
    --to=akpm@osdl.org \
    --cc=fabian.frederick@skynet.be \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@parcelfarce.linux.theplanet.co.uk \
    /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

all inboxes | Powered by JetHome®