mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: syzbot <syzbot+6a132745caefcf42cb0d@syzkaller.appspotmail.com>
To: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: Forwarded: [PATCH] Test for a forgotten shrink_stripes in the grow_stripes.
Date: Sun, 27 Sep 2026 06:07:45 -0700	[thread overview]
Message-ID: <6ab91521.80e1c6cc.1e8e5f.0059.GAE@google.com> (raw)
In-Reply-To: <6ab10ffa.a6af0033.177e91.0014.GAE@google.com>

For archival purposes, forwarding an incoming command email to
linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com.

***

Subject: [PATCH] Test for a forgotten shrink_stripes in the grow_stripes.
Author: nsvatoslav515@gmail.com

#syz test: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 6812ce4e4379

Signed-off-by: Svyatoslav Nikolenko <nsvatoslav515@gmail.com>
---
 drivers/md/raid5.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
index b91545ce090d..326409ca0cfb 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -1,4 +1,4 @@
-// SPDX-License-Identifier: GPL-2.0-or-later
+/// SPDX-License-Identifier: GPL-2.0-or-later
 /*
  * raid5.c : Multiple Devices driver for Linux
  *	   Copyright (C) 1996, 1997 Ingo Molnar, Miguel de Icaza, Gadi Oxman
@@ -2441,9 +2441,12 @@ static int grow_stripes(struct r5conf *conf, int num)
 	conf->pool_size = devs;
 	while (num--)
 		if (!grow_one_stripe(conf, GFP_KERNEL))
-			return 1;
+			goto err;
 
 	return 0;
+err:
+	shrink_stripes(conf);
+	return 1;
 }
 
 /**
-- 
2.47.3


      parent reply	other threads:[~2026-09-27 13:07 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-21 11:07 [syzbot] [raid?] WARNING in free_conf syzbot
2026-09-25 18:02 ` syzbot
2026-09-27 13:07 ` syzbot [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=6ab91521.80e1c6cc.1e8e5f.0059.GAE@google.com \
    --to=syzbot+6a132745caefcf42cb0d@syzkaller.appspotmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syzkaller-bugs@googlegroups.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®