From: NeilBrown <neilb@suse.com>
To: Shaohua Li <shli@kernel.org>
Cc: linux-raid@vger.kernel.org, kumba@gentoo.org,
Shaohua Li <shli@fb.com>, Song Liu <songliubraving@fb.com>
Subject: Re: [PATCH] md/bitmap: avoid read out of the disk
Date: Fri, 13 Oct 2017 08:44:17 +1100 [thread overview]
Message-ID: <87tvz4m47i.fsf@notabene.neil.brown.name> (raw)
In-Reply-To: <20171012173019.c2bbfyz3hgudjbhz@kernel.org>
[-- Attachment #1: Type: text/plain, Size: 2143 bytes --]
On Thu, Oct 12 2017, Shaohua Li wrote:
> On Thu, Oct 12, 2017 at 02:09:21PM +1100, Neil Brown wrote:
>> On Tue, Oct 10 2017, Shaohua Li wrote:
>>
>> > From: Shaohua Li <shli@fb.com>
>> >
>> > If PAGE_SIZE is bigger than 4k, we could read out of the disk boundary. Limit
>> > the read size to the end of disk. Write path already has similar limitation.
>> >
>> > Fix: 8031c3ddc70a(md/bitmap: copy correct data for bitmap super)
>> > Reported-by: Joshua Kinard <kumba@gentoo.org>
>> > Tested-by: Joshua Kinard <kumba@gentoo.org>
>> > Cc: Song Liu <songliubraving@fb.com>
>> > Signed-off-by: Shaohua Li <shli@fb.com>
>>
>> Given that this bug was introduced by
>> Commit: 8031c3ddc70a ("md/bitmap: copy correct data for bitmap super")
>>
>> and that patch is markted:
>>
>> Cc: stable@vger.kernel.org (4.10+)
>>
>> I think this patch should be tagged "CC: stable" too.
>
> I thought the Fix tag is enough, but I'll add the stable
My experience is that Fixes: sometimes causes patched to go to stable,
but not always. Cc: stable *always* causes the stable team to look at
the patch.
I prefer to keep each having a well defined meaning. Fixes is
documentation about a relationship between commits, Cc:stable is a
statement about the importance of a patch.
Thanks,
Neilbrown
>> However ... that earlier patch looks strange to me.
>> Why is it that "raid5 cache could write bitmap superblock before bitmap superblock is
>> initialized." Can we just get raid5 cache *not* to write the bitmap
>> superblock too early?
>> I think that would better than breaking code that previously worked.
>
> That's the log reply code, which must update superblock and hence bitmap
> superblock, because reply happens very earlier. I agree the reply might still
> have problem with bitmap. We'd better defer reply after the raid is fully
> initialized. Song, any idea?
>
> Thanks,
> Shaohua
> --
> To unsubscribe from this list: send the line "unsubscribe linux-raid" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]
prev parent reply other threads:[~2017-10-12 21:44 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-10 21:20 [PATCH] md/bitmap: avoid read out of the disk Shaohua Li
2017-10-11 12:41 ` Joshua Kinard
2017-10-12 3:09 ` NeilBrown
2017-10-12 17:30 ` Shaohua Li
2017-10-12 17:53 ` Song Liu
2017-10-12 21:46 ` NeilBrown
2017-10-12 22:51 ` Shaohua Li
2017-10-13 5:16 ` NeilBrown
2017-10-13 19:51 ` Shaohua Li
2017-10-16 16:21 ` Song Liu
2017-10-16 21:15 ` NeilBrown
2017-10-16 23:56 ` Shaohua Li
2017-10-17 3:24 ` [PATCH] md: forbid a RAID5 from having both a bitmap and a journal NeilBrown
2017-10-17 20:41 ` John Stoffel
2017-10-17 21:03 ` NeilBrown
2017-10-18 1:51 ` Joshua Kinard
2017-10-19 23:16 ` Wols Lists
2017-10-18 14:48 ` John Stoffel
2017-10-19 23:21 ` Wols Lists
2017-10-18 1:50 ` Joshua Kinard
2017-10-19 3:16 ` Shaohua Li
2017-10-12 21:44 ` NeilBrown [this message]
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=87tvz4m47i.fsf@notabene.neil.brown.name \
--to=neilb@suse.com \
--cc=kumba@gentoo.org \
--cc=linux-raid@vger.kernel.org \
--cc=shli@fb.com \
--cc=shli@kernel.org \
--cc=songliubraving@fb.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;
as well as URLs for NNTP newsgroup(s).