#!/bin/sh /etc/rc.common
# Copyright (C) 2006-2011 OpenWrt.org

START=50

start()
{
	local pppoe_passthrough=`/bin/config get enable_pppoe_passthrough`
	if [ "x$pppoe_passthrough" = "x1" ];then
		/usr/sbin/pppoe-relay -C $BR_IF -B brwan
	fi
}

stop()
{
	kill -9 $(ps |grep /usr/sbin/pppoe-relay |grep -v grep |awk '{print $1}')
}

restart()
{
	stop
	start
}

