[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20080307091325.04DE91B419C@basil.firstfloor.org>
Date: Fri, 7 Mar 2008 10:13:25 +0100 (CET)
From: Andi Kleen <andi@...stfloor.org>
To: axboe@...nel.dk, linux-kernel@...r.kernel.org
Subject: [PATCH] [4/7] Add blk_q_mask
Converts the queue bounce_pfn to a DMA mask suitable for the mask allocator
Signed-off-by: Andi Kleen <ak@...e.de>
---
include/linux/blkdev.h | 5 +++++
1 file changed, 5 insertions(+)
Index: linux/include/linux/blkdev.h
===================================================================
--- linux.orig/include/linux/blkdev.h
+++ linux/include/linux/blkdev.h
@@ -814,6 +814,11 @@ static inline unsigned int block_size(st
return bdev->bd_block_size;
}
+static inline u64 blk_q_mask(struct request_queue *q)
+{
+ return ~(-1LL << (PAGE_SHIFT + fls64(q->bounce_pfn)));
+}
+
typedef struct {struct page *v;} Sector;
unsigned char *read_dev_sector(struct block_device *, sector_t, Sector *);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists