Okay, will send the new version..
On 8/21/19 5:58 PM, Christoph Hellwig wrote:
>> +static inline blk_status_t null_handle_zoned(struct nullb_cmd *cmd,
>> + enum req_opf op, sector_t sector,
>> + sector_t nr_sectors)
>> +{
> Shouldn't this go into null_blk_zoned.c? Also the indentation for the
> here seems odd.
>
>> + blk_status_t sts = BLK_STS_OK;
>> +
>> + switch (op) {
>> + case REQ_OP_WRITE:
>> + sts = null_zone_write(cmd, sector, nr_sectors);
>> + break;
>> + case REQ_OP_ZONE_RESET:
>> + sts = null_zone_reset(cmd, sector);
>> + break;
>> + default:
>> + break;
>> + }
>> +
>> + return sts;
> Why not:
>
> switch (op) {
> case REQ_OP_WRITE:
> return null_zone_write(cmd, sector, nr_sectors);
> case REQ_OP_ZONE_RESET:
> return null_zone_reset(cmd, sector);
> default:
> return BLK_STS_OK;
> }- [PATCH V3 3/6] null_blk: create a helper for badblocks Chaitanya Kulkarni
- Re: [PATCH V3 3/6] null_blk: create a helper for b... Christoph Hellwig
- [PATCH V3 6/6] null_blk: create a helper for req comple... Chaitanya Kulkarni
- Re: [PATCH V3 6/6] null_blk: create a helper for r... Christoph Hellwig
- Re: [PATCH V3 6/6] null_blk: create a helper f... Chaitanya Kulkarni
- Re: [PATCH V3 6/6] null_blk: create a help... Chaitanya Kulkarni
- [PATCH V3 4/6] null_blk: create a helper for mem-backed... Chaitanya Kulkarni
- Re: [PATCH V3 4/6] null_blk: create a helper for m... Christoph Hellwig
- [PATCH V3 5/6] null_blk: create a helper for zoned devi... Chaitanya Kulkarni
- Re: [PATCH V3 5/6] null_blk: create a helper for z... Christoph Hellwig
- Re: [PATCH V3 5/6] null_blk: create a helper f... Chaitanya Kulkarni
