r212 - in mdadm/trunk/debian: . patches
madduck at users.alioth.debian.org
madduck at users.alioth.debian.org
Tue Oct 10 08:00:20 UTC 2006
Author: madduck
Date: 2006-10-10 08:00:19 +0000 (Tue, 10 Oct 2006)
New Revision: 212
Removed:
mdadm/trunk/debian/patches/50-superblock-partition-limit.dpatch
Modified:
mdadm/trunk/debian/changelog
Log:
removing superblock overlap patch
Modified: mdadm/trunk/debian/changelog
===================================================================
--- mdadm/trunk/debian/changelog 2006-10-08 11:54:34 UTC (rev 211)
+++ mdadm/trunk/debian/changelog 2006-10-10 08:00:19 UTC (rev 212)
@@ -1,3 +1,16 @@
+mdadm (2.5.3.git200610100838-1) unstable; urgency=low
+
+ * Merged upstream changes:
+ - --examine now reports chunk size also for RAID6 and RAID10
+ - fix endianness issues with v1 superblocks (closes: #385726) and bitmap
+ metadata.
+ - improved the message when mdadm detects similar superblocks
+ (closes: #385951).
+ * Removed patch previously used to fix #385951 because it's not adequate.
+ See the bug log for reasons.
+
+ -- martin f. krafft <madduck at debian.org> Tue, 10 Oct 2006 08:38:50 +0200
+
mdadm (2.5.3.git200608202239-8) unstable; urgency=low
* This revision is dedicated to Peter Samuelson for his RAID10 expertise^W
Deleted: mdadm/trunk/debian/patches/50-superblock-partition-limit.dpatch
===================================================================
--- mdadm/trunk/debian/patches/50-superblock-partition-limit.dpatch 2006-10-08 11:54:34 UTC (rev 211)
+++ mdadm/trunk/debian/patches/50-superblock-partition-limit.dpatch 2006-10-10 08:00:19 UTC (rev 212)
@@ -1,128 +0,0 @@
-#! /bin/sh /usr/share/dpatch/dpatch-run
-## 50-superblock-partition-limit.dpatch by martin f. krafft <madduck at debian.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: No description.
-
- at DPATCH@
-diff -urNad mdadm.git~/config.c mdadm.git/config.c
---- mdadm.git~/config.c 2006-09-20 17:53:00.863178469 +0200
-+++ mdadm.git/config.c 2006-09-21 15:35:17.513157034 +0200
-@@ -219,31 +219,105 @@
- char *name;
- } *cdevlist = NULL;
-
-+char* skipblanks(char* buf)
-+{
-+ if (!buf) return buf;
-+ while (*buf != '\0' && isblank(*buf)) ++buf;
-+ return buf;
-+}
-+
-+char* skipnonblanks(char* buf)
-+{
-+ if (!buf) return buf;
-+ while (*buf != '\0' && !isblank(*buf)) ++buf;
-+ return buf;
-+}
-+
-+char* skipdigits(char* buf)
-+{
-+ if (!buf) return buf;
-+ while (*buf != '\0' && isdigit(*buf)) ++buf;
-+ return buf;
-+}
-+
- mddev_dev_t load_partitions(void)
- {
- FILE *f = fopen("/proc/partitions", "r");
-- char buf[1024];
-+ char buf[1024], last_device_name[1024];
-+ int last_major = -1;
- mddev_dev_t rv = NULL;
- if (f == NULL) {
- fprintf(stderr, Name ": cannot open /proc/partitions\n");
- return NULL;
- }
-- while (fgets(buf, 1024, f)) {
-- int major, minor;
-- char *name, *mp;
-+ while (!feof(f) && fgets(buf, 1024, f)) {
-+ unsigned long major, minor;
-+ char *name, *kernel_name, *mp, *ptr;
- mddev_dev_t d;
-
-- buf[1023] = '\0';
-- if (buf[0] != ' ')
-- continue;
-+ /*
-+ * All partition lines start with a space.
-+ */
-+ if (buf[0] != ' ') continue;
-+
-+ /*
-+ * Chop at the end of each line.
-+ */
-+ ptr = strchr(buf, '\n');
-+ if (ptr) *ptr = '\0';
-+
-+ /*
-+ * Extract the major and minor numbers and obtain the device node name.
-+ * 10 is the max number of digits expected in a major/minor number
-+ * (32bit).
-+ */
- major = strtoul(buf, &mp, 10);
-- if (mp == buf || *mp != ' ')
-- continue;
-- minor = strtoul(mp, NULL, 10);
-+ if (mp == buf || *mp != ' ') continue;
-+ mp = skipblanks(mp);
-+ minor = strtoul(mp, &mp, 10);
-+ mp = skipblanks(mp);
-
- name = map_dev(major, minor, 1);
-- if (!name)
-- continue;
-+ if (!name) continue;
-+
-+ /*
-+ * mp now points at the third field, which is digits only. We thus skip
-+ * all spaces and digits to reach the forth field.
-+ */
-+ mp = skipdigits(mp);
-+ mp = skipblanks(mp);
-+
-+ /*
-+ * Now the cursor is at the beginning to the kernel name, so we point
-+ * there and terminate the string on the first space character.
-+ */
-+ kernel_name = mp;
-+ mp = skipnonblanks(mp);
-+ *mp = '\0';
-+
-+ /*
-+ * Check if this could be a partition of the previous device
-+ * (the disk _always_ comes just before the first partition, cf.
-+ * /usr/src/linux/fs/partitions/check.c)
-+ */
-+ if (major == last_major && strlen(kernel_name) > strlen(last_device_name) &&
-+ strncmp(kernel_name, last_device_name, strlen(last_device_name)) == 0 &&
-+ isdigit(kernel_name[strlen(kernel_name) - 1])) {
-+ /*
-+ * The previous device appears to have a partition table, so delete it
-+ * so it isn't scanned for a superblock. This makes sure we don't get
-+ * confused when a partition with an md superblock lives very close to
-+ * the end of a disk.
-+ */
-+ d = rv->next;
-+ free(rv->devname);
-+ free(rv);
-+ rv = d;
-+ }
-+
-+ last_major = major;
-+ strcpy(last_device_name, kernel_name);
-+
- d = malloc(sizeof(*d));
- d->devname = strdup(name);
- d->next = rv;
More information about the pkg-mdadm-commits
mailing list