From: Rolf Eike Beer <eike-kernel@sf-tec.de>
To: aacraid@adaptec.com
Cc: linux-scsi@vger.kernel.org, Andrew Morton <akpm@linux-foundation.org>
Subject: [PATCH][Resend #2] Do not set DMA mask to 32 bit first if adapter only supports 31
Date: Mon, 26 Jul 2010 08:07:44 +0200 [thread overview]
Message-ID: <201007260807.45533.eike-kernel@sf-tec.de> (raw)
>From 1c2f6ce5be5890ea7151ada3602699566afdd060 Mon Sep 17 00:00:00 2001
From: Rolf Eike Beer <eike-kernel@sf-tec.de>
Date: Wed, 1 Jul 2009 22:43:39 +0200
Signed-off-by: Rolf Eike Beer <eike-kernel@sf-tec.de>
---
drivers/scsi/aacraid/linit.c | 14 ++++++++------
1 files changed, 8 insertions(+), 6 deletions(-)
James, it looks like people at Adaptec don't care if you send patches in. That
also applies to at least one patch from Julia Lawall that is waiting since
December. What next?
diff --git a/drivers/scsi/aacraid/linit.c b/drivers/scsi/aacraid/linit.c
index 33898b6..cad6f9a 100644
--- a/drivers/scsi/aacraid/linit.c
+++ b/drivers/scsi/aacraid/linit.c
@@ -1091,6 +1091,7 @@ static int __devinit aac_probe_one(struct pci_dev *pdev,
struct list_head *insert = &aac_devices;
int error = -ENODEV;
int unique_id = 0;
+ u64 dmamask;
list_for_each_entry(aac, &aac_devices, entry) {
if (aac->id > unique_id)
@@ -1104,17 +1105,18 @@ static int __devinit aac_probe_one(struct pci_dev
*pdev,
goto out;
error = -ENODEV;
- if (pci_set_dma_mask(pdev, DMA_BIT_MASK(32)) ||
- pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(32)))
- goto out_disable_pdev;
/*
* If the quirk31 bit is set, the adapter needs adapter
* to driver communication memory to be allocated below 2gig
*/
if (aac_drivers[index].quirks & AAC_QUIRK_31BIT)
- if (pci_set_dma_mask(pdev, DMA_BIT_MASK(31)) ||
- pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(31)))
- goto out_disable_pdev;
+ dmamask = DMA_BIT_MASK(31);
+ else
+ dmamask = DMA_BIT_MASK(32);
+
+ if (pci_set_dma_mask(pdev, dmamask) ||
+ pci_set_consistent_dma_mask(pdev, dmamask))
+ goto out_disable_pdev;
pci_set_master(pdev);
--
1.7.1
next reply other threads:[~2010-07-26 6:07 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-26 6:07 Rolf Eike Beer [this message]
2010-07-26 13:25 ` [PATCH][Resend #2] Do not set DMA mask to 32 bit first if adapter only supports 31 Achim Leubner
2010-07-26 15:46 ` Rolf Eike Beer
2010-07-26 16:07 ` James Bottomley
2010-07-26 16:53 ` Rolf Eike Beer
2010-07-29 10:09 ` Achim Leubner
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=201007260807.45533.eike-kernel@sf-tec.de \
--to=eike-kernel@sf-tec.de \
--cc=aacraid@adaptec.com \
--cc=akpm@linux-foundation.org \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.