From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: linan666@huaweicloud.com
Cc: <song@kernel.org>, <yukuai3@huawei.com>,
<martin.petersen@oracle.com>, <hare@suse.de>, <axboe@kernel.dk>,
<linux-raid@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<bvanassche@acm.org>, <hch@infradead.org>,
<filipe.c.maia@gmail.com>, <yangerkun@huawei.com>,
<yi.zhang@huawei.com>
Subject: Re: [PATCH v2 3/3] md: Fix the return value of mddev_stack_new_rdev
Date: Thu, 31 Jul 2025 01:01:05 -0400 [thread overview]
Message-ID: <yq1bjp1ge13.fsf@ca-mkp.ca.oracle.com> (raw)
In-Reply-To: <20250719083119.1068811-4-linan666@huaweicloud.com> (linan's message of "Sat, 19 Jul 2025 16:31:19 +0800")
> In mddev_stack_new_rdev(), if the integrity profile check fails, it
> returns -ENXIO, which means "No such device or address". This is
> inaccurate and can mislead users. Change it to return -EINVAL.
> Fixes: c6e56cf6b2e7 ("block: move integrity information into queue_limits")
Returning -ENXIO predates the above commit by many, many years. Changing
the return value might break applications which rely on the original
behavior.
In case of a stacking failure, an appropriate message is logged and the
function returns an errno. How is that misleading?
--
Martin K. Petersen
next prev parent reply other threads:[~2025-07-31 5:01 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-19 8:31 [PATCH v2 0/3] make logical_block_size configurable linan666
2025-07-19 8:31 ` [PATCH v2 1/3] md: prevent adding disks with larger logical_block_size to active arrays linan666
2025-07-31 5:01 ` Martin K. Petersen
2025-07-19 8:31 ` [PATCH v2 2/3] md: allow configuring logical_block_size linan666
2025-07-31 5:36 ` Martin K. Petersen
2025-07-31 7:02 ` Yu Kuai
2025-07-19 8:31 ` [PATCH v2 3/3] md: Fix the return value of mddev_stack_new_rdev linan666
2025-07-31 5:01 ` Martin K. Petersen [this message]
2025-08-25 1:26 ` Li Nan
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=yq1bjp1ge13.fsf@ca-mkp.ca.oracle.com \
--to=martin.petersen@oracle.com \
--cc=axboe@kernel.dk \
--cc=bvanassche@acm.org \
--cc=filipe.c.maia@gmail.com \
--cc=hare@suse.de \
--cc=hch@infradead.org \
--cc=linan666@huaweicloud.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-raid@vger.kernel.org \
--cc=song@kernel.org \
--cc=yangerkun@huawei.com \
--cc=yi.zhang@huawei.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
all inboxes | Powered by JetHome®