-# $OpenBSD: install.md,v 1.38 2023/03/26 19:25:16 kn Exp $
+# $OpenBSD: install.md,v 1.39 2023/03/29 00:16:14 kn Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
MOUNT_ARGS_msdos="-o-l"
md_installboot() {
- local _disk=/dev/$1 _mdec _plat
+ local _disk=$1 _mdec _plat
case $(sysctl -n machdep.compatible) in
apple,*) _plat=apple;;
done)
;;
pine64)
- dd if=$_mdec/u-boot-sunxi-with-spl.bin of=${_disk}c \
+ dd if=$_mdec/u-boot-sunxi-with-spl.bin of=/dev/${_disk}c \
bs=1024 seek=8 status=none
;;
rpi)
- mount ${MOUNT_ARGS_msdos} ${_disk}i /mnt/mnt
+ mount ${MOUNT_ARGS_msdos} /dev/${_disk}i /mnt/mnt
cp $_mdec/{bootcode.bin,start*.elf,fixup*.dat,*.dtb} /mnt/mnt/
cp $_mdec/u-boot.bin /mnt/mnt/
mkdir -p /mnt/mnt/overlays
-# $OpenBSD: install.md,v 1.53 2023/03/28 23:09:08 kn Exp $
+# $OpenBSD: install.md,v 1.54 2023/03/29 00:16:14 kn Exp $
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
# All rights reserved.
MOUNT_ARGS_msdos="-o-l"
md_installboot() {
- local _disk=/dev/$1 _mdec _plat
+ local _disk=$1 _mdec _plat
case $(sysctl -n hw.product) in
*AM335x*) _plat=am335x;;
fi
# Apply some final tweaks on selected platforms
- mount ${MOUNT_ARGS_msdos} ${_disk}i /mnt/mnt
+ mount ${MOUNT_ARGS_msdos} /dev/${_disk}i /mnt/mnt
_mdec=/usr/mdec/$_plat
;;
cubox|wandboard)
cp $_mdec/*.dtb /mnt/mnt/
- dd if=$_mdec/SPL of=${_disk}c bs=1024 seek=1 \
+ dd if=$_mdec/SPL of=/dev/${_disk}c bs=1024 seek=1 \
status=none
- dd if=$_mdec/u-boot.img of=${_disk}c bs=1024 seek=69 \
+ dd if=$_mdec/u-boot.img of=/dev/${_disk}c bs=1024 seek=69 \
status=none
;;
nitrogen)
;;
cubie)
cp $_mdec/*.dtb /mnt/mnt/
- dd if=$_mdec/u-boot-sunxi-with-spl.bin of=${_disk}c \
+ dd if=$_mdec/u-boot-sunxi-with-spl.bin of=/dev/${_disk}c \
bs=1024 seek=8 status=none
;;
esac