Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/distrib/utils/embedded Derive the FAT type from the MBR part...
details: https://anonhg.NetBSD.org/src/rev/b51c6cb85473
branches: trunk
changeset: 966461:b51c6cb85473
user: martin <martin%NetBSD.org@localhost>
date: Wed Oct 30 14:16:15 2019 +0000
description:
Derive the FAT type from the MBR partition type and pass it on to makefs
when crating a msdos file system.
diffstat:
distrib/utils/embedded/mkimage | 11 +++++++++--
1 files changed, 9 insertions(+), 2 deletions(-)
diffs (26 lines):
diff -r 38084e93b66e -r b51c6cb85473 distrib/utils/embedded/mkimage
--- a/distrib/utils/embedded/mkimage Wed Oct 30 13:32:32 2019 +0000
+++ b/distrib/utils/embedded/mkimage Wed Oct 30 14:16:15 2019 +0000
@@ -1,5 +1,5 @@
#!/bin/sh
-# $NetBSD: mkimage,v 1.70 2019/10/02 11:16:00 maya Exp $
+# $NetBSD: mkimage,v 1.71 2019/10/30 14:16:15 martin Exp $
#
# Copyright (c) 2013, 2014 The NetBSD Foundation, Inc.
# All rights reserved.
@@ -217,7 +217,14 @@
if [ -n "${msdosid}" ]; then
echo ${bar} Populating msdos filesystem ${bar}
- ${MAKEFS} -N ${release}/etc -t msdos -o volume_label=NETBSD \
+ case $(( ${msdosid} )) in
+ 1) fat_opt=",fat_type=12";;
+ 4|6|14) fat_opt=",fat_type=16";;
+ 11|12) fat_opt=",fat_type=32";;
+ *) fat_opt=;;
+ esac
+ ${MAKEFS} -N ${release}/etc -t msdos \
+ -o "volume_label=NETBSD${fat_opt}" \
-O $((${init} / 2))m -s $((${boot} / 2))m \
${image} ${mnt}/boot
fi
Home |
Main Index |
Thread Index |
Old Index