ponmngr: add initial airoha support

This commit is contained in:
Sukru Senli 2022-08-12 09:57:55 +02:00 committed by Rahul Thakur
parent 1c3cb6b72a
commit 7f81a5167b
5 changed files with 29 additions and 7 deletions

View file

@ -6,7 +6,7 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=ponmngr
PKG_VERSION:=1.0.0
PKG_VERSION:=1.0.1
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
@ -17,11 +17,12 @@ include $(INCLUDE_DIR)/package.mk
define Package/ponmngr
CATEGORY:=Utilities
TITLE:=ponmngr packets manager daemon
TITLE:=PON Manager
DEPENDS:=@(TARGET_iopsys_brcm63xx_arm||TARGET_iopsys_econet)
endef
define Package/ponmngr/description
Configures pon
Configures PON
endef
#define Build/Prepare
@ -32,7 +33,12 @@ define Build/Compile
endef
define Package/ponmngr/install
$(CP) ./files/* $(1)/
$(CP) ./files/common/* $(1)/
ifneq ($(CONFIG_TARGET_iopsys_brcm63xx_arm),)
$(CP) ./files/broadcom/* $(1)/
else ifneq ($(CONFIG_TARGET_iopsys_econet),)
$(CP) ./files/airoha/* $(1)/
endif
endef
$(eval $(call BuildPackage,ponmngr))

View file

@ -0,0 +1,18 @@
#!/bin/sh
. /lib/functions.sh
init_xpon() {
# For now use the base mac address as the omci serial number
/userfs/bin/omcicfgCmd set sn $(fw_printenv -n ethaddr | tr -d ':' | tr 'a-z' 'A-Z')
/userfs/bin/ponmgr_cfg &
sleep 1
/userfs/bin/omci &
}
deinit_xpon() {
killall -9 omci 2>/dev/null
killall -9 ponmgr_cfg 2>/dev/null
}

View file

@ -1,7 +1,5 @@
#!/bin/sh
USE_PROCD=1
. /lib/functions.sh
init_xpon() {

View file

@ -1,7 +1,7 @@
#!/bin/sh /etc/rc.common
START=19
STOP=10
STOP=91
USE_PROCD=1