From: Greg KH <greg@kroah.com>
To: Linus Torvalds <torvalds@osdl.org>
Cc: akpm@osdl.org, linux-usb-devel@lists.sourceforge.net,
linux-kernel@vger.kernel.org
Subject: Re: [BK PATCH] USB fixes for 2.6.10-rc3
Date: Thu, 9 Dec 2004 15:57:09 -0800 [thread overview]
Message-ID: <20041209235709.GA8147@kroah.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0412091538510.31040@ppc970.osdl.org>
On Thu, Dec 09, 2004 at 03:41:47PM -0800, Linus Torvalds wrote:
>
>
> On Thu, 9 Dec 2004, Greg KH wrote:
> >
> > Greg Kroah-Hartman:
> > o USB: fix another sparse warning in the USB core
>
> This one looks incorrect.
>
> The code doesn't _fix_ any warnings. It just shuts them up, without fixing
> anything at all.
No, the "fun" problem with this specific field (the wTotalLength one) is
that we initially read them in from the hardware (which for USB is in le
order) and then, in a later function, convert all of the le fields to
native cpu order so that all device drivers don't have to worry about
which fields in the usb structures are in which order.
I tried a while ago to create 2 different versions of the structures,
one in the "on the wire" format, and the other after we had converted
them to native format, but it just got too messy for no real good
reason. I then just put the proper __force markings in the needed
places within the USB core. Here's just a place where I had missed it
before for some reason.
Yeah, it's not the cleanest, and yes, it is just shutting the warning
up, but that's ok in this case. I guess I could look into doing the
"two different structures" type thing again, if people don't like things
like this in different places.
thanks,
greg k-h
next prev parent reply other threads:[~2004-12-09 23:57 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-12-09 23:09 [BK PATCH] USB fixes for 2.6.10-rc3 Greg KH
2004-12-09 23:41 ` Linus Torvalds
2004-12-09 23:57 ` Greg KH [this message]
2004-12-10 0:08 ` Linus Torvalds
2004-12-10 0:19 ` Greg KH
2004-12-10 4:48 ` Benjamin Herrenschmidt
2004-12-11 15:21 ` linjia02
2004-12-10 0:12 ` [linux-usb-devel] " David Brownell
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=20041209235709.GA8147@kroah.com \
--to=greg@kroah.com \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb-devel@lists.sourceforge.net \
--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