From: domen@coderock.org
To: axboe@suse.de
Cc: linux-kernel@vger.kernel.org,
Tobias Klauser <tklauser@nuerscht.ch>,
domen@coderock.org
Subject: [patch 11/12] drivers/block/umem.c: Use the DMA_{64, 32}BIT_MASK constants
Date: Mon, 20 Jun 2005 23:51:41 +0200 [thread overview]
Message-ID: <20050620215139.825371000@nd47.coderock.org> (raw)
[-- Attachment #1: dma_mask-drivers_block_umem.patch --]
[-- Type: text/plain, Size: 1435 bytes --]
From: Tobias Klauser <tklauser@nuerscht.ch>
Use the DMA_{64,32}BIT_MASK constants from dma-mapping.h when calling
pci_set_dma_mask() or pci_set_consistent_dma_mask()
These patches include dma-mapping.h explicitly because it caused errors
on some architectures otherwise.
See http://marc.theaimsgroup.com/?t=108001993000001&r=1&w=2 for details
Signed-off-by: Tobias Klauser <tklauser@nuerscht.ch>
Signed-off-by: Domen Puncer <domen@coderock.org>
---
umem.c | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
Index: quilt/drivers/block/umem.c
===================================================================
--- quilt.orig/drivers/block/umem.c
+++ quilt/drivers/block/umem.c
@@ -50,6 +50,7 @@
#include <linux/timer.h>
#include <linux/pci.h>
#include <linux/slab.h>
+#include <linux/dma-mapping.h>
#include <linux/fcntl.h> /* O_ACCMODE */
#include <linux/hdreg.h> /* HDIO_GETGEO */
@@ -892,8 +893,8 @@ static int __devinit mm_pci_probe(struct
printk(KERN_INFO "Micro Memory(tm) controller #%d found at %02x:%02x (PCI Mem Module (Battery Backup))\n",
card->card_number, dev->bus->number, dev->devfn);
- if (pci_set_dma_mask(dev, 0xffffffffffffffffLL) &&
- !pci_set_dma_mask(dev, 0xffffffffLL)) {
+ if (pci_set_dma_mask(dev, DMA_64BIT_MASK) &&
+ !pci_set_dma_mask(dev, DMA_32BIT_MASK)) {
printk(KERN_WARNING "MM%d: NO suitable DMA found\n",num_cards);
return -ENOMEM;
}
--
next reply other threads:[~2005-06-21 6:19 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-20 21:51 domen [this message]
2005-06-21 7:19 ` [patch 11/12] drivers/block/umem.c: Use the DMA_{64, 32}BIT_MASK constants Jens Axboe
2005-06-21 11:11 ` Neil Brown
2005-06-21 16:25 ` Tobias Klauser
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=20050620215139.825371000@nd47.coderock.org \
--to=domen@coderock.org \
--cc=axboe@suse.de \
--cc=linux-kernel@vger.kernel.org \
--cc=tklauser@nuerscht.ch \
/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