mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Yu Kuai <yukuai3@huawei.com>
To: "Mateusz Jończyk" <mat.jonczyk@o2.pl>,
	linux-raid@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: <regressions@lists.linux.dev>, Song Liu <song@kernel.org>,
	Paul Luse <paul.e.luse@linux.intel.com>,
	"yukuai (C)" <yukuai3@huawei.com>
Subject: Re: [REGRESSION] Cannot start degraded RAID1 array with device with write-mostly flag
Date: Mon, 8 Jul 2024 09:54:28 +0800	[thread overview]
Message-ID: <a703ec45-6cd5-4970-db22-fb9e7469332a@huawei.com> (raw)
In-Reply-To: <20240706143038.7253-1-mat.jonczyk@o2.pl>

Hi,

在 2024/07/06 22:30, Mateusz Jończyk 写道:
> Subject: [RFC PATCH] md/raid1: fill in max_sectors
> 
> 
> 
> Not yet fully tested or carefully investigated.
> 
> 
> 
> Signed-off-by: Mateusz Jo艅czyk<mat.jonczyk@o2.pl>
> 
> 
> 
> ---
> 
>   drivers/md/raid1.c | 1 +
> 
>   1 file changed, 1 insertion(+)
> 
> 
> 
> diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c
> 
> index 7b8a71ca66dd..82f70a4ce6ed 100644
> 
> --- a/drivers/md/raid1.c
> 
> +++ b/drivers/md/raid1.c
> 
> @@ -680,6 +680,7 @@ static int choose_slow_rdev(struct r1conf *conf, struct r1bio *r1_bio,
> 
>   		len = r1_bio->sectors;
> 
>   		read_len = raid1_check_read_range(rdev, this_sector, &len);
> 
>   		if (read_len == r1_bio->sectors) {
> 
> +			*max_sectors = read_len;
> 
>   			update_read_sectors(conf, disk, this_sector, read_len);
> 
>   			return disk;
> 
>   		}

This looks correct, can you give it a test and cook a patch?

Thanks,
Kuai

  parent reply	other threads:[~2024-07-08  2:11 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-06 14:30 Mateusz Jończyk
2024-07-07 19:50 ` Mateusz Jończyk
2024-07-08  1:54 ` Yu Kuai [this message]
2024-07-08 20:09   ` Mateusz Jończyk
2024-07-09  2:57     ` Yu Kuai
2024-07-11 20:23       ` [PATCH] md/raid1: set max_sectors during early return from choose_slow_rdev() Mateusz Jończyk
2024-07-11 21:14         ` Paul E Luse
2024-07-12  1:16         ` Yu Kuai
2024-07-12 15:11           ` Song Liu
2024-07-13 12:40           ` Mateusz Jończyk

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=a703ec45-6cd5-4970-db22-fb9e7469332a@huawei.com \
    --to=yukuai3@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-raid@vger.kernel.org \
    --cc=mat.jonczyk@o2.pl \
    --cc=paul.e.luse@linux.intel.com \
    --cc=regressions@lists.linux.dev \
    --cc=song@kernel.org \
    /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®