xen/blkfront: fix comment for need_copy
Subsystems (3)
PATCH 1/1 xen/blkfront: fix comment for need_copy
The 'need_copy' is set when rq_data_dir(req) returns WRITE, in order to copy the written data to persistent page.
".need_copy = rq_data_dir(req) && info->feature_persistent,"
--- drivers/block/xen-blkfront.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/block/xen-blkfront.c +1 -1
@@ -576,7 +576,7 @@ struct setup_rw_req {struct blkif_request *ring_req;grant_ref_t gref_head;unsigned int id; -/* Only used when persistent grant is used and it's a read request */ +/* Only used when persistent grant is used and it's a write request */ bool need_copy;unsigned int bvec_off;char *bvec_data;
Signature · 1 line
2.17.1
Quoted 7 lines · Dongli Zhang
The '
need_copy' is set whenrq_data_dir(req)returns WRITE, in order to copy the written data to persistent page.".need_copy =
rq_data_dir(req)&&info->feature_persistent,"Signed-off-by Dongli Zhang <[email protected]>---
Looks good.
-ck
Quoted 4 lines · Dongli Zhang
The '
need_copy' is set whenrq_data_dir(req)returns WRITE, in order to copy the written data to persistent page.".need_copy =
rq_data_dir(req)&&info->feature_persistent,"
I would also add:
Quoted 1 line
Signed-off-by Dongli Zhang <[email protected]>
Albeit I have one nit since you are already changing the line.
Quoted 9 lines
--- drivers/block/xen-blkfront.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/block/xen-blkfront.c +0
-0
drivers/block/xen-blkfront.c struct setup_rw_req { · line 579
Quoted 5 lines
drivers/block/xen-blkfront.c +1
-1@@ -576,7 +576,7 @@ struct setup_rw_req {struct blkif_request *ring_req;grant_ref_t gref_head;unsigned int id; -/* Only used when persistent grant is used and it's a read request */ +/* Only used when persistent grant is used and it's a write request */
While there you might want to adjust the comment to:
"... persistent grants are used ..."
Thanks, Roger.
Juergen Gross
maintainerQuoted 9 lines · Roger Pau Monné
Quoted 4 lines · Dongli Zhang
The '
need_copy' is set whenrq_data_dir(req)returns WRITE, in order to copy the written data to persistent page.".need_copy =
rq_data_dir(req)&&info->feature_persistent,"I would also add:
Fixes c004a6fe0c40 ('block/xen-blkfront: Make it running on 64KB page granularity')
Hmm, a "Fixes:" tag for a change in a comment?
This might generate additional work e.g. for downstreams (we at SUSE have scripts checking "Fixes:" tags and require such changes to be applied to kernels having the fixed patch applied).
That said I'd prefer not having a "Fixes:" tag for such changes, but maybe this is just due to the fact that it would be me having to apply this patch to the SUSE kernels...
Juergen
Quoted 6 lines · Dongli Zhang
The '
need_copy' is set whenrq_data_dir(req)returns WRITE, in order to copy the written data to persistent page.".need_copy =
rq_data_dir(req)&&info->feature_persistent,"
Applied, thanks!
[1/1] xen/blkfront: fix comment for need_copy
commit: 08719dd9176b4c55f547bd11812fd6cc35907d37
Best regards,
Signature · 1 line
Jens Axboe