projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2f9a0b3
)
sd: switch to using blk_queue_write_cache()
author
Jens Axboe
<
[email protected]
>
Wed, 30 Mar 2016 16:06:11 +0000
(10:06 -0600)
committer
Jens Axboe
<
[email protected]
>
Tue, 12 Apr 2016 22:00:39 +0000
(16:00 -0600)
Switch to the newer interface, instead of using blk_queue_flush()
directly.
Signed-off-by: Jens Axboe <
[email protected]
>
Reviewed-by: Christoph Hellwig <
[email protected]
>
Acked-by: Martin K. Petersen <
[email protected]
>
drivers/scsi/sd.c
patch
|
blob
|
history
diff --git
a/drivers/scsi/sd.c
b/drivers/scsi/sd.c
index 69b0a4a7a15f472e31884b02c46228a5b85e6314..428c03ef02b21ec538f1d55204f2ff27351bb445 100644
(file)
--- a/
drivers/scsi/sd.c
+++ b/
drivers/scsi/sd.c
@@
-137,15
+137,15
@@
static const char *sd_cache_types[] = {
static void sd_set_flush_flag(struct scsi_disk *sdkp)
{
-
unsigned flush = 0
;
+
bool wc = false, fua = false
;
if (sdkp->WCE) {
-
flush |= REQ_FLUSH
;
+
wc = true
;
if (sdkp->DPOFUA)
- f
lush |= REQ_FUA
;
+ f
ua = true
;
}
- blk_queue_
flush(sdkp->disk->queue, flush
);
+ blk_queue_
write_cache(sdkp->disk->queue, wc, fua
);
}
static ssize_t