mirror of
				git://git.openwrt.org/openwrt/openwrt.git
				synced 2025-10-30 21:44:27 -04:00 
			
		
		
		
	This target has been mostly replaced by ath79 and won't be included in the upcoming release anymore. Finally put it to rest. This also removes all references in packages, tools, etc. as well as the uboot-ar71xx and vsc73x5-ucode packages. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
		
			
				
	
	
		
			37 lines
		
	
	
		
			503 B
		
	
	
	
		
			Bash
		
	
	
	
	
	
			
		
		
	
	
			37 lines
		
	
	
		
			503 B
		
	
	
	
		
			Bash
		
	
	
	
	
	
| #!/bin/sh /etc/rc.common
 | |
| #
 | |
| # Copyright (C) 2011 OpenWrt.org
 | |
| #
 | |
| 
 | |
| START=11
 | |
| STOP=11
 | |
| 
 | |
| USE_PROCD=1
 | |
| NAME=om-watchdog
 | |
| PROG=/sbin/om-watchdog
 | |
| 
 | |
| get_gpio() {
 | |
| 	local board=$(board_name)
 | |
| 
 | |
| 	if [ "$board" = "teltonika,rut5xx" ]; then
 | |
| 		# ramips
 | |
| 		return 11
 | |
| 	else
 | |
| 		#we assume it is om1p in this case
 | |
| 		return 3
 | |
| 	fi
 | |
| 
 | |
| 	return 255
 | |
| }
 | |
| 
 | |
| start_service() {
 | |
| 	get_gpio
 | |
| 	gpio="$?"
 | |
| 	[ "$gpio" != "255" ] || return
 | |
| 
 | |
| 	procd_open_instance
 | |
| 	procd_set_param command "${PROG}" "${gpio}"
 | |
| 	procd_set_param respawn
 | |
| 	procd_close_instance
 | |
| }
 |