Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=482eb689169948e9f4966fbae6be4d6bc0bfa818
Commit:     482eb689169948e9f4966fbae6be4d6bc0bfa818
Parent:     6da127ad0918f93ea93678dad62ce15ffed18797
Author:     Pete Wyckoff <[EMAIL PROTECTED]>
AuthorDate: Tue Jan 1 10:23:02 2008 -0500
Committer:  Jens Axboe <[EMAIL PROTECTED]>
CommitDate: Mon Jan 28 10:04:46 2008 +0100

    block: allow queue dma_alignment of zero
    
    Let queue_dma_alignment return 0 if it was specifically set to 0.
    This permits devices with no particular alignment restrictions to
    use arbitrary user space buffers without copying.
    
    Signed-off-by: Pete Wyckoff <[EMAIL PROTECTED]>
    Signed-off-by: Jens Axboe <[EMAIL PROTECTED]>
---
 include/linux/blkdev.h |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 49b7a4c..c7a3ab5 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -836,12 +836,7 @@ static inline int bdev_hardsect_size(struct block_device 
*bdev)
 
 static inline int queue_dma_alignment(struct request_queue *q)
 {
-       int retval = 511;
-
-       if (q && q->dma_alignment)
-               retval = q->dma_alignment;
-
-       return retval;
+       return q ? q->dma_alignment : 511;
 }
 
 /* assumes size > 256 */
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to