Skip site navigation (1)Skip section navigation (2)
Date:      17 Jul 2000 16:25:23 +0200
From:      Dag-Erling Smorgrav <des@flood.ping.uio.no>
To:        emulation@freebsd.org
Subject:   linux.sh should mount linprocfs
Message-ID:  <xzp3dl8g7fw.fsf@flood.ping.uio.no>

next in thread | raw e-mail | index | archive | help
I think linux.sh should be modified to load linprocfs and mount
/compat/linux/proc in addition to loading the linux module. Here's a
rough patch, though it lacks error checking. The patch also removes
tons of useless whitespace.

Index: linux.sh
===================================================================
RCS file: /home/ncvs/src/sys/modules/linux/linux.sh,v
retrieving revision 1.8
diff -u -r1.8 linux.sh
--- linux.sh	1999/12/13 08:38:22	1.8
+++ linux.sh	2000/07/17 14:24:25
@@ -2,16 +2,21 @@
 
 # $FreeBSD: src/sys/modules/linux/linux.sh,v 1.8 1999/12/13 08:38:22 cracauer Exp $
 
-FOUND=`kldstat -v | egrep 'linux(aout|elf)'`
+FOUND=$(kldstat -v | egrep 'linux(aout|elf)')
 
 exitcode=0
 
-if [ "x$FOUND" != x ] ; then           
+if [ "x$FOUND" != x ] ; then
 	echo Linux driver already loaded
 	exitcode=1
-else    
-	kldload linux                                                
+else 
+	kldload linux 
 	exitcode=$?
+fi
+
+if [ -z $(kldstat -v | grep 'linprocfs') ] ; then
+	kldstat linprocfs
+	mount_linprocfs linprocfs /compat/linux/proc
 fi
 
 if [ -f /compat/linux/sbin/ldconfig ] ; then

DES
-- 
Dag-Erling Smorgrav - des@flood.ping.uio.no


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




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