summaryrefslogtreecommitdiffstats
path: root/recipes-ti/beagleboard/gadget-init/g-ether-start-service.sh
blob: 2db16c26081d3830fabf33cf58bed826c53aff04 (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/bin/sh
if [ -a /sys/devices/platform/omap/ti81xx-usbss/musb-hdrc.0/gadget/lun0/file ]
then
	x=$(cat /sys/devices/platform/omap/ti81xx-usbss/musb-hdrc.0/gadget/lun0/file)
	if [ -z "$x" ]
	then
		/bin/systemctl stop storage-gadget-init.service
		/bin/systemctl start network-gadget-init.service
		/bin/systemctl start udhcpd.service
	fi
fi