mirror of
https://github.com/koverstreet/bcachefs-tools.git
synced 2025-12-11 00:00:12 +03:00
handle REQ_OP_FLUSH
This commit is contained in:
parent
8aaf7d913a
commit
c7950838b2
@ -79,6 +79,12 @@ void generic_make_request(struct bio *bio)
|
|||||||
if (ret != 1)
|
if (ret != 1)
|
||||||
die("io_submit err: %s", strerror(-ret));
|
die("io_submit err: %s", strerror(-ret));
|
||||||
break;
|
break;
|
||||||
|
case REQ_OP_FLUSH:
|
||||||
|
ret = fsync(bio->bi_bdev->bd_fd);
|
||||||
|
if (ret)
|
||||||
|
die("fsync error: %m");
|
||||||
|
bio_endio(bio);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
BUG();
|
BUG();
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user