[arch-commits] Commit in mkinitcpio/trunk (2 files)

Dave Reisner dreisner at archlinux.org
Tue Oct 9 14:18:46 UTC 2018


    Date: Tuesday, October 9, 2018 @ 14:18:46
  Author: dreisner
Revision: 336057

upgpkg: mkinitcpio 24-3

- backport fix for https://bugs.archlinux.org/task/60272

Added:
  mkinitcpio/trunk/0001-install-block-avoid-conditional-addition-of-drivers.patch
Modified:
  mkinitcpio/trunk/PKGBUILD

----------------------------------------------------------------+
 0001-install-block-avoid-conditional-addition-of-drivers.patch |   65 ++++++++++
 PKGBUILD                                                       |    9 -
 2 files changed, 71 insertions(+), 3 deletions(-)

Added: 0001-install-block-avoid-conditional-addition-of-drivers.patch
===================================================================
--- 0001-install-block-avoid-conditional-addition-of-drivers.patch	                        (rev 0)
+++ 0001-install-block-avoid-conditional-addition-of-drivers.patch	2018-10-09 14:18:46 UTC (rev 336057)
@@ -0,0 +1,65 @@
+From a3cb799a8f63186b843db6a57da12d74a9320686 Mon Sep 17 00:00:00 2001
+From: Dave Reisner <dreisner at archlinux.org>
+Date: Mon, 8 Oct 2018 19:45:11 -0400
+Subject: [subjectprefix = mkinitcpio] [PATCH] install/block: avoid conditional
+ addition of drivers
+
+Avoid over-optimizing autodetect and always add these. This allows
+storage drivers to be builtins and still trigger addition of the block
+node driver.
+---
+ install/block | 25 ++++++++-----------------
+ 1 file changed, 8 insertions(+), 17 deletions(-)
+
+diff --git a/install/block b/install/block
+index d9c627f..11c4665 100644
+--- a/install/block
++++ b/install/block
+@@ -2,36 +2,27 @@
+ 
+ build() {
+     local filter
+-    local -A blockdevs
++
++    map add_module sd_mod? sr_mod? usb_storage? mmc_block? firewire-sbp2? virtio_blk?
+ 
+     # pata, sata, scsi, nvme
+     for filter in 'scsi/.*ata' '/(block|scsi|fusion|nvme)/' 'ata/[ps]ata_' \
+             'ata/(ahci|pdc_adma|ata_piix|ata_generic)'; do
+-        add_checked_modules "$filter" && blockdevs['sd_mod']=1
++        add_checked_modules "$filter"
+     done
+ 
+     # usb
+-    if add_checked_modules -f '(_cs|sl811_hcd|isp116x_hcd)' '/usb/host'; then
+-        blockdevs+=(['usb_storage?']=1 ['sd_mod?']=1 ['sr_mod?']=1)
+-        add_checked_modules '/drivers/usb/storage/'
+-    fi
++    add_checked_modules -f '(_cs|sl811_hcd|isp116x_hcd)' '/usb/host'
++    add_checked_modules '/drivers/usb/storage/'
+ 
+     # firewire
+-    if add_checked_modules '/drivers/firewire/'; then
+-        blockdevs+=(['firewire-sbp2?']=1 ['sd_mod?']=1 ['sr_mod?']=1)
+-    fi
++    add_checked_modules '/drivers/firewire/'
+ 
+     # mmc
+-    if add_checked_modules '/(mmc|tifm_)'; then
+-        blockdevs+=(['mmc_block?']=1)
+-    fi
++    add_checked_modules '/(mmc|tifm_)'
+ 
+     # virtio
+-    if add_checked_modules 'virtio'; then
+-        blockdevs['virtio_blk?']=1
+-    fi
+-
+-    map add_module "${!blockdevs[@]}"
++    add_checked_modules 'virtio'
+ }
+ 
+ help() {
+-- 
+2.19.0
+

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2018-10-09 12:45:42 UTC (rev 336056)
+++ PKGBUILD	2018-10-09 14:18:46 UTC (rev 336057)
@@ -3,7 +3,7 @@
 
 pkgname=mkinitcpio
 pkgver=24
-pkgrel=2
+pkgrel=3
 pkgdesc="Modular initramfs image creation utility"
 arch=('any')
 url="https://projects.archlinux.org/mkinitcpio.git/"
@@ -17,11 +17,13 @@
             'mkinitcpio-nfs-utils: Support for root filesystem on NFS')
 backup=('etc/mkinitcpio.conf')
 source=("https://sources.archlinux.org/other/$pkgname/$pkgname-$pkgver.tar.gz"{,.sig}
-        0001-Restore-addition-of-modules-from-config-file.patch)
+        0001-Restore-addition-of-modules-from-config-file.patch
+        0001-install-block-avoid-conditional-addition-of-drivers.patch)
 install=mkinitcpio.install
 sha256sums=('ec0ecbc518c14ecacf5a8ece2f068fe86fcaf3aed09ee6b82737e773e5d7d02b'
             'SKIP'
-            'd4cbbf7b05f5dcaf23139469376ff6c29e948ce77a8c51ad4867413b4bddc4db')
+            'd4cbbf7b05f5dcaf23139469376ff6c29e948ce77a8c51ad4867413b4bddc4db'
+            '2ef47f6068323494bfc3181d8d34a732f8947775f6ff6e595e6f3eb4190df76e')
 validpgpkeys=('487EACC08557AD082088DABA1EB2638FF56C0C53'   # Dave Reisner
               '86CFFCA918CF3AF47147588051E8B148A9999C34')  # Evangelos Foutras
 
@@ -29,6 +31,7 @@
   cd "$pkgname-$pkgver"
 
   patch -Np1 <"$srcdir"/0001-Restore-addition-of-modules-from-config-file.patch
+  patch -Np1 <"$srcdir"/0001-install-block-avoid-conditional-addition-of-drivers.patch
 }
 
 check() {



More information about the arch-commits mailing list