[Devel] [PATCH RHEL7 COMMIT] ploop: io_kaio: fix silly bug in kaio_complete_io_state()
Konstantin Khorenko
khorenko at virtuozzo.com
Fri Jun 17 02:32:34 PDT 2016
The commit is pushed to "branch-rh7-3.10.0-327.18.2.vz7.14.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-327.18.2.vz7.14.15
------>
commit 75347fcbd30151977601d819a56f0a0bb57182f5
Author: Maxim Patlasov <mpatlasov at virtuozzo.com>
Date: Fri Jun 17 13:32:34 2016 +0400
ploop: io_kaio: fix silly bug in kaio_complete_io_state()
It's useless to check for preq->req_rw & REQ_FUA after:
preq->req_rw &= ~REQ_FUA;
Signed-off-by: Maxim Patlasov <mpatlasov at virtuozzo.com>
Acked-by: Dmitry Monakhov <dmonakhov at virtuozzo.com>
Note: original code:
...
preq->req_rw &= ~REQ_FUA;
/* Convert requested fua to fsync */
if (test_and_clear_bit(PLOOP_REQ_FORCE_FUA, &preq->state) ||
test_and_clear_bit(PLOOP_REQ_KAIO_FSYNC,
&preq->state))
post_fsync = 1;
if (!post_fsync &&
!ploop_req_delay_fua_possible(preq->req_rw, preq) &&
(preq->req_rw & REQ_FUA))
post_fsync = 1;
preq->req_rw &= ~REQ_FUA;
...
---
drivers/block/ploop/io_kaio.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/block/ploop/io_kaio.c b/drivers/block/ploop/io_kaio.c
index 54f8e21..81da1c5 100644
--- a/drivers/block/ploop/io_kaio.c
+++ b/drivers/block/ploop/io_kaio.c
@@ -78,8 +78,6 @@ static void kaio_complete_io_state(struct ploop_request * preq)
return;
}
- preq->req_rw &= ~REQ_FUA;
-
/* Convert requested fua to fsync */
if (test_and_clear_bit(PLOOP_REQ_FORCE_FUA, &preq->state) ||
test_and_clear_bit(PLOOP_REQ_KAIO_FSYNC, &preq->state))
More information about the Devel
mailing list