[Devel] [PATCH RHEL7 COMMIT] ploop: Pass correct argument in kaio_sync_read_many()

Vasily Averin vvs at virtuozzo.com
Mon Aug 17 09:52:25 MSK 2020


The commit is pushed to "branch-rh7-3.10.0-1127.18.2.vz7.163.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-1127.18.2.vz7.163.2
------>
commit 17b0126be1a9cc55962987e376506bc866e271c3
Author: Kirill Tkhai <ktkhai at virtuozzo.com>
Date:   Mon Aug 17 09:52:25 2020 +0300

    ploop: Pass correct argument in kaio_sync_read_many()
    
    AIO argument has to be passed here, while READ_SYNC results
    in permanent EINVAL.
    
    The fix has no visible effect, as this function is currently
    unused (kaio is not populating holes_bitmap on mount at the moment).
    
    https://jira.sw.ru/browse/PSBM-105347
    
    Signed-off-by: Kirill Tkhai <ktkhai at virtuozzo.com>
---
 drivers/block/ploop/io_kaio.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/block/ploop/io_kaio.c b/drivers/block/ploop/io_kaio.c
index 36f4a62..87287af 100644
--- a/drivers/block/ploop/io_kaio.c
+++ b/drivers/block/ploop/io_kaio.c
@@ -886,7 +886,7 @@ kaio_sync_write(struct ploop_io * io, struct page * page, unsigned int len,
 static int kaio_sync_read_many(struct ploop_io *io, struct page *pages[],
 				unsigned int nr_pages, sector_t sec)
 {
-	return kaio_sync_io(io, READ_SYNC, pages, nr_pages,
+	return kaio_sync_io(io, IOCB_CMD_READ_ITER, pages, nr_pages,
 			    PAGE_SIZE * nr_pages, 0, sec);
 }
 


More information about the Devel mailing list