All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Add error handling for chunk size in RAID1
@ 2021-07-15 10:25 Mateusz Grzonka
  2021-07-16 14:31 ` Jes Sorensen
  0 siblings, 1 reply; 2+ messages in thread
From: Mateusz Grzonka @ 2021-07-15 10:25 UTC (permalink / raw)
  To: linux-raid; +Cc: jes

Print error if chunk size is set as it is not supported.

Signed-off-by: Mateusz Grzonka <mateusz.grzonka@intel.com>
---
 Create.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/Create.c b/Create.c
index 18b5e646..f5d57f8c 100644
--- a/Create.c
+++ b/Create.c
@@ -254,9 +254,8 @@ int Create(struct supertype *st, char *mddev,
 	case LEVEL_MULTIPATH:
 	case LEVEL_CONTAINER:
 		if (s->chunk) {
-			s->chunk = 0;
-			if (c->verbose > 0)
-				pr_err("chunk size ignored for this level\n");
+			pr_err("specifying chunk size is forbidden for this level\n");
+			return 1;
 		}
 		break;
 	default:
-- 
2.26.2


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] Add error handling for chunk size in RAID1
  2021-07-15 10:25 [PATCH] Add error handling for chunk size in RAID1 Mateusz Grzonka
@ 2021-07-16 14:31 ` Jes Sorensen
  0 siblings, 0 replies; 2+ messages in thread
From: Jes Sorensen @ 2021-07-16 14:31 UTC (permalink / raw)
  To: Mateusz Grzonka, linux-raid

On 7/15/21 6:25 AM, Mateusz Grzonka wrote:
> Print error if chunk size is set as it is not supported.
> 
> Signed-off-by: Mateusz Grzonka <mateusz.grzonka@intel.com>
> ---
>  Create.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)

Applied!

Thanks,
Jes


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-07-16 14:32 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-15 10:25 [PATCH] Add error handling for chunk size in RAID1 Mateusz Grzonka
2021-07-16 14:31 ` Jes Sorensen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.