Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 02 Nov 2002 23:54:47 +0900
From:      Makoto Matsushita <matusita@jp.FreeBSD.org>
To:        qa@FreeBSD.org
Subject:   Re: note about modules in mfsroot
Message-ID:  <20021102235447G.matusita@jp.FreeBSD.org>
In-Reply-To: <XFMail.20021101143742.jhb@FreeBSD.org>
References:  <XFMail.20021101143742.jhb@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help

jhb> We might consider either not copying /stand/modules from the mfsroot
jhb> over to /, or we might move the modules to /modules or some such in
jhb> the mfsroot so that they don't get copied in the first place.

IIRC, copying kernel module under /stand/modules is by *accident*;
sysinstall copies (actually not cp(1) but cpio(1)) ALL /stand files on
mfsroot to a HDD.

I second "move kernel modules to other location" idea.  It seems that
following patch will do that, but I don't test it any:

Index: Makefile
===================================================================
RCS file: /home/ncvs/src/release/Makefile,v
retrieving revision 1.718
diff -u -r1.718 Makefile
--- Makefile	2 Nov 2002 06:00:06 -0000	1.718
+++ Makefile	2 Nov 2002 14:51:54 -0000
@@ -664,11 +664,11 @@
 .endif
 .if defined(SMALLBOOTSIZE)
 .if exists(${.CURDIR}/${TARGET}/drivers-small.conf)
-	@rm -rf ${RD}/mfsfd/stand/modules
-	@mkdir -p ${RD}/mfsfd/stand/modules
+	@rm -rf ${RD}/mfsfd/modules
+	@mkdir -p ${RD}/mfsfd/modules
 	@awk -f  ${.CURDIR}/scripts/driver-copy2.awk 2 \
 	    ${.CURDIR}/${TARGET}/drivers-small.conf \
-	    ${RD}/trees/base/boot/kernel ${RD}/mfsfd/stand/modules
+	    ${RD}/trees/base/boot/kernel ${RD}/mfsfd/modules
 .endif
 	sh -e ${.CURDIR}/scripts/doFS.sh -s mfsroot-small ${RD} ${MNT} \
 		${MFSSIZE} ${RD}/mfsfd ${MFSINODE} ${MFSLABEL}
@@ -678,11 +678,11 @@
 		${BOOTINODE} ${SMALLBOOTLABEL}
 .endif
 .if exists(${.CURDIR}/${TARGET}/drivers.conf)
-	@rm -rf ${RD}/mfsfd/stand/modules
-	@mkdir -p ${RD}/mfsfd/stand/modules
+	@rm -rf ${RD}/mfsfd/modules
+	@mkdir -p ${RD}/mfsfd/modules
 	@awk -f  ${.CURDIR}/scripts/driver-copy2.awk 2 \
 	    ${.CURDIR}/${TARGET}/drivers.conf \
-	    ${RD}/trees/base/boot/kernel ${RD}/mfsfd/stand/modules
+	    ${RD}/trees/base/boot/kernel ${RD}/mfsfd/modules
 	@rm -rf ${RD}/driversfd
 	@mkdir ${RD}/driversfd
 	@awk -f  ${.CURDIR}/scripts/driver-copy2.awk 3 \
@@ -1016,7 +1016,7 @@
 .endif
 	@echo "load -t mfs_root /mfsroot" >> ${RD}/image.${FSIMAGE}/boot/loader.rc
 	@echo "set hint.acpi.0.disabled=1" >> ${RD}/image.${FSIMAGE}/boot/loader.rc
-	@echo "set module_path=\"/stand/modules;/dist\"" >> ${RD}/image.${FSIMAGE}/boot/loader.rc
+	@echo "set module_path=\"/modules;/dist\"" >> ${RD}/image.${FSIMAGE}/boot/loader.rc
 	@echo "echo \\007\\007" >> ${RD}/image.${FSIMAGE}/boot/loader.rc
 	@echo "autoboot 10" >> ${RD}/image.${FSIMAGE}/boot/loader.rc
 .if ${TARGET_ARCH} == "i386" && ${AUTO_KEYBOARD_DETECT}
Index: modules.c
===================================================================
RCS file: /home/ncvs/src/usr.sbin/sysinstall/modules.c,v
retrieving revision 1.4
diff -u -r1.4 modules.c
--- modules.c	3 Jun 2002 22:36:52 -0000	1.4
+++ modules.c	2 Nov 2002 14:53:00 -0000
@@ -40,7 +40,7 @@
 /* Prototypes */
 static int		kldModuleFire(dialogMenuItem *self);
 
-#define MODULESDIR "/stand/modules"
+#define MODULESDIR "/modules"
 #define DISTMOUNT "/dist"
 
 void


-- -
Makoto `MAR' Matsushita

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-qa" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021102235447G.matusita>