summaryrefslogtreecommitdiff
path: root/distrib
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2022-01-11 00:58:33 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2022-01-11 00:58:33 +0000
commit2c65adb045c78d23b39a60a04072f49a04d6fab4 (patch)
tree1e60cb34c255a1ee6fb6f861ad272252cfc30869 /distrib
parent834999b52b6fd4e5a1945d3fcc3377f3ecfa3024 (diff)
If the install media contains non-free /*firmware*.tgz files, use fw_update
to install them. This lets users usb-lift firmware on a preloaded install70.img image like this: # vnconfig install70.img vnd0 # (mount /dev/vnd0a /mnt && cd /mnt && fw_update -F iwm iwx iwn intel) # umount /mnt && vnconfig -u vnd0 The firmwares are installed after the sets, then all network drivers are re-configured in the hope that new firmwares have showed up. The install script continues to attempt a network firmware install, which might pull/update additional firmwares. work done with afresh1
Diffstat (limited to 'distrib')
-rw-r--r--distrib/miniroot/install.sub8
1 files changed, 7 insertions, 1 deletions
diff --git a/distrib/miniroot/install.sub b/distrib/miniroot/install.sub
index e40e36423a0..76d0b68890a 100644
--- a/distrib/miniroot/install.sub
+++ b/distrib/miniroot/install.sub
@@ -1,5 +1,5 @@
#!/bin/ksh
-# $OpenBSD: install.sub,v 1.1188 2022/01/11 00:48:45 deraadt Exp $
+# $OpenBSD: install.sub,v 1.1189 2022/01/11 00:58:32 deraadt Exp $
#
# Copyright (c) 1997-2015 Todd Miller, Theo de Raadt, Ken Westerback
# Copyright (c) 2015, Robert Peichaer <rpe@openbsd.org>
@@ -2739,6 +2739,12 @@ install_sets() {
# Preserve the selected install source selection.
[[ -n $INSTALL_METHOD ]] && _d=$INSTALL_METHOD
+ if [ -x /mnt/usr/sbin/fw_update -a \
+ "$(echo /mnt2/*firmware*tgz)" != "/mnt2/*firmware*tgz" ]; then
+ DESTDIR=/mnt /mnt/usr/sbin/fw_update /mnt2/*firmware*tgz
+ enable_ifs # try again with firmwares
+ fi
+
# Set default to 'done' to leave the while-loop.
sane_install quiet || $AI && _d=done
done