[kernel] r15485 - dists/sid/linux-2.6/debian

Ben Hutchings benh at alioth.debian.org
Sun Apr 4 23:07:22 UTC 2010


Author: benh
Date: Sun Apr  4 23:07:13 2010
New Revision: 15485

Log:
linux-base: Report when hdparm.conf or mdadm.conf may need to be updated (Closes: #576442)

Modified:
   dists/sid/linux-2.6/debian/changelog
   dists/sid/linux-2.6/debian/linux-base.postinst

Modified: dists/sid/linux-2.6/debian/changelog
==============================================================================
--- dists/sid/linux-2.6/debian/changelog	Sun Apr  4 23:05:37 2010	(r15484)
+++ dists/sid/linux-2.6/debian/changelog	Sun Apr  4 23:07:13 2010	(r15485)
@@ -23,6 +23,8 @@
   * linux-base: Redirect stdin and stdout of child processes to avoid
     interfering with debconf (Closes: #574987)
   * [x86] Add ramzswap driver (Closes: #573912)
+  * linux-base: Report when hdparm.conf or mdadm.conf may need to be updated
+    (Closes: #576442)
 
   [ maximilian attems]
   * [alpha, hppa] Disable oprofile as tracing code is unsupported here.

Modified: dists/sid/linux-2.6/debian/linux-base.postinst
==============================================================================
--- dists/sid/linux-2.6/debian/linux-base.postinst	Sun Apr  4 23:05:37 2010	(r15484)
+++ dists/sid/linux-2.6/debian/linux-base.postinst	Sun Apr  4 23:07:13 2010	(r15485)
@@ -887,6 +887,23 @@
     }
 }
 
+# hdparm
+
+sub hdparm_list {
+    my ($file) = @_;
+    my (@results) = ();
+
+    # I really can't be bothered to parse this mess.  Just see if
+    # there's anything like a device name on a non-comment line.
+    while (<$file>) {
+	if (!/^\s*#/) {
+	    push @results, grep({m|^/dev/|} split(/\s+/));
+	}
+    }
+
+    return @results;
+}
+
 ### list of all configuration files and functions
 
 my @config_files = ({packages => 'mount',
@@ -963,7 +980,18 @@
 		    {packages => 'cryptsetup',
 		     path => '/etc/crypttab',
 		     list => \&cryptsetup_list,
-		     update => \&cryptsetup_update});
+		     update => \&cryptsetup_update},
+		    # mdadm.conf requires manual update because it may
+		    # contain wildcards.
+		    {packages => 'mdadm',
+		     path => '/etc/mdadm/mdadm.conf'},
+		    # hdparm.conf requires manual update because it
+		    # (1) refers to whole disks (2) might not work
+		    # properly with the new drivers (3) is in a very
+		    # special format.
+		    {packages => 'hdparm',
+		     path => '/etc/hdparm.conf',
+		     list => \&hdparm_list});
 
 ### Filesystem labels and UUIDs
 



More information about the Kernel-svn-changes mailing list