linux-block.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Brian Foster <bfoster@redhat.com>
To: Chaitanya Kulkarni <chaitanyak@nvidia.com>
Cc: "linux-block@vger.kernel.org" <linux-block@vger.kernel.org>,
	"axboe@kernel.dk" <axboe@kernel.dk>,
	"damien.lemoal@opensource.wdc.com"
	<damien.lemoal@opensource.wdc.com>,
	"johannes.thumshirn@wdc.com" <johannes.thumshirn@wdc.com>,
	"bvanassche@acm.org" <bvanassche@acm.org>,
	"ming.lei@redhat.com" <ming.lei@redhat.com>,
	"shinichiro.kawasaki@wdc.com" <shinichiro.kawasaki@wdc.com>,
	"vincent.fu@samsung.com" <vincent.fu@samsung.com>,
	"yukuai3@huawei.com" <yukuai3@huawei.com>
Subject: Re: [PATCH 2/6] null_blk: allow write zeores on membacked
Date: Wed, 5 Oct 2022 14:53:23 -0400	[thread overview]
Message-ID: <Yz3So0+WoFH7e4p3@bfoster> (raw)
In-Reply-To: <09793b3d-b1f9-9755-f3cc-1f0cfcaeded0@nvidia.com>

On Wed, Oct 05, 2022 at 06:45:35PM +0000, Chaitanya Kulkarni wrote:
> 
> >> @@ -875,6 +877,24 @@ static void null_free_sector(struct nullb *nullb, sector_t sector,
> >>   	}
> >>   }
> >>   
> >> +static void null_zero_sector(struct nullb_device *d, sector_t sect,
> >> +			     sector_t nr_sects, bool cache)
> >> +{
> > 
> > Any reason to not just pass the tree root directly here instead of the
> > cache boolean? It might make the callers more readable and also
> > eliminates the need to pass the nullb_device.
> > 
> > Brian
> > 
> 
> I kept the style similar to null_free_sector() where root is calculated 
> inside the helper acting on the sector, if we change that for 
> null_zero_sector() then I think we need to change for null_free_sector() 
> for consistency, unless you strongly object it for some reason.
> 

Nope, just a nit that stood out to me when skimming the patches. Not a
big deal at all.

Brian

> -ck
> 


  reply	other threads:[~2022-10-05 18:53 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-05  3:16 [PATCH 0/6] null_blk: allow REQ_OP_WRITE_ZEROES and cleanup Chaitanya Kulkarni
2022-10-05  3:16 ` [PATCH 1/6] null_blk: allow write zeores on non-membacked Chaitanya Kulkarni
2022-10-05  4:54   ` Damien Le Moal
2022-10-05  5:24     ` Chaitanya Kulkarni
2022-10-05 18:33       ` Chaitanya Kulkarni
2022-10-05  3:16 ` [PATCH 2/6] null_blk: allow write zeores on membacked Chaitanya Kulkarni
2022-10-05  4:57   ` Damien Le Moal
2022-10-05  5:10     ` Chaitanya Kulkarni
2022-10-05 17:18   ` Brian Foster
2022-10-05 18:45     ` Chaitanya Kulkarni
2022-10-05 18:53       ` Brian Foster [this message]
2022-10-05 19:01         ` Chaitanya Kulkarni
2022-10-05  3:16 ` [PATCH 3/6] null_blk: code cleaup Chaitanya Kulkarni
2022-10-05  5:02   ` Damien Le Moal
2022-10-05  5:21     ` Chaitanya Kulkarni
2022-10-05  3:16 ` [PATCH 4/6] null_blk: initialize cmd->bio in __alloc_cmd() Chaitanya Kulkarni
2022-10-05  5:04   ` Damien Le Moal
2022-10-05  3:17 ` [PATCH 5/6] null_blk: don't use magic numbers in the code Chaitanya Kulkarni
2022-10-05  5:05   ` Damien Le Moal
2022-10-05  3:17 ` [PATCH 6/6] null_blk: remove extra space in switch condition Chaitanya Kulkarni
2022-10-05  5:06   ` Damien Le Moal

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Yz3So0+WoFH7e4p3@bfoster \
    --to=bfoster@redhat.com \
    --cc=axboe@kernel.dk \
    --cc=bvanassche@acm.org \
    --cc=chaitanyak@nvidia.com \
    --cc=damien.lemoal@opensource.wdc.com \
    --cc=johannes.thumshirn@wdc.com \
    --cc=linux-block@vger.kernel.org \
    --cc=ming.lei@redhat.com \
    --cc=shinichiro.kawasaki@wdc.com \
    --cc=vincent.fu@samsung.com \
    --cc=yukuai3@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).