ppcrcd/trunk/conf.dir/usr/lib/ppcrcd/setbootopt

sparky cvs at pld-linux.org
Fri Mar 3 01:39:42 CET 2006


Author: sparky
Date: Fri Mar  3 01:39:39 2006
New Revision: 7074

Modified:
   ppcrcd/trunk/conf.dir/usr/lib/ppcrcd/setbootopt
Log:
- swap option support


Modified: ppcrcd/trunk/conf.dir/usr/lib/ppcrcd/setbootopt
==============================================================================
--- ppcrcd/trunk/conf.dir/usr/lib/ppcrcd/setbootopt	(original)
+++ ppcrcd/trunk/conf.dir/usr/lib/ppcrcd/setbootopt	Fri Mar  3 01:39:39 2006
@@ -102,6 +102,9 @@
 			eth=*)
 				ETH="$ETH $OPT"
 				;;
+			swap|swap=*)
+				SWAP="$OPT"
+				;;
 			*)
 				echo "Jumping: $OPT"
 		esac
@@ -184,6 +187,16 @@
 			SERVICE="$1"
 			echo adding $1
 			;;
+		swap|swap=*)
+			if [[ -n $(value $1) ]]; then
+				value $1 | tr "," "\n" | \
+				  while read DEV; do
+					[ -r /dev/$DEV ] || die 31 "No device '/dev/$DEV'"
+				  done
+			fi
+			SWAP="$1"
+			echo adding $1
+			;;
 		-f)
 			;;
 		*)
@@ -196,7 +209,7 @@
 
 
 # end ########################################################################
-OPTS="$(echo "$sboKTABLE $CONF $MODPRE $MODULES $ETH $SERVICE" | \
+OPTS="$(echo "$sboKTABLE $CONF $MODPRE $MODULES $ETH $SERVICE $SWAP" | \
 	sed -e 's/  */ /g' -e 's/^ *//' -e 's/ *$//')"
 echo
 echo -n "old opts:"


More information about the pld-cvs-commit mailing list