2009-03-09 05:50:38 +00:00
|
|
|
#!/bin/sh /etc/rc.common
|
|
|
|
START=90
|
2009-06-08 09:12:24 +00:00
|
|
|
|
2009-03-09 05:50:38 +00:00
|
|
|
start () {
|
2009-03-11 08:05:54 +00:00
|
|
|
interfaces=$(uci get batman-adv-kernelland.general.interface)
|
2009-03-10 15:48:41 +00:00
|
|
|
if [ "$interfaces" = "" ]; then
|
2009-03-09 05:50:38 +00:00
|
|
|
echo $1 Error, you must specify at least a network interface
|
|
|
|
exit
|
|
|
|
fi
|
|
|
|
|
2009-07-03 15:17:39 +00:00
|
|
|
batctl interface $interfaces
|
|
|
|
|
2009-03-11 08:05:54 +00:00
|
|
|
originator_interval=$(uci get batman-adv-kernelland.general.originator_interval)
|
|
|
|
log_level=$(uci get batman-adv-kernelland.general.log_level)
|
2009-03-09 05:50:38 +00:00
|
|
|
|
|
|
|
if [ $originator_interval ]; then
|
2009-07-03 15:17:39 +00:00
|
|
|
batctl interval $originator_interval
|
2009-03-09 05:50:38 +00:00
|
|
|
fi
|
|
|
|
|
|
|
|
if [ $log_level ]; then
|
2009-07-03 15:17:39 +00:00
|
|
|
batctl loglevel $log_level
|
2009-03-09 05:50:38 +00:00
|
|
|
fi
|
|
|
|
}
|
|
|
|
|
|
|
|
stop () {
|
2009-07-03 15:17:39 +00:00
|
|
|
batctl interface none
|
2009-03-09 05:50:38 +00:00
|
|
|
}
|
2009-04-21 19:16:40 +00:00
|
|
|
|
|
|
|
|