Subject: [PATCH] mdadm: raid0: support chunks of 4K*n for raid0

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Neil.
I do not know what is policy for mdadm patches. I would thankful for some instructions.
The bellow is the patch I applied to support raid0 chunk sizes 4K*n.
---
--- mdadm.c	(revision 16152)
+++ mdadm.c	(working copy)
@@ -314,7 +314,8 @@
 				exit(2);
 			}
 			chunk = strtol(optarg, &c, 10);
-			if (!optarg[0] || *c || chunk<4 || (chunk%4)) {
+			if (!optarg[0] || *c || chunk<4 ||  (((chunk-1)&chunk) && level !=0)
+					||  (((chunk%4) && level ==0) )) {
 				fprintf(stderr, Name ": invalid chunk/rounding value: %s\n",
 					optarg);
 				exit(2);


--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux