* [PATCH for-next 0/2] Misc RNBD update @ 2022-01-14 15:58 Md Haris Iqbal 2022-01-14 15:58 ` [PATCH for-next 1/2] block/rnbd-clt: fix CHECK:BRACES warning Md Haris Iqbal ` (3 more replies) 0 siblings, 4 replies; 9+ messages in thread From: Md Haris Iqbal @ 2022-01-14 15:58 UTC (permalink / raw) To: linux-block; +Cc: axboe, hch, sagi, bvanassche, haris.iqbal, jinpu.wang Hi Jens, Please consider to include following change for next merge window. - fixes warning generated from checkpatch - removes rotational param from RNBD device Gioh Kim (2): block/rnbd-clt: fix CHECK:BRACES warning block/rnbd: client device does not care queue/rotational drivers/block/rnbd/rnbd-clt.c | 15 ++++++++------- drivers/block/rnbd/rnbd-clt.h | 1 - drivers/block/rnbd/rnbd-proto.h | 4 ++-- drivers/block/rnbd/rnbd-srv.c | 1 - 4 files changed, 10 insertions(+), 11 deletions(-) -- 2.25.1 ^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH for-next 1/2] block/rnbd-clt: fix CHECK:BRACES warning 2022-01-14 15:58 [PATCH for-next 0/2] Misc RNBD update Md Haris Iqbal @ 2022-01-14 15:58 ` Md Haris Iqbal 2022-01-14 15:58 ` [PATCH for-next 2/2] block/rnbd: client device does not care queue/rotational Md Haris Iqbal ` (2 subsequent siblings) 3 siblings, 0 replies; 9+ messages in thread From: Md Haris Iqbal @ 2022-01-14 15:58 UTC (permalink / raw) To: linux-block Cc: axboe, hch, sagi, bvanassche, haris.iqbal, jinpu.wang, Gioh Kim From: Gioh Kim <gi-oh.kim@ionos.com> This patch fix the "CHECK:BRACES: braces {} should be used on all arms of this statement" warning from checkpatch Signed-off-by: Gioh Kim <gi-oh.kim@ionos.com> Signed-off-by: Md Haris Iqbal <haris.iqbal@ionos.com> --- drivers/block/rnbd/rnbd-clt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/block/rnbd/rnbd-clt.c b/drivers/block/rnbd/rnbd-clt.c index 67a8edbaa1fd..8c24d3dfe35f 100644 --- a/drivers/block/rnbd/rnbd-clt.c +++ b/drivers/block/rnbd/rnbd-clt.c @@ -1262,9 +1262,9 @@ find_and_get_or_create_sess(const char *sessname, struct rtrs_clt_ops rtrs_ops; sess = find_or_create_sess(sessname, &first); - if (sess == ERR_PTR(-ENOMEM)) + if (sess == ERR_PTR(-ENOMEM)) { return ERR_PTR(-ENOMEM); - else if ((nr_poll_queues && !first) || (!nr_poll_queues && sess->nr_poll_queues)) { + } else if ((nr_poll_queues && !first) || (!nr_poll_queues && sess->nr_poll_queues)) { /* * A device MUST have its own session to use the polling-mode. * It must fail to map new device with the same session. -- 2.25.1 ^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH for-next 2/2] block/rnbd: client device does not care queue/rotational 2022-01-14 15:58 [PATCH for-next 0/2] Misc RNBD update Md Haris Iqbal 2022-01-14 15:58 ` [PATCH for-next 1/2] block/rnbd-clt: fix CHECK:BRACES warning Md Haris Iqbal @ 2022-01-14 15:58 ` Md Haris Iqbal 2022-01-26 13:57 ` [PATCH for-next 0/2] Misc RNBD update Haris Iqbal 2022-01-26 14:01 ` Jens Axboe 3 siblings, 0 replies; 9+ messages in thread From: Md Haris Iqbal @ 2022-01-14 15:58 UTC (permalink / raw) To: linux-block Cc: axboe, hch, sagi, bvanassche, haris.iqbal, jinpu.wang, Gioh Kim From: Gioh Kim <gi-oh.kim@ionos.com> On client side, the device is a network device. There is no reason to set rotational even-if the target device on server is rotational. Signed-off-by: Gioh Kim <gi-oh.kim@ionos.com> Signed-off-by: Jack Wang <jinpu.wang@ionos.com> Signed-off-by: Md Haris Iqbal <haris.iqbal@ionos.com> --- drivers/block/rnbd/rnbd-clt.c | 11 ++++++----- drivers/block/rnbd/rnbd-clt.h | 1 - drivers/block/rnbd/rnbd-proto.h | 4 ++-- drivers/block/rnbd/rnbd-srv.c | 1 - 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/drivers/block/rnbd/rnbd-clt.c b/drivers/block/rnbd/rnbd-clt.c index 8c24d3dfe35f..6ace401baf8a 100644 --- a/drivers/block/rnbd/rnbd-clt.c +++ b/drivers/block/rnbd/rnbd-clt.c @@ -87,7 +87,6 @@ static int rnbd_clt_set_dev_attr(struct rnbd_clt_dev *dev, dev->discard_granularity = le32_to_cpu(rsp->discard_granularity); dev->discard_alignment = le32_to_cpu(rsp->discard_alignment); dev->secure_discard = le16_to_cpu(rsp->secure_discard); - dev->rotational = rsp->rotational; dev->wc = !!(rsp->cache_policy & RNBD_WRITEBACK); dev->fua = !!(rsp->cache_policy & RNBD_FUA); @@ -1410,8 +1409,10 @@ static int rnbd_clt_setup_gen_disk(struct rnbd_clt_dev *dev, int idx) dev->read_only = false; } - if (!dev->rotational) - blk_queue_flag_set(QUEUE_FLAG_NONROT, dev->queue); + /* + * Network device does not need rotational + */ + blk_queue_flag_set(QUEUE_FLAG_NONROT, dev->queue); err = add_disk(dev->gd); if (err) blk_cleanup_disk(dev->gd); @@ -1610,13 +1611,13 @@ struct rnbd_clt_dev *rnbd_clt_map_device(const char *sessname, } rnbd_clt_info(dev, - "map_device: Device mapped as %s (nsectors: %zu, logical_block_size: %d, physical_block_size: %d, max_write_same_sectors: %d, max_discard_sectors: %d, discard_granularity: %d, discard_alignment: %d, secure_discard: %d, max_segments: %d, max_hw_sectors: %d, rotational: %d, wc: %d, fua: %d)\n", + "map_device: Device mapped as %s (nsectors: %zu, logical_block_size: %d, physical_block_size: %d, max_write_same_sectors: %d, max_discard_sectors: %d, discard_granularity: %d, discard_alignment: %d, secure_discard: %d, max_segments: %d, max_hw_sectors: %d, wc: %d, fua: %d)\n", dev->gd->disk_name, dev->nsectors, dev->logical_block_size, dev->physical_block_size, dev->max_write_same_sectors, dev->max_discard_sectors, dev->discard_granularity, dev->discard_alignment, dev->secure_discard, dev->max_segments, - dev->max_hw_sectors, dev->rotational, dev->wc, dev->fua); + dev->max_hw_sectors, dev->wc, dev->fua); mutex_unlock(&dev->lock); rnbd_clt_put_sess(sess); diff --git a/drivers/block/rnbd/rnbd-clt.h b/drivers/block/rnbd/rnbd-clt.h index 9ef8c4f306f2..715e616b8a91 100644 --- a/drivers/block/rnbd/rnbd-clt.h +++ b/drivers/block/rnbd/rnbd-clt.h @@ -118,7 +118,6 @@ struct rnbd_clt_dev { enum rnbd_access_mode access_mode; u32 nr_poll_queues; bool read_only; - bool rotational; bool wc; bool fua; u32 max_hw_sectors; diff --git a/drivers/block/rnbd/rnbd-proto.h b/drivers/block/rnbd/rnbd-proto.h index de5d5a8df81d..c4a68b3a1cbe 100644 --- a/drivers/block/rnbd/rnbd-proto.h +++ b/drivers/block/rnbd/rnbd-proto.h @@ -128,7 +128,7 @@ enum rnbd_cache_policy { * @logical_block_size: logical block size device supports in bytes * @max_segments: max segments hardware support in one transfer * @secure_discard: supports secure discard - * @rotation: is a rotational disc? + * @obsolete_rotational: obsolete, not in used. * @cache_policy: support write-back caching or FUA? */ struct rnbd_msg_open_rsp { @@ -144,7 +144,7 @@ struct rnbd_msg_open_rsp { __le16 logical_block_size; __le16 max_segments; __le16 secure_discard; - u8 rotational; + u8 obsolete_rotational; u8 cache_policy; u8 reserved[10]; }; diff --git a/drivers/block/rnbd/rnbd-srv.c b/drivers/block/rnbd/rnbd-srv.c index aafecfe97055..4f5d919f3760 100644 --- a/drivers/block/rnbd/rnbd-srv.c +++ b/drivers/block/rnbd/rnbd-srv.c @@ -568,7 +568,6 @@ static void rnbd_srv_fill_msg_open_rsp(struct rnbd_msg_open_rsp *rsp, cpu_to_le32(rnbd_dev_get_discard_alignment(rnbd_dev)); rsp->secure_discard = cpu_to_le16(rnbd_dev_get_secure_discard(rnbd_dev)); - rsp->rotational = !blk_queue_nonrot(q); rsp->cache_policy = 0; if (test_bit(QUEUE_FLAG_WC, &q->queue_flags)) rsp->cache_policy |= RNBD_WRITEBACK; -- 2.25.1 ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH for-next 0/2] Misc RNBD update 2022-01-14 15:58 [PATCH for-next 0/2] Misc RNBD update Md Haris Iqbal 2022-01-14 15:58 ` [PATCH for-next 1/2] block/rnbd-clt: fix CHECK:BRACES warning Md Haris Iqbal 2022-01-14 15:58 ` [PATCH for-next 2/2] block/rnbd: client device does not care queue/rotational Md Haris Iqbal @ 2022-01-26 13:57 ` Haris Iqbal 2022-01-26 14:01 ` Jens Axboe 3 siblings, 0 replies; 9+ messages in thread From: Haris Iqbal @ 2022-01-26 13:57 UTC (permalink / raw) To: linux-block; +Cc: axboe, hch, sagi, bvanassche, jinpu.wang On Fri, Jan 14, 2022 at 4:58 PM Md Haris Iqbal <haris.iqbal@ionos.com> wrote: > > Hi Jens, > > Please consider to include following change for next merge window. > - fixes warning generated from checkpatch > - removes rotational param from RNBD device Ping. > > Gioh Kim (2): > block/rnbd-clt: fix CHECK:BRACES warning > block/rnbd: client device does not care queue/rotational > > drivers/block/rnbd/rnbd-clt.c | 15 ++++++++------- > drivers/block/rnbd/rnbd-clt.h | 1 - > drivers/block/rnbd/rnbd-proto.h | 4 ++-- > drivers/block/rnbd/rnbd-srv.c | 1 - > 4 files changed, 10 insertions(+), 11 deletions(-) > > -- > 2.25.1 > ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH for-next 0/2] Misc RNBD update 2022-01-14 15:58 [PATCH for-next 0/2] Misc RNBD update Md Haris Iqbal ` (2 preceding siblings ...) 2022-01-26 13:57 ` [PATCH for-next 0/2] Misc RNBD update Haris Iqbal @ 2022-01-26 14:01 ` Jens Axboe 3 siblings, 0 replies; 9+ messages in thread From: Jens Axboe @ 2022-01-26 14:01 UTC (permalink / raw) To: Md Haris Iqbal, linux-block; +Cc: hch, jinpu.wang, bvanassche, sagi On Fri, 14 Jan 2022 16:58:53 +0100, Md Haris Iqbal wrote: > Please consider to include following change for next merge window. > - fixes warning generated from checkpatch > - removes rotational param from RNBD device > > Gioh Kim (2): > block/rnbd-clt: fix CHECK:BRACES warning > block/rnbd: client device does not care queue/rotational > > [...] Applied, thanks! [1/2] block/rnbd-clt: fix CHECK:BRACES warning commit: 7cb0c32efbae2a7000f74243d8b4cab35d669cbd [2/2] block/rnbd: client device does not care queue/rotational commit: de53a6a82aad3010d7e9c3151cba5e4e46b6ec32 Best regards, -- Jens Axboe ^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH for-next 0/2] Misc RNBD update @ 2022-07-07 14:31 Md Haris Iqbal 2022-07-07 23:29 ` Jens Axboe 0 siblings, 1 reply; 9+ messages in thread From: Md Haris Iqbal @ 2022-07-07 14:31 UTC (permalink / raw) To: linux-block; +Cc: axboe, hch, sagi, bvanassche, haris.iqbal, jinpu.wang Hi Jens, Please consider to include following change for next merge window. - Fixes a minor bug - Removes a list, and replaces its use with an existing xarray Md Haris Iqbal (2): block/rnbd-srv: Set keep_id to true after mutex_trylock block/rnbd-srv: Replace sess_dev_list with index_idr drivers/block/rnbd/rnbd-srv.c | 20 +++++++++----------- drivers/block/rnbd/rnbd-srv.h | 4 ---- 2 files changed, 9 insertions(+), 15 deletions(-) -- 2.25.1 ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH for-next 0/2] Misc RNBD update 2022-07-07 14:31 Md Haris Iqbal @ 2022-07-07 23:29 ` Jens Axboe 0 siblings, 0 replies; 9+ messages in thread From: Jens Axboe @ 2022-07-07 23:29 UTC (permalink / raw) To: haris.iqbal, linux-block; +Cc: hch, bvanassche, sagi, jinpu.wang On Thu, 7 Jul 2022 16:31:20 +0200, Md Haris Iqbal wrote: > Please consider to include following change for next merge window. > - Fixes a minor bug > - Removes a list, and replaces its use with an existing xarray > > Md Haris Iqbal (2): > block/rnbd-srv: Set keep_id to true after mutex_trylock > block/rnbd-srv: Replace sess_dev_list with index_idr > > [...] Applied, thanks! [1/2] block/rnbd-srv: Set keep_id to true after mutex_trylock commit: 5ba7b490d9fce87b2aea9de27e13da6ef5300a17 [2/2] block/rnbd-srv: Replace sess_dev_list with index_idr commit: cf9db9e0f6fd15aa044d32e4018c3a572534a9a7 Best regards, -- Jens Axboe ^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH for-next 0/2] Misc RNBD update @ 2021-07-26 11:59 Jack Wang 2021-07-27 22:48 ` Jens Axboe 0 siblings, 1 reply; 9+ messages in thread From: Jack Wang @ 2021-07-26 11:59 UTC (permalink / raw) To: linux-block; +Cc: axboe, hch, sagi, bvanassche, haris.iqbal, jinpu.wang Hi Jens, Please consider to include following change for next merge window. - one fix for wrong api usage. - one sysfs_emit conversion for sysfs access. Regards! Gioh Kim (1): block/rnbd-clt: Use put_cpu_ptr after get_cpu_ptr Md Haris Iqbal (1): block/rnbd: Use sysfs_emit instead of s*printf function for sysfs show drivers/block/rnbd/rnbd-clt-sysfs.c | 33 +++++++++++++---------------- drivers/block/rnbd/rnbd-clt.c | 2 +- drivers/block/rnbd/rnbd-srv-sysfs.c | 14 ++++++------ 3 files changed, 23 insertions(+), 26 deletions(-) -- 2.25.1 ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH for-next 0/2] Misc RNBD update 2021-07-26 11:59 Jack Wang @ 2021-07-27 22:48 ` Jens Axboe 0 siblings, 0 replies; 9+ messages in thread From: Jens Axboe @ 2021-07-27 22:48 UTC (permalink / raw) To: Jack Wang, linux-block; +Cc: hch, sagi, bvanassche, haris.iqbal On 7/26/21 5:59 AM, Jack Wang wrote: > Hi Jens, > > Please consider to include following change for next merge window. > - one fix for wrong api usage.> - one sysfs_emit conversion for sysfs access. Applied, thanks. -- Jens Axboe ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2022-07-07 23:29 UTC | newest] Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2022-01-14 15:58 [PATCH for-next 0/2] Misc RNBD update Md Haris Iqbal 2022-01-14 15:58 ` [PATCH for-next 1/2] block/rnbd-clt: fix CHECK:BRACES warning Md Haris Iqbal 2022-01-14 15:58 ` [PATCH for-next 2/2] block/rnbd: client device does not care queue/rotational Md Haris Iqbal 2022-01-26 13:57 ` [PATCH for-next 0/2] Misc RNBD update Haris Iqbal 2022-01-26 14:01 ` Jens Axboe -- strict thread matches above, loose matches on Subject: below -- 2022-07-07 14:31 Md Haris Iqbal 2022-07-07 23:29 ` Jens Axboe 2021-07-26 11:59 Jack Wang 2021-07-27 22:48 ` Jens Axboe
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.