]> git.baikalelectronics.ru Git - kernel.git/commit
block: Make blkdev_issue_zeroout use WRITE SAME
authorMartin K. Petersen <martin.petersen@oracle.com>
Tue, 18 Sep 2012 16:19:28 +0000 (12:19 -0400)
committerJens Axboe <axboe@kernel.dk>
Thu, 20 Sep 2012 12:31:49 +0000 (14:31 +0200)
commit78c6de24aee43bf98c59b3fe7b1b94c718deb029
treef41d7d469cb427550656f1d1d2c3b5215a9ea0aa
parentff4f212484f2d5b3c8e443146b4e8a984b98019b
block: Make blkdev_issue_zeroout use WRITE SAME

If the device supports WRITE SAME, use that to optimize zeroing of
blocks. If the device does not support WRITE SAME or if the operation
fails, fall back to writing zeroes the old-fashioned way.

Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Acked-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-lib.c