From 47c5bd66a8d652d8dab18cd8c32c0bc0fd07f2db Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sat, 9 Jun 2001 12:20:04 +0200 Subject: Checking for loaded driver in 'runvdr' --- CONTRIBUTORS | 4 ++++ runvdr | 8 ++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 8cb99a71..37c47874 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -75,3 +75,7 @@ J Benjamin Reichardt for his help in debugging the transition to the new API + +Henning Holtschneider + for patching 'runvdr' to check whether the driver is already loaded + diff --git a/runvdr b/runvdr index 158cba81..e4847162 100755 --- a/runvdr +++ b/runvdr @@ -18,15 +18,19 @@ # See the main source file 'vdr.c' for copyright information and # how to reach the author. # -# $Id: runvdr 1.5 2001/06/01 16:23:29 kls Exp $ +# $Id: runvdr 1.6 2001/06/09 12:20:04 kls Exp $ DVBDIR="../DVB/driver" VDRPRG="./vdr" VDRCMD="$VDRPRG -w 60 $*" +LSMOD="`/sbin/lsmod | grep dvbdev | wc -l`" KILLPROC="/sbin/killproc -TERM" -(cd $DVBDIR; make insmod) +# Load driver if it hasn't been loaded already: +if [ $LSMOD -eq 0 ] ; then + (cd $DVBDIR; make insmod) + fi while (true) do su -c "$VDRCMD" $VDRUSR -- cgit v1.2.3