From: James Bottomley <James.Bottomley@HansenPartnership.com>
To: "Salyzyn, Mark" <Mark_Salyzyn@adaptec.com>
Cc: "'linux-scsi@vger.kernel.org'" <linux-scsi@vger.kernel.org>
Subject: Re: [PATCH 1/1] aacraid: add call to flush_kernel_dcache_page for architectures that require it.
Date: Fri, 11 Jan 2008 10:41:02 -0600 [thread overview]
Message-ID: <1200069662.3286.21.camel@localhost.localdomain> (raw)
In-Reply-To: <532ABFBDAAC3A34EB12EBA6CEC2838F40DC622@ADPE2K703.adaptec.com>
On Tue, 2008-01-08 at 12:09 -0800, Salyzyn, Mark wrote:
> Some architectures require a call to flush_kernel_dcache_page for processor spoofed DMA operations.
>
> This attached patch is against current scsi-misc-2.6.
>
> ObligatoryDisclaimer: Please accept my condolences regarding Outlook's handling of patch attachments (inline gets damaged, use attachment).
>
> Signed-off-by: Mark Salyzyn <aacraid@adaptec.com>
>
> aachba.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff -ru a/drivers/scsi/aacraid/aachba.c b/drivers/scsi/aacraid/aachba.c
> --- a/drivers/scsi/aacraid/aachba.c 2008-01-08 15:01:21.503932722 -0500
> +++ b/drivers/scsi/aacraid/aachba.c 2008-01-08 15:02:35.849634368 -0500
> @@ -31,9 +31,9 @@
> #include <linux/slab.h>
> #include <linux/completion.h>
> #include <linux/blkdev.h>
> -#include <linux/dma-mapping.h>
> #include <asm/semaphore.h>
> #include <asm/uaccess.h>
> +#include <linux/highmem.h> /* For flush_kernel_dcache_page */
>
> #include <scsi/scsi.h>
> #include <scsi/scsi_cmnd.h>
> @@ -366,6 +366,9 @@
> if (buf && transfer_len > 0)
> memcpy(buf + offset, data, transfer_len);
>
> +#ifdef ARCH_HAS_FLUSH_ANON_PAGE
> + flush_kernel_dcache_page(kmap_atomic_to_page(buf - sg->offset));
> +#endif
This #ifdef/#endif guard is unnecessary ... flush_kernel_dcache_page()
is available on all architectures (it's a nop on most).
However, ARCH_HAS_FLUSH_ANON_PAGE is the wrong guard anyway ... that's
for the flush_anon_page() function ...
James
next prev parent reply other threads:[~2008-01-11 16:41 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-31 4:02 [PATCH] aacraid: don't assign cpu_to_le32(constant) to u8 Stephen Rothwell
2007-10-31 13:53 ` Salyzyn, Mark
2007-11-01 6:32 ` [PATCHv2] " Stephen Rothwell
2007-11-01 13:11 ` Salyzyn, Mark
2007-11-01 13:31 ` Andreas Schwab
2007-11-07 15:58 ` [PATCH 1/1] aacraid: don't assign cpu_to_le32(int) " Salyzyn, Mark
2007-11-07 17:33 ` Christoph Hellwig
2007-11-07 18:51 ` Salyzyn, Mark
2007-11-08 17:27 ` Christoph Hellwig
2007-11-08 18:09 ` Salyzyn, Mark
2008-01-08 20:01 ` [PATCH 1/1] aacraid: add aacraid.cache parameter to driver to control FUA and SYNCHRONIZE_CACHE policy Salyzyn, Mark
[not found] ` <532ABFBDAAC3A34EB12EBA6CEC2838F40FE734@ADPE2K703.adaptec.com>
2008-01-08 20:09 ` [PATCH 1/1] aacraid: add call to flush_kernel_dcache_page for architectures that require it Salyzyn, Mark
2008-01-11 16:41 ` James Bottomley [this message]
2008-01-11 19:46 ` [PATCH 1/1] aacraid: add call to flush_kernel_dcache_page for architectures that require it (take 2) Salyzyn, Mark
2008-01-11 19:56 ` James Bottomley
[not found] ` <532ABFBDAAC3A34EB12EBA6CEC2838F40FE735@ADPE2K703.adaptec.com>
2008-01-08 20:23 ` [PATCH 1/1] aacraid: add sysfs report of RAID level Salyzyn, Mark
[not found] ` <532ABFBDAAC3A34EB12EBA6CEC2838F40FE736@ADPE2K703.adaptec.com>
2008-01-08 20:32 ` [PATCH 1/1] aacraid: variable redefinition hides earlier warning Salyzyn, Mark
2008-01-08 20:48 ` [PATCH 1/1] aacraid: big endian issues Salyzyn, Mark
2008-01-08 21:17 ` Grant Grundler
2008-01-08 21:37 ` Salyzyn, Mark
2008-01-09 3:57 ` Grant Grundler
2008-01-08 21:39 ` Matthew Wilcox
[not found] ` <532ABFBDAAC3A34EB12EBA6CEC2838F40FE738@ADPE2K703.adaptec.com>
2008-01-08 20:57 ` [PATCH 1/1] aacraid: multiple definition of automatic variable warning Salyzyn, Mark
2008-01-08 21:08 ` Salyzyn, Mark
2008-01-08 21:26 ` [PATCH 1/1] aacraid: OS panic after Adapter panic (hardening) Salyzyn, Mark
[not found] ` <532ABFBDAAC3A34EB12EBA6CEC2838F40FE739@ADPE2K703.adaptec.com>
2008-01-08 22:07 ` [PATCH 1/1] aacraid: improve queue balancing Salyzyn, Mark
2008-01-24 15:40 ` [PATCH 1/1] aacraid: fib context lock for management ioctls Salyzyn, Mark
2008-01-28 20:16 ` [PATCH 1/1] aacraid: fib context lock for management ioctls (take 2) Salyzyn, Mark
[not found] ` <532ABFBDAAC3A34EB12EBA6CEC2838F40FE73E@ADPE2K703.adaptec.com>
2008-01-11 16:15 ` [PATCH 1/1] aacraid: respond to enclosure service events Salyzyn, Mark
[not found] ` <532ABFBDAAC3A34EB12EBA6CEC2838F437E96989@ADPE2K703.adaptec.com>
2008-01-11 16:41 ` [RFC] aacraid: driver feature flags? Salyzyn, Mark
2008-01-11 19:56 ` [PATCH 1/1] aacraid: respond to enclosure service events (take 2) Salyzyn, Mark
2008-01-11 21:46 ` [PATCH 1/1] aacraid: SMC vendor identification Salyzyn, Mark
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=1200069662.3286.21.camel@localhost.localdomain \
--to=james.bottomley@hansenpartnership.com \
--cc=Mark_Salyzyn@adaptec.com \
--cc=linux-scsi@vger.kernel.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