From: Roland Dreier <roland@topspin.com>
To: Oliver Neukum <Oliver.Neukum@lrz.uni-muenchen.de>
Cc: linuxppc-embedded@lists.linuxppc.org,
linux-usb-devel@lists.sourceforge.net
Subject: Re: [linux-usb-devel] USB on PPC440GP (cache incoherent)
Date: 08 Jun 2002 13:43:26 -0700 [thread overview]
Message-ID: <52ptz1a4cx.fsf@topspin.com> (raw)
In-Reply-To: <200206080845.g588jvX11858@fachschaft.cup.uni-muenchen.de>
>>>>> "Oliver" == Oliver Neukum <Oliver.Neukum@lrz.uni-muenchen.de> writes:
Oliver> This can be used in error handling by storage devices. You
Oliver> must use GFP_NOIO. And you should check for a failure due
Oliver> to OOM.
Yep, I caught those missed checks for allocation failure. And I will
change to using GFP_NOIO where appropriate.
Roland> - srb->request_buffer = srb->sense_buffer;
Roland> + srb->request_buffer = kmalloc(18, in_interrupt() ? GFP_ATOMIC :
Oliver> However, why do you do this ? The srb is kmalloced.
Yes, but srb->sense_buffer is not aligned on a cache line boundary.
My feeling is that this could corrupt the rest of the cache line,
though others have questioned whether this is strictly necessary. I
just posted a question on lkml to try to and get an authoritative
answer on DMA into unaligned buffers is OK.
Thanks for the comments,
Roland
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
prev parent reply other threads:[~2002-06-08 20:43 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-06-07 23:57 USB on PPC440GP (cache incoherent) Roland Dreier
2002-06-08 2:54 ` [linux-usb-devel] " David Brownell
2002-06-08 3:43 ` Roland Dreier
2002-06-08 5:18 ` David Brownell
2002-06-08 8:47 ` Oliver Neukum
2002-06-08 20:43 ` Roland Dreier [this message]
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=52ptz1a4cx.fsf@topspin.com \
--to=roland@topspin.com \
--cc=Oliver.Neukum@lrz.uni-muenchen.de \
--cc=linux-usb-devel@lists.sourceforge.net \
--cc=linuxppc-embedded@lists.linuxppc.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;
as well as URLs for NNTP newsgroup(s).