[PATCH 5/9] nvme: drop unreachable "off" case in reconnect_delay_show()
sashiko-bot at kernel.org
sashiko-bot at kernel.org
Wed Nov 4 18:20:34 PST 2026
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] nvme: Documentation/ABI/stable/sysfs-nvme out of sync for reconnect_delay
--
commit 0bdac7a94ae088ab38d8d6006c42a68c7d0447dc
Author: Guixin Liu <kanie at linux.alibaba.com>
nvme: drop unreachable "off" case in reconnect_delay_show()
This commit removes the check for ctrl->opts->reconnect_delay == -1 in
nvme_ctrl_reconnect_delay_show() so that reading reconnect_delay no longer
emits "off".
> diff --git a/drivers/nvme/host/sysfs.c b/drivers/nvme/host/sysfs.c
> index 10018c6356b62..3724b5ce03a07 100644
> --- a/drivers/nvme/host/sysfs.c
> +++ b/drivers/nvme/host/sysfs.c
> @@ -618,8 +618,6 @@ static ssize_t nvme_ctrl_reconnect_delay_show(struct device *dev,
> {
> struct nvme_ctrl *ctrl = dev_get_drvdata(dev);
>
> - if (ctrl->opts->reconnect_delay == -1)
> - return sysfs_emit(buf, "off\n");
> return sysfs_emit(buf, "%d\n", ctrl->opts->reconnect_delay);
[Severity: Low]
With this branch removed from nvme_ctrl_reconnect_delay_show() in
drivers/nvme/host/sysfs.c, reading /sys/class/nvme/nvmeX/reconnect_delay
never outputs "off". However, Documentation/ABI/stable/sysfs-nvme still
states:
reconnect_delay: Shows or sets the reconnect delay in
seconds. Reading returns the delay value, or "off" if
disabled.
Should Documentation/ABI/stable/sysfs-nvme be updated to drop the "off"
description as well?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261105021051.1667222-1-kanie@linux.alibaba.com?part=5
More information about the Linux-nvme
mailing list