mirror of
https://github.com/Ysurac/openmptcprouter-feeds.git
synced 2025-03-09 15:40:03 +00:00
add qca feed
This commit is contained in:
parent
d43ffd8720
commit
26ac03f3f6
451 changed files with 111139 additions and 12069 deletions
67
qaa/qca/utils/btdiag/Makefile
Normal file
67
qaa/qca/utils/btdiag/Makefile
Normal file
|
|
@ -0,0 +1,67 @@
|
|||
#
|
||||
# Copyright (c) 2014 Qualcomm Atheros, Inc..
|
||||
#
|
||||
# All Rights Reserved.
|
||||
# Qualcomm Atheros Confidential and Proprietary.
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=btdiag
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_BRANCH:=master
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/btdiag
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)/Default
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:=$(1) - QCA ART Driver & tools
|
||||
DEPENDS:=+libpthread +libc +librt
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
ART package support for 10.4
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
CFLAGS="$(TARGET_CPPFLAGS) $(TARGET_CFLAGS)" \
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
CC="$(TARGET_CC)" \
|
||||
LD="$(TARGET_CC)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)"
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install/Default
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/Btdiag $(1)/usr/sbin
|
||||
endef
|
||||
|
||||
define Package/btdiag
|
||||
$(call Package/btdiag/Default)
|
||||
endef
|
||||
|
||||
define Package/btdiag/Description
|
||||
$(call Package/$(PKG_NAME)/Description/Default)
|
||||
endef
|
||||
|
||||
define Package/btdiag/config
|
||||
$(call Package/btdiag/config/Default)
|
||||
endef
|
||||
|
||||
define Package/btdiag/install
|
||||
$(call Package/btdiag/install/Default,$(1))
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,btdiag))
|
||||
66
qaa/qca/utils/cnssdiag/Makefile
Normal file
66
qaa/qca/utils/cnssdiag/Makefile
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=cnssdiag
|
||||
PKG_NAME:=$(PKG)
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:= QCA cnssdiag utils
|
||||
DEPENDS:=+TARGET_ipq50xx:qca-diag +TARGET_ipq60xx:qca-diag +TARGET_ipq807x:qca-diag +TARGET_ipq_ipq807x:qca-diag +TARGET_ipq_ipq807x_64:qca-diag +TARGET_ipq_ipq60xx:qca-diag +TARGET_ipq_ipq60xx_64:qca-diag +TARGET_ipq_ipq50xx:qca-diag +TARGET_ipq_ipq50xx_64:qca-diag +libnl
|
||||
endef
|
||||
|
||||
#MAKEOPTS+= \
|
||||
$(TARGET_CONFIGURE_OPTS) \
|
||||
COPTS="$(TARGET_CFLAGS)" \
|
||||
ATHEROSPATH=$(STAGING_DIR)/usr/include \
|
||||
ATH_SUPPORT_ICM=1 \
|
||||
ATH_SUPPORT_SPECTRAL=1 \
|
||||
QSDK_SPECTRAL=1
|
||||
TARGET_CFLAGS += -MMD -O2 -Wall -g -DCNSS_DIAG_PLATFORM_WIN -I. -I$(STAGING_DIR)/usr/include/ -I$(STAGING_DIR)/usr/include/qca-diag -I$(STAGING_DIR)/usr/include/libnl -I$(STAGING_DIR)/usr/include/libnl3 -D_GNU_SOURCE -fpie
|
||||
TARGET_LDFLAGS += -pie
|
||||
|
||||
|
||||
ifeq ($(CONFIG_TARGET_ipq_ipq40xx),y)
|
||||
TARGET_CFLAGS += -DNO_DIAG_SUPPORT
|
||||
else
|
||||
ifeq ($(CONFIG_TARGET_ipq_ipq806x),y)
|
||||
TARGET_CFLAGS += -DNO_DIAG_SUPPORT
|
||||
else
|
||||
TARGET_LDFLAGS += -ldiag -L$(STAGING_DIR)/usr/lib
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_PACKAGE_kmod-ath11k),y)
|
||||
TARGET_CFLAGS+=-DWIN_AP_HOST_OPEN=1
|
||||
TARGET_LDFLAGS += -lnl-3 -lnl-genl-3
|
||||
endif
|
||||
|
||||
define Package/InstallDev
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR)/cnssdiag \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)"
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin $(1)/etc/init.d $(1)/etc/config
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/cnssdiag/cnss_diag $(1)/usr/sbin
|
||||
$(INSTALL_BIN) ./files/cnss_diag.init $(1)/etc/init.d/cnss_diag
|
||||
$(INSTALL_BIN) ./files/cnss_diag.config $(1)/etc/config/cnss_diag
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)))
|
||||
8
qaa/qca/utils/cnssdiag/files/cnss_diag.config
Normal file
8
qaa/qca/utils/cnssdiag/files/cnss_diag.config
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
config cnss_diag global
|
||||
option enable '0'
|
||||
option console '0'
|
||||
option file '1'
|
||||
option firmware_file '/dev/zero'
|
||||
option host_file '/dev/console'
|
||||
option syslog '0'
|
||||
option qxdm '0'
|
||||
61
qaa/qca/utils/cnssdiag/files/cnss_diag.init
Normal file
61
qaa/qca/utils/cnssdiag/files/cnss_diag.init
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
#!/bin/sh /etc/rc.common
|
||||
#Copyright (c) 2018 Qualcomm Technologies, Inc.
|
||||
#
|
||||
#All Rights Reserved.
|
||||
#Confidential and Proprietary - Qualcomm Technologies, Inc.
|
||||
#
|
||||
START=19
|
||||
STOP=91
|
||||
SERVICE_PID_FILE=/var/run/cnss_diag.pid
|
||||
SERVICE_DAEMONIZE=1
|
||||
SERVICE_WRITE_PID=1
|
||||
|
||||
start () {
|
||||
config_load cnss_diag
|
||||
local ARGS
|
||||
|
||||
local enable
|
||||
config_get_bool enable global enable 0
|
||||
[ "${enable}" -gt 0 ] || return
|
||||
|
||||
local firmware console qxdm syslog file
|
||||
local firmware_file host_file
|
||||
|
||||
config_get firmware_file global firmware_file
|
||||
config_get host_file global host_file
|
||||
echo "LOG_PATH_FLAG = 3" >/var/run/cnss_diag.conf
|
||||
echo "REAL_TIME_WRITE = 1" >>/var/run/cnss_diag.conf
|
||||
echo "MAX_LOG_FILE_SIZE = 50" >>/var/run/cnss_diag.conf
|
||||
echo "MAX_ARCHIVES = 0" >>/var/run/cnss_diag.conf
|
||||
echo "MAX_PKTLOG_ARCHIVES = 0" >>/var/run/cnss_diag.conf
|
||||
echo "AVAILABLE_MEMORY_THRESHOLD = 0" >>/var/run/cnss_diag.conf
|
||||
echo "MAX_LOG_BUFFER = 2" >>/var/run/cnss_diag.conf
|
||||
echo "HOST_LOG_FILE_CUSTOM_LOC = ${host_file}" >>/var/run/cnss_diag.conf
|
||||
echo "FIRMWARE_LOG_FILE_CUSTOM_LOC = ${firmware_file}" >>/var/run/cnss_diag.conf
|
||||
echo "MAX_PKTLOG_BUFFER = 10" >>/var/run/cnss_diag.conf
|
||||
echo "ENABLE_FLUSH_LOG = 1" >>/var/run/cnss_diag.conf
|
||||
|
||||
|
||||
config_get console global console
|
||||
if [ "${console}" -ne "0" ]; then
|
||||
append ARGS "-c "
|
||||
fi
|
||||
config_get file global file
|
||||
if [ "${file}" -ne "0" ]; then
|
||||
append ARGS "-f "
|
||||
fi
|
||||
config_get qxdm global qxdm
|
||||
if [ "${qxdm}" -eq "1" ]; then
|
||||
append ARGS "-q "
|
||||
fi
|
||||
config_get syslog global syslog
|
||||
if [ "${syslog}" -eq "1" ]; then
|
||||
append ARGS "-S "
|
||||
fi
|
||||
|
||||
service_start /usr/sbin/cnss_diag ${ARGS} -s -b 0 -m /var/run/cnss_diag.conf
|
||||
}
|
||||
|
||||
stop() {
|
||||
service_stop /usr/sbin/cnss_diag
|
||||
}
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
diff --git a/cnssdiag/Makefile b/cnssdiag/Makefile
|
||||
index d1d340a..3923cbf 100644
|
||||
--- a/cnssdiag/Makefile
|
||||
+++ b/cnssdiag/Makefile
|
||||
@@ -1,9 +1,8 @@
|
||||
-CC := $(ATH_CROSS_COMPILE_TYPE)gcc
|
||||
-TARGET_TYPE ?= AR9888
|
||||
-TARGET_VERS ?= v2
|
||||
+CC = gcc
|
||||
+AR = ar
|
||||
|
||||
all:
|
||||
- $(CC) -g3 -Wall -Werror -Wno-unusedparameter \
|
||||
+ $(CC) -g3 -Wall -Werror $(CFLAGS) $(LDFLAGS) \
|
||||
cld-fwlog-netlink.c parser.c nan-parser.c cld-diag-parser.c -o cnss_diag
|
||||
|
||||
clean:
|
||||
76
qaa/qca/utils/ftm/Makefile
Normal file
76
qaa/qca/utils/ftm/Makefile
Normal file
|
|
@ -0,0 +1,76 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=ftm
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools/ftm
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
#PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:= QCA ftm utils
|
||||
DEPENDS:= @TARGET_ipq_ipq807x||TARGET_ipq_ipq807x_64||TARGET_ipq_ipq60xx||TARGET_ipq_ipq60xx_64||TARGET_ipq_ipq50xx||TARGET_ipq_ipq50xx_64||TARGET_ipq807x||TARGET_ipq60xx||TARGET_ipq50xx +libnl +libtcmd +qca-diag +librt +FEATURE_QCA_IOT:qca-IOT +FEATURE_QCA_IOT_IPQ50XX_SUPPORT:btdaemon
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
FTM Package Support for QCA WIFI 11 drivers
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS += -DCONFIG_FTM_WLAN -DDEBUG -DFTM_DEBUG -DWIN_AP_HOST
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include/qca-diag
|
||||
TARGET_CFLAGS += -MMD -O2 -Wall -g
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include
|
||||
TARGET_CFLAGS += -fpie
|
||||
TARGET_LDFLAGS += -ldiag -lnl-3 -lnl-genl-3 -lrt -ltcmd
|
||||
TARGET_CSRCS := ftm_main.c ftm_wlan.c ftm_write_to_flash.c
|
||||
TARGET_LDFLAGS += -pie
|
||||
|
||||
ifneq ($(CONFIG_PACKAGE_kmod-ath11k),)
|
||||
TARGET_CFLAGS+=-DWIN_AP_HOST_OPEN=1
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_FEATURE_QCA_IOT),y)
|
||||
TARGET_CFLAGS += -DIPQ_AP_HOST_IOT -DIPQ_AP_HOST_IOT_QCA402X -ggdb3 -DCONFIG_DAEMON_MODE
|
||||
TARGET_CSRCS += ftm_iot.c
|
||||
TARGET_LDFLAGS += -lpthread
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include/qca-iot
|
||||
TARGET_LDFLAGS += -ldiag_demo
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_FEATURE_QCA_IOT_IPQ50XX_SUPPORT),y)
|
||||
TARGET_CFLAGS += -DIPQ_AP_HOST_IOT -DIPQ_AP_HOST_IOT_IPQ50XX -ggdb3 -I$(STAGING_DIR)/usr/include/btdaemon
|
||||
TARGET_CSRCS += ftm_iot.c
|
||||
TARGET_LDFLAGS += -lpthread -lbtdaemon
|
||||
endif
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)" \
|
||||
CSRCS="$(TARGET_CSRCS)"
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/ftm $(1)/usr/sbin/
|
||||
$(INSTALL_BIN) ./files/ftm.init $(1)/etc/init.d/ftm
|
||||
$(INSTALL_DIR) $(1)/lib/wifi
|
||||
$(INSTALL_BIN) ./files/compress_vart.sh $(1)/lib/compress_vart.sh
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,ftm))
|
||||
74
qaa/qca/utils/ftm/files/compress_vart.sh
Normal file
74
qaa/qca/utils/ftm/files/compress_vart.sh
Normal file
|
|
@ -0,0 +1,74 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Copyright (c) 2020 Qualcomm Technologies, Inc.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
# Confidential and Proprietary - Qualcomm Technologies, Inc.
|
||||
#
|
||||
#
|
||||
|
||||
[ -e /lib/ipq806x.sh ] && . /lib/ipq806x.sh
|
||||
. /lib/functions.sh
|
||||
|
||||
low_mem_compress_art()
|
||||
{
|
||||
local mtdblock=$(find_mtd_part 0:ART)
|
||||
|
||||
if [ -z "$mtdblock" ]; then
|
||||
# read from mmc
|
||||
mtdblock=$(find_mmc_part 0:ART)
|
||||
fi
|
||||
|
||||
[ -n "$mtdblock" ] || return
|
||||
|
||||
local apmp="/tmp"
|
||||
|
||||
lzma -zvfk -4 ${apmp}/virtual_art.bin 2> /dev/null || {
|
||||
echo "Error Compressing Virtual ART" > /dev/console
|
||||
return
|
||||
}
|
||||
|
||||
dd if=${apmp}/virtual_art.bin.lzma of=${mtdblock}
|
||||
echo "Success compressing Virtual ART(${mtdblock})" > /dev/console
|
||||
return
|
||||
}
|
||||
|
||||
normal_art()
|
||||
{
|
||||
local mtdblock=$(find_mtd_part 0:ART)
|
||||
|
||||
if [ -z "$mtdblock" ]; then
|
||||
# read from mmc
|
||||
mtdblock=$(find_mmc_part 0:ART)
|
||||
fi
|
||||
|
||||
[ -n "$mtdblock" ] || return
|
||||
|
||||
local apmp="/tmp"
|
||||
|
||||
dd if=${apmp}/virtual_art.bin of=${mtdblock}
|
||||
echo "Success writing to ART(${mtdblock})" > /dev/console
|
||||
return
|
||||
}
|
||||
|
||||
write_caldata()
|
||||
{
|
||||
local board
|
||||
[ -f /tmp/sysinfo/board_name ] && {
|
||||
board=ap$(cat /tmp/sysinfo/board_name | awk -F 'ap' '{print$2}')
|
||||
}
|
||||
|
||||
if [ -e /sys/firmware/devicetree/base/compressed_art ]
|
||||
then
|
||||
echo "Compressed ART Supported Platform $board " > /dev/console
|
||||
low_mem_compress_art
|
||||
else
|
||||
echo "Non Compressed ART Platform $board " > /dev/console
|
||||
normal_art
|
||||
fi
|
||||
}
|
||||
|
||||
if [ "$1" = "write_caldata" ]
|
||||
then
|
||||
write_caldata
|
||||
fi
|
||||
97
qaa/qca/utils/ftm/files/ftm.init
Normal file
97
qaa/qca/utils/ftm/files/ftm.init
Normal file
|
|
@ -0,0 +1,97 @@
|
|||
#!/bin/sh /etc/rc.common
|
||||
#
|
||||
# Copyright (c) 2013, 2017, 2020 Qualcomm Technologies, Inc.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
# Confidential and Proprietary - Qualcomm Technologies, Inc.
|
||||
#
|
||||
# 2013 Qualcomm Atheros, Inc.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
# Qualcomm Atheros Confidential and Proprietary
|
||||
#
|
||||
|
||||
. /lib/functions.sh
|
||||
[ -e /lib/ipq806x.sh ] && . /lib/ipq806x.sh
|
||||
|
||||
START=97
|
||||
SERVICE_DAEMONIZE=1
|
||||
SERVICE_WRITE_PID=1
|
||||
|
||||
MTD_ART_PART_NAME="art"
|
||||
|
||||
compressed_art_read() {
|
||||
local mtdblock=$(find_mtd_part 0:ART)
|
||||
|
||||
if [ -z "$mtdblock" ]; then
|
||||
#read from mmc
|
||||
mtdblock=$(find_mmc_part 0:ART)
|
||||
fi
|
||||
|
||||
[ -n "$mtdblock" ] || return
|
||||
|
||||
local apmp="/tmp"
|
||||
|
||||
dd if=${mtdblock} of=${apmp}/virtual_art.bin.lzma
|
||||
lzma -fdv --single-stream ${apmp}/virtual_art.bin.lzma || {
|
||||
# Create dummy virtual_art.bin file of size 512K
|
||||
dd if=/dev/zero of=${apmp}/virtual_art.bin bs=1024 count=512
|
||||
}
|
||||
echo "Uncompressed and Copied ART content from ${mtdblock} to /tmp/virtual_art.bin" > /dev/console
|
||||
}
|
||||
|
||||
raw_art_read() {
|
||||
local mtdblock=$(find_mtd_part 0:ART)
|
||||
|
||||
if [ -z "$mtdblock" ]; then
|
||||
#read from mmc
|
||||
mtdblock=$(find_mmc_part 0:ART)
|
||||
fi
|
||||
|
||||
[ -n "$mtdblock" ] || return
|
||||
|
||||
local apmp="/tmp"
|
||||
|
||||
dd if=${mtdblock} of=${apmp}/virtual_art.bin
|
||||
echo "Copy ART caldata from ${mtdblock} to /tmp/virtual_art.bin" > /dev/console
|
||||
}
|
||||
|
||||
retrieve_caldata() {
|
||||
local board
|
||||
[ -f /tmp/sysinfo/board_name ] && {
|
||||
board=ap$(cat /tmp/sysinfo/board_name | awk -F 'ap' '{print$2}')
|
||||
}
|
||||
echo "**** Platform Name: $board *****" > /dev/console
|
||||
|
||||
if [ -e /sys/firmware/devicetree/base/compressed_art ]
|
||||
then
|
||||
compressed_art_read
|
||||
else
|
||||
raw_art_read
|
||||
fi
|
||||
}
|
||||
|
||||
start() {
|
||||
local emmc_flash=""
|
||||
local nor_flash=""
|
||||
|
||||
emmc_flash=$(find_mmc_part 0:ART 2> /dev/null)
|
||||
mtd_name=$(grep -i -w ${MTD_ART_PART_NAME} /proc/mtd | cut -f1 -d:)
|
||||
nor_flash=`find /sys/bus/spi/devices/*/mtd -name ${mtd_name} 2> /dev/null`
|
||||
|
||||
if [ -n "$emmc_flash" ]; then
|
||||
[ -L /dev/caldata ] || \
|
||||
ln -s $emmc_flash /dev/caldata
|
||||
elif [ -n "$nor_flash" ]; then
|
||||
[ -L /dev/caldata ] || \
|
||||
ln -s /dev/${mtd_name//mtd/mtdblock} /dev/caldata
|
||||
elif [ -n "$mtd_name" ]; then
|
||||
[ -L /dev/caldata ] || \
|
||||
ln -s /dev/${mtd_name//mtd/mtdblock} /dev/caldata
|
||||
fi
|
||||
retrieve_caldata
|
||||
}
|
||||
|
||||
stop() {
|
||||
[ -L /dev/caldata ] && rm /dev/caldata
|
||||
}
|
||||
66
qaa/qca/utils/libathtestcmd/Makefile
Normal file
66
qaa/qca/utils/libathtestcmd/Makefile
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=libathtestcmd
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools/ath6kl-utils/libathtestcmd
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QTI
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Technologies, Inc
|
||||
TITLE:= QTI libathtestcmd utils
|
||||
DEPENDS:= @TARGET_ipq_ipq807x||TARGET_ipq_ipq807x_64||TARGET_ipq_ipq60xx||TARGET_ipq_ipq60xx_64||TARGET_ipq60xx||TARGET_ipq_ipq50xx||TARGET_ipq_ipq50xx_64||TARGET_ipq807x +libpthread +libnl +libtcmd +libtlv2 +libtlvutil
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
LIBATHTESTCMD Package Support for QTI WIFI 11 drivers
|
||||
endef
|
||||
|
||||
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include \
|
||||
-I./include \
|
||||
-I$(STAGING_DIR)/usr/lib/ \
|
||||
-I$(STAGING_DIR)/usr/include/libnl3 \
|
||||
-I$(STAGING_DIR)/usr/include/libnl3/netlink \
|
||||
-I$(STAGING_DIR)/usr/include/libtlv2 \
|
||||
-I$(STAGING_DIR)/usr/include/libtlvutil \
|
||||
-fPIC -DWLAN_API_NL80211 -DLIBNL_2 -DWIN_AP_HOST -D_HOST_SIM_TESTING -DLinux -DUSE_TLV2
|
||||
|
||||
TARGET_LDFLAGS += -shared
|
||||
TARGET_LDFLAGS += -ltcmd -ltlv2 -ltlv1util
|
||||
|
||||
ifneq ($(CONFIG_PACKAGE_kmod-ath11k),)
|
||||
TARGET_CFLAGS+=-DWIN_AP_HOST_OPEN=1
|
||||
endif
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)"
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include/libathtestcmd $(1)/usr/lib
|
||||
$(CP) $(PKG_BUILD_DIR)/testcmd6174.h $(1)/usr/include/libathtestcmd
|
||||
$(CP) $(PKG_BUILD_DIR)/include/*.h $(1)/usr/include/libathtestcmd
|
||||
$(CP) $(PKG_BUILD_DIR)/libtestcmd6174.so $(1)/usr/lib
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/libtestcmd6174.so $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,libathtestcmd))
|
||||
62
qaa/qca/utils/libtcmd/Makefile
Normal file
62
qaa/qca/utils/libtcmd/Makefile
Normal file
|
|
@ -0,0 +1,62 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=libtcmd
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools/ath6kl-utils/libtcmd
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
#PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:= QCA libtcmd utils
|
||||
DEPENDS:= @TARGET_ipq_ipq807x||TARGET_ipq_ipq807x_64||TARGET_ipq_ipq60xx||TARGET_ipq_ipq60xx_64||TARGET_ipq_ipq50xx||TARGET_ipq_ipq50xx_64||TARGET_ipq807x||TARGET_ipq60xx||TARGET_ipq50xx +libpthread +libnl
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
LIBTCMD Package Support for QCA WIFI 11 drivers
|
||||
endef
|
||||
|
||||
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include \
|
||||
-I$(STAGING_DIR)/usr/include/libnl3 \
|
||||
-I$(STAGING_DIR)/usr/include/libnl3/netlink \
|
||||
-fPIC -DWLAN_API_NL80211 -DLIBNL_2 -DWIN_AP_HOST
|
||||
|
||||
TARGET_LDFLAGS += -lnl-3 -lnl-genl-3 -shared
|
||||
|
||||
ifneq ($(CONFIG_PACKAGE_kmod-ath11k),)
|
||||
TARGET_CFLAGS+=-DWIN_AP_HOST_OPEN=1
|
||||
endif
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)"
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include/ $(1)/usr/lib/
|
||||
$(CP) $(PKG_BUILD_DIR)/*.h $(1)/usr/include/
|
||||
$(CP) $(PKG_BUILD_DIR)/libtcmd.so $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/libtcmd.so $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,libtcmd))
|
||||
64
qaa/qca/utils/libtlv2/Makefile
Normal file
64
qaa/qca/utils/libtlv2/Makefile
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=libtlv2
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools/ath6kl-utils/libathtestcmd/libtlv2
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QTI
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Technologies, Inc
|
||||
TITLE:= QTI libtlv2 utils
|
||||
DEPENDS:= @TARGET_ipq_ipq807x||TARGET_ipq_ipq807x_64||TARGET_ipq_ipq60xx||TARGET_ipq_ipq60xx_64||TARGET_ipq_ipq50xx||TARGET_ipq_ipq50xx_64||TARGET_ipq807x||TARGET_ipq60xx +libpthread +libnl
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
LIBTLV2 Package Support for QTI WIFI 11 drivers
|
||||
endef
|
||||
|
||||
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include \
|
||||
-I./include \
|
||||
-I./include/testUtil.h \
|
||||
-fPIC -DWLAN_API_NL80211 -DLIBNL_2 -DWIN_AP_HOST -D_HOST_SIM_TESTING -D_FOR_HOST_TESTING \
|
||||
-DLinux \
|
||||
-I./cmdEncoder \
|
||||
-I./cmdParser \
|
||||
-I./common \
|
||||
-I./tlvcmdrsp \
|
||||
-I$(STAGING_DIR)/usr/include/libathtestcmd
|
||||
|
||||
TARGET_LDFLAGS += -shared
|
||||
|
||||
ifneq ($(CONFIG_PACKAGE_kmod-ath11k),)
|
||||
TARGET_CFLAGS+=-DWIN_AP_HOST_OPEN=1
|
||||
endif
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) CC="$(TARGET_CC)" CFLAGS="$(TARGET_CFLAGS)" LDFLAGS="$(TARGET_LDFLAGS)" \
|
||||
-f Makefile.win
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include/$(PKG_NAME) $(1)/usr/lib
|
||||
$(CP) $(PKG_BUILD_DIR)/include/*.h $(1)/usr/include/$(PKG_NAME)
|
||||
$(CP) $(PKG_BUILD_DIR)/*.so $(1)/usr/lib
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/*.so $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,libtlv2))
|
||||
63
qaa/qca/utils/libtlvutil/Makefile
Normal file
63
qaa/qca/utils/libtlvutil/Makefile
Normal file
|
|
@ -0,0 +1,63 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=libtlvutil
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools/ath6kl-utils/libathtestcmd/
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QTI
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Technologies, Inc
|
||||
TITLE:= QTI libtlvutil utils
|
||||
DEPENDS:= @TARGET_ipq_ipq807x||TARGET_ipq_ipq807x_64||TARGET_ipq_ipq60xx||TARGET_ipq_ipq60xx_64||TARGET_ipq_ipq50xx||TARGET_ipq_ipq50xx_64||TARGET_ipq807x||TARGET_ipq60xx +libpthread +libnl
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
LIBTLVUTIL Package Support for QTI WIFI 11 drivers
|
||||
endef
|
||||
|
||||
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include \
|
||||
-I./../include \
|
||||
-I./common/ \
|
||||
-I./templete/ \
|
||||
-I./defParm/ \
|
||||
-fPIC -DWLAN_API_NL80211 -DLIBNL_2 -DWIN_AP_HOST -D_HOST_SIM_TESTING -D_FOR_HOST_TESTING
|
||||
|
||||
TARGET_LDFLAGS += -shared
|
||||
|
||||
ifneq ($(CONFIG_PACKAGE_kmod-ath11k),)
|
||||
TARGET_CFLAGS+=-DWIN_AP_HOST_OPEN=1
|
||||
endif
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR)/libtlvutil \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)"
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include/$(PKG_NAME) $(1)/usr/lib/
|
||||
$(CP) $(PKG_BUILD_DIR)/libtlvutil/common/tcmdHostInternal.h $(1)/usr/include/$(PKG_NAME)
|
||||
$(CP) $(PKG_BUILD_DIR)/libtlvutil/*.h $(1)/usr/include/$(PKG_NAME)
|
||||
$(CP) $(PKG_BUILD_DIR)/libtlvutil/libtlv1util.so $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/libtlvutil/libtlv1util.so $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,libtlvutil))
|
||||
57
qaa/qca/utils/myftm/Makefile
Normal file
57
qaa/qca/utils/myftm/Makefile
Normal file
|
|
@ -0,0 +1,57 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=myftm
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools/ath6kl-utils/myftm
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
#PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QTI
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Technologies, Inc
|
||||
TITLE:= QTI myftm utils
|
||||
DEPENDS:= @TARGET_ipq_ipq807x||TARGET_ipq_ipq807x_64||TARGET_ipq_ipq60xx||TARGET_ipq_ipq60xx_64||TARGET_ipq_ipq50xx||TARGET_ipq_ipq50xx_64||TARGET_ipq807x||TARGET_ipq60xx +libtcmd +librt +libnl +libathtestcmd +zlib
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
My FTM Package Support for QTI WIFI 11 drivers
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS += -DCONFIG_FTM_WLAN -DDEBUG -DFTM_DEBUG -DCONFIG_FTM_WLAN_AUTOLOAD -DWIN_AP_HOST -DUSE_TLV2
|
||||
TARGET_CFLAGS += -MMD -O2 -Wall -g
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include/
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include/libathtestcmd
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/lib/libathtestcmd
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/lib/
|
||||
TARGET_CFLAGS += -fpie
|
||||
TARGET_LDFLAGS += -ltcmd -ltestcmd6174 -lz
|
||||
TARGET_CSRCS := myftm_main.c myftm_wlan.c myftm_qtip.c
|
||||
TARGET_LDFLAGS += -pie
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)" \
|
||||
CSRCS="$(TARGET_CSRCS)"
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/myftm $(1)/usr/sbin/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,myftm))
|
||||
69
qaa/qca/utils/qca-cfg80211/Makefile
Normal file
69
qaa/qca/utils/qca-cfg80211/Makefile
Normal file
|
|
@ -0,0 +1,69 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=qca-cfg80211
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=ssh://qca-git01.qualcomm.com:29418/wifi/$(PKG_NAME).git
|
||||
PKG_BRANCH:=master
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools
|
||||
DRIVER_PATH:=$(TOPDIR)/qca/src/qca-wifi
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_REV:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
PKG_VERSION:=g$(PKG_REV)
|
||||
endif
|
||||
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)-$(PKG_VERSION)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:= QCA cfg80211 utils
|
||||
DEPENDS:=+libnl +libpthread +iw
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS += \
|
||||
-I$(STAGING_DIR)/usr/include/ \
|
||||
-I$(STAGING_DIR)/usr/include/libnl \
|
||||
-I$(STAGING_DIR)/usr/include/libnl3 \
|
||||
-D_GNU_SOURCE=1 -D__USE_GNU=1
|
||||
|
||||
TARGET_LDFLAGS += \
|
||||
-lnl-3 -lnl-genl-3
|
||||
|
||||
TARGET_CFLAGS += -fpie
|
||||
TARGET_CFLAGS += -fPIC
|
||||
TARGET_LDFLAGS += -pie
|
||||
|
||||
define Package/InstallDev
|
||||
$(CP) $(PKG_BUILD_DIR)/cfg80211_nlwrapper_api.h $(STAGING_DIR)/usr/include/cfg80211_nlwrapper_api.h
|
||||
$(CP) $(PKG_BUILD_DIR)/cfg80211_nlwrapper_pvt.h $(STAGING_DIR)/usr/include/cfg80211_nlwrapper_pvt.h
|
||||
$(CP) $(PKG_BUILD_DIR)/nl80211_copy.h $(STAGING_DIR)/usr/include/nl80211_copy.h
|
||||
$(CP) $(PKG_BUILD_DIR)/libqca_nl80211_wrapper.so $(STAGING_DIR)/usr/lib/
|
||||
$(CP) $(DRIVER_PATH)/component_dev/tools/linux/cfg80211_ven_cmd.h $(STAGING_DIR)/usr/include
|
||||
endef
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR)/qca_nl80211_lib \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)"
|
||||
$(CP) $(PKG_BUILD_DIR)/qca_nl80211_lib/cfg80211_nlwrapper_api.h $(STAGING_DIR)/usr/include/cfg80211_nlwrapper_api.h
|
||||
$(CP) $(PKG_BUILD_DIR)/qca_nl80211_lib/cfg80211_nlwrapper_pvt.h $(STAGING_DIR)/usr/include/cfg80211_nlwrapper_pvt.h
|
||||
$(CP) $(PKG_BUILD_DIR)/qca_nl80211_lib/qca-vendor.h $(STAGING_DIR)/usr/include/qca-vendor.h
|
||||
$(CP) $(PKG_BUILD_DIR)/qca_nl80211_lib/libqca_nl80211_wrapper.so $(STAGING_DIR)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/local/lib
|
||||
$(INSTALL_DATA) $(PKG_BUILD_DIR)/qca_nl80211_lib/libqca_nl80211_wrapper.so $(1)/usr/local/lib/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)))
|
||||
59
qaa/qca/utils/qca-cfg80211tool/Makefile
Normal file
59
qaa/qca/utils/qca-cfg80211tool/Makefile
Normal file
|
|
@ -0,0 +1,59 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=qca-cfg80211tool
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=ssh://qca-git01.qualcomm.com:29418/wifi/$(PKG_NAME).git
|
||||
PKG_BRANCH:=master
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools
|
||||
DRIVER_PATH:=$(TOPDIR)/qca/src/qca-wifi
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_REV:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
PKG_VERSION:=g$(PKG_REV)
|
||||
endif
|
||||
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)-$(PKG_VERSION)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
PKG_BUILD_DEPENDS:=qca-wifi
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:= QCA cfg80211 utils
|
||||
DEPENDS:=+libnl +libpthread +libroxml +iw
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS += \
|
||||
-I$(STAGING_DIR)/usr/include/ \
|
||||
-I$(STAGING_DIR)/usr/include/libnl \
|
||||
-I$(STAGING_DIR)/usr/include/libnl3 \
|
||||
-D_GNU_SOURCE=1 -D__USE_GNU=1 -D__WIN__=1 -DCONFIG_SUPPORT_LIBROXML=1
|
||||
|
||||
TARGET_LDFLAGS += \
|
||||
-lnl-3 -lnl-genl-3 -lroxml
|
||||
|
||||
TARGET_CFLAGS += -fpie
|
||||
TARGET_CFLAGS += -fPIC
|
||||
TARGET_LDFLAGS += -pie
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR)/vendorcmdtool \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)"
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/vendorcmdtool/cfg80211tool.1 $(1)/usr/sbin
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)))
|
||||
43
qaa/qca/utils/qca-cnss-daemon/Makefile
Normal file
43
qaa/qca/utils/qca-cnss-daemon/Makefile
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
|
||||
include $(TOPDIR)/rules.mk
|
||||
include $(INCLUDE_DIR)/kernel.mk
|
||||
|
||||
PKG_NAME:=qca-cnss-daemon
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_BRANCH:=master
|
||||
PKG_RELEASE:=1
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/qca-cnss-daemon
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
TITLE:=QCA Linux QMI sotware
|
||||
DEPENDS:=@TARGET_ipq_ipq807x||TARGET_ipq_ipq807x_64||TARGET_ipq_ipq60xx||TARGET_ipq_ipq60xx_64||TARGET_ipq_ipq50xx||TARGET_ipq_ipq50xx_64||TARGET_ipq807x||TARGET_ipq60xx||TARGET_ipq50xx +libnl +libpthread +qca-qmi-framework
|
||||
endef
|
||||
|
||||
define Package/qca-cnss-daemon/Description
|
||||
This package contains a Linux qmi framework for the user space
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)
|
||||
mkdir -p $(1)/usr/include
|
||||
$(CP) $(PKG_BUILD_DIR)/*.h $(1)/usr/include/
|
||||
endef
|
||||
|
||||
define Package/qca-cnss-daemon/install
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/cnssdaemon $(1)/usr/bin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/lib/cnsscli $(1)/usr/bin
|
||||
endef
|
||||
|
||||
|
||||
$(eval $(call BuildPackage,qca-cnss-daemon))
|
||||
|
|
@ -0,0 +1,41 @@
|
|||
diff --git a/qca-cnss-daemon/patches/Makefile b/qca-cnss-daemon/patches/Makefile
|
||||
new file mode 100644
|
||||
index 0000000..f413dd8
|
||||
--- /dev/null
|
||||
+++ b/Makefile
|
||||
@@ -0,0 +1,33 @@
|
||||
+INCLUDE_DIR += -I. -I$(STAGING_DIR)/usr/include/libnl \
|
||||
+ -I$(STAGING_DIR)/usr/include/libnl3
|
||||
+
|
||||
+FLAGS := -fPIC -Wall -g -DICNSS_QMI -D__USE_GNU -DCONFIG_DEBUG_SYSLOG \
|
||||
+ -DCONFIG_DEBUG -DCONFIG_DEBUG_FILE -DCONFIG_IPC_LOGGING \
|
||||
+ -DCONFIG_NO_DMS -D_GNU_SOURCE \
|
||||
+ -DCONFIG_NO_DATA_PATH_EXTNS \
|
||||
+ -DCONFIG_NO_PM -DCONFIG_CNSS_USER\
|
||||
+ -DCONFIG_RECORD_DAEMON_QMI_LOG -DCONFIG_WLAN_MSG_SVC \
|
||||
+ -DDISABLE_CLD80211_LIB -D__NON_ANDROID -DIPQ
|
||||
+LIBS := -lpthread -lnl-genl-3 -lnl-3
|
||||
+LDFLAGS := -L/usr/lib -lqmi_common_so -lqmi_qrtr_cci \
|
||||
+ -pie
|
||||
+
|
||||
+CFLAGS += -fpie
|
||||
+
|
||||
+cnssdaemon := wlan_firmware_service_v01.o \
|
||||
+ cnss_plat.o wlfw_qmi_client.o \
|
||||
+ debug.o \
|
||||
+ main.o nl_loop.o cnss_user.o cnss_genl.o
|
||||
+
|
||||
+cnsscli := cnss_cli.o
|
||||
+%.o: %.c
|
||||
+ $(CC) -c -o $@ $(INCLUDE_DIR) $(FLAGS) $(LIBS) $(LDFLAGS) $(CFLAGS) $<
|
||||
+
|
||||
+all: $(cnssdaemon) $(cnsscli)
|
||||
+ $(CC) -o cnssdaemon $(cnssdaemon) $(INCLUDE_DIR) $(FLAGS) $(LIBS) $(LDFLAGS) $(CFLAGS)
|
||||
+ $(CC) -o cnsscli $(cnsscli) $(INCLUDE_DIR) $(LIBS) $(LDFLAGS) $(CFLAGS)
|
||||
+ mkdir -p lib/
|
||||
+ mv cnssdaemon lib/
|
||||
+ mv cnsscli lib/
|
||||
+clean:
|
||||
+ rm -rf lib/
|
||||
+ rm -rf *.o
|
||||
+
|
||||
86
qaa/qca/utils/qca-icm/Makefile
Normal file
86
qaa/qca/utils/qca-icm/Makefile
Normal file
|
|
@ -0,0 +1,86 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=qca-icm
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=ssh://qca-git01.qualcomm.com:29418/qca/src/$(PKG_NAME).git
|
||||
PKG_BRANCH:=master
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_REV:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
PKG_VERSION:=g$(PKG_REV)
|
||||
endif
|
||||
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)-$(PKG_VERSION)
|
||||
PKG_BUILD_DEPENDS:=kmod-qca-wifi
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:=QCA Intelligent channel manager
|
||||
DEPENDS:=kmod-qca-wifi +libpthread qca-spectral +libnl
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS += \
|
||||
-I$(STAGING_DIR)/usr/include \
|
||||
-I. \
|
||||
-Idriver \
|
||||
-Icommon \
|
||||
-I$(STAGING_DIR)/usr/include/libnl3
|
||||
|
||||
TARGET_LDFLAGS += \
|
||||
-lnl-3 -lnl-genl-3
|
||||
|
||||
# Update CFLAGS
|
||||
TARGET_CFLAGS+= -Wall -Werror
|
||||
|
||||
ifeq (${BUILD_STATIC}, y)
|
||||
TARGET_LDFLAGS+= -static
|
||||
endif
|
||||
|
||||
ifeq (${BUILD_DEBUG}, y)
|
||||
TARGET_CFLAGS+= -g
|
||||
endif
|
||||
|
||||
ifeq (${BUILD_OPTIMIZED}, y)
|
||||
TARGET_CFLAGS += -Os -pipe -mips32r2 -mtune=mips32r2 -funit-at-a-time
|
||||
endif
|
||||
|
||||
TARGET_CFLAGS += -DICM_RTR_DRIVER
|
||||
|
||||
ifdef CONFIG_USE_MUSL
|
||||
ifeq ($(ARCH),aarch64)
|
||||
TARGET_CFLAGS+=-DAARCH64_WITH_MUSL
|
||||
endif
|
||||
endif
|
||||
|
||||
MAKEOPTS+= \
|
||||
$(TARGET_CONFIGURE_OPTS) \
|
||||
WLAN_SPECTRAL_ENABLE=1 \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)"\
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR)/icm $(MAKEOPTS)
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/icm/icm $(1)/usr/sbin
|
||||
|
||||
$(INSTALL_DIR) $(1)/lib/wifi
|
||||
$(INSTALL_BIN) ./files/icm.sh $(1)/lib/wifi
|
||||
|
||||
$(INSTALL_DIR) $(1)/etc/ath
|
||||
$(INSTALL_DATA) ./files/icm.conf $(1)/etc/ath
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)))
|
||||
84
qaa/qca/utils/qca-icm/files/icm.conf
Normal file
84
qaa/qca/utils/qca-icm/files/icm.conf
Normal file
|
|
@ -0,0 +1,84 @@
|
|||
# Copyright (c) 2012 Qualcomm Atheros, Inc..
|
||||
# All Rights Reserved.
|
||||
# Qualcomm Atheros Confidential and Proprietary.
|
||||
|
||||
# icm configuration file
|
||||
|
||||
#number of devices
|
||||
num_devices=1
|
||||
|
||||
# radio interface name
|
||||
id_0_radio_ifname=wifi0
|
||||
id_1_radio_ifname=wifi1
|
||||
#id_2_radio_ifname=wifi2
|
||||
|
||||
# device interface name
|
||||
id_0_dev_ifname=ath0
|
||||
id_1_dev_ifname=ath1
|
||||
#id_2_dev_ifname=ath2
|
||||
|
||||
# operating band
|
||||
# 0 - 2.4 GHz band
|
||||
# 1 - 5 GHz band
|
||||
id_0_band=0
|
||||
id_1_band=1
|
||||
#id_2_band=1
|
||||
|
||||
# PHY specification
|
||||
# 0 - 11A
|
||||
# 1 - 11B
|
||||
# 2 - 11G
|
||||
# 3 - FH
|
||||
# 4 - TURBO_A
|
||||
# 5 - TURBO_G
|
||||
# 6 - 11NA
|
||||
# 7 - 11NG
|
||||
# 8 - 11AC
|
||||
id_0_phy_spec=7
|
||||
id_1_phy_spec=6
|
||||
#id_2_physpec=8
|
||||
|
||||
# socket interface type
|
||||
# 0 - TCP socket
|
||||
# 1 - UDP socket
|
||||
sock_type=1
|
||||
|
||||
# channel width
|
||||
# 0 - HT20
|
||||
# 1 - HT40MINUS
|
||||
# 2 - HT40PLUS
|
||||
# 3 - HT40
|
||||
id_0_channel_width=0
|
||||
id_1_channel_width=2
|
||||
#id_2_channel_width=0
|
||||
|
||||
# enable daemon
|
||||
# 0 - disable
|
||||
# 1 - enable
|
||||
daemon=0
|
||||
|
||||
# enable server_mode
|
||||
# 0 - disable
|
||||
# 1 - enable
|
||||
server_mode=0
|
||||
|
||||
# debug level
|
||||
# 1 - minor
|
||||
# 2 - default
|
||||
# 3 - major
|
||||
# 4 - critical
|
||||
debug_level=2
|
||||
|
||||
# debug mask
|
||||
# 0x01 - ICM main module
|
||||
# 0x02 - ICM SCAN module
|
||||
# 0x04 - ICM_SELELCTOR module
|
||||
# 0x08 - ICM_UTIL module
|
||||
# 0x10 - ICM Test module
|
||||
# 0xFF - Default
|
||||
debug_module_bitmap=255
|
||||
|
||||
# channel
|
||||
id_0_channel=6
|
||||
id_1_channel=44
|
||||
#id_2_channel=36
|
||||
63
qaa/qca/utils/qca-icm/files/icm.sh
Normal file
63
qaa/qca/utils/qca-icm/files/icm.sh
Normal file
|
|
@ -0,0 +1,63 @@
|
|||
# Copyright (c) 2014, 2019 Qualcomm Technologies, Inc.
|
||||
# All Rights Reserved.
|
||||
# Confidential and Proprietary - Qualcomm Technologies, Inc.
|
||||
#
|
||||
# 2014 Qualcomm Atheros, Inc.
|
||||
#
|
||||
# All Rights Reserved.
|
||||
# Qualcomm Atheros Confidential and Proprietary.
|
||||
#
|
||||
|
||||
. /lib/functions.sh
|
||||
. /lib/functions/service.sh
|
||||
|
||||
SERVICE_NAME=icm
|
||||
SERVICE_MATCH_EXEC=1
|
||||
SERVICE_DAEMONIZE=1
|
||||
|
||||
icm_setup() {
|
||||
ICM_ARGS=
|
||||
|
||||
config_get mode icm mode
|
||||
case ${mode} in
|
||||
standalone) ;;
|
||||
server) append ICM_ARGS "-v";;
|
||||
"") logger -t icm "Using default icm mode: Standlone";;
|
||||
*) logger -t icm "icm mode (${mode}) not supported. Using standlone";;
|
||||
esac
|
||||
|
||||
[ ${1} == "cfg80211" ] && append ICM_ARGS "-c cfg "
|
||||
|
||||
config_get_bool seldebug icm seldebug 0
|
||||
[ "${seldebug}" -gt 0 ] && append ICM_ARGS "-i"
|
||||
|
||||
config_get dbglvl icm dbglvl
|
||||
[ -n "${dbglevel}" ] && append ICM_ARGS "-q ${dbglevel}"
|
||||
|
||||
config_get dbgmask icm dbgmask
|
||||
[ -n "${dbgmask}" ] && append ICM_ARGS "-u ${dbgmask}"
|
||||
|
||||
config_get_bool enable11axunii3pref icm enable11axunii3pref
|
||||
[ -n "${enable11axunii3pref}" ] && append ICM_ARGS "-b ${enable11axunii3pref}"
|
||||
|
||||
config_get reptxpowerpolicy icm reptxpowerpolicy
|
||||
[ -n "${reptxpowerpolicy}" ] && append ICM_ARGS "-r ${reptxpowerpolicy}"
|
||||
|
||||
config_get rejpolicybitmask icm rejpolicybitmask
|
||||
[ -n "${rejpolicybitmask}" ] && append ICM_ARGS "-S ${rejpolicybitmask}"
|
||||
|
||||
config_get_bool enablechangradeusage icm enablechangradeusage
|
||||
[ -n "${enablechangradeusage}" ] && append ICM_ARGS "-g ${enablechangradeusage}"
|
||||
|
||||
config_get_bool enablespectralscan icm enablespectralscan
|
||||
[ -n "${enablespectralscan}" ] && append ICM_ARGS "-x ${enablespectralscan}"
|
||||
|
||||
# We don't use service_start here because we want to redirect the output
|
||||
# to syslog. However, we start it in such a way that service_stop can
|
||||
# find it when we want to shut it down.
|
||||
/usr/sbin/icm ${ICM_ARGS} -f | logger -t icm &
|
||||
}
|
||||
|
||||
icm_teardown() {
|
||||
service_stop /usr/sbin/icm
|
||||
}
|
||||
64
qaa/qca/utils/qca-spectral/Makefile
Normal file
64
qaa/qca/utils/qca-spectral/Makefile
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=qca-spectral
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_SOURCE_URL:=ssh://qca-git01.qualcomm.com:29418/wifi/$(PKG_NAME).git
|
||||
PKG_BRANCH:=master
|
||||
PKG_RELEASE:=1
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_REV:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
PKG_VERSION:=g$(PKG_REV)
|
||||
endif
|
||||
|
||||
|
||||
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)-$(PKG_VERSION)
|
||||
PKG_BUILD_DEPENDS:=qca-wifi
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:=QCA Spectral Analysis
|
||||
DEPENDS:=+libpthread +libnl +qca-cfg80211
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS += \
|
||||
-I$(STAGING_DIR)/usr/include/ \
|
||||
-I$(STAGING_DIR)/usr/include/libnl3
|
||||
|
||||
TARGET_LDFLAGS += \
|
||||
-lnl-3 -lnl-genl-3
|
||||
|
||||
MAKEOPTS+= \
|
||||
$(TARGET_CONFIGURE_OPTS) \
|
||||
COPTS="$(TARGET_CFLAGS) $(TARGET_LDFLAGS)" \
|
||||
ATHEROSPATH=$(STAGING_DIR)/usr/include \
|
||||
ATH_SUPPORT_SPECTRAL=1 \
|
||||
SPECTRAL_SUPPORT_CFG80211=1 \
|
||||
WLAN_FEATURE_ATHSSD_DEBUG=1 \
|
||||
QSDK_SPECTRAL=1
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) $(MAKEOPTS)
|
||||
$(CP) $(PKG_BUILD_DIR)/libath_classifier.a $(STAGING_DIR)/usr/lib/libath_classifier.a
|
||||
$(CP) $(PKG_BUILD_DIR)/ath_classifier.h $(STAGING_DIR)/usr/include/ath_classifier.h
|
||||
$(CP) $(PKG_BUILD_DIR)/wireless_copy.h $(STAGING_DIR)/usr/include/wireless_copy.h
|
||||
$(CP) $(PKG_BUILD_DIR)/common/spectral.h $(STAGING_DIR)/usr/include/spectral.h
|
||||
$(CP) $(PKG_BUILD_DIR)/common/spec_msg_proto.h $(STAGING_DIR)/usr/include/spec_msg_proto.h
|
||||
$(CP) $(PKG_BUILD_DIR)/common/spectral_data.h $(STAGING_DIR)/usr/include/spectral_data.h
|
||||
$(CP) $(PKG_BUILD_DIR)/common/spectral_types.h $(STAGING_DIR)/usr/include/spectral_types.h
|
||||
$(CP) $(PKG_BUILD_DIR)/common/classifier.h $(STAGING_DIR)/usr/include/classifier.h
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/athssd $(1)/usr/sbin
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,$(PKG_NAME)))
|
||||
107
qaa/qca/utils/qcmbr-10.4/Makefile
Normal file
107
qaa/qca/utils/qcmbr-10.4/Makefile
Normal file
|
|
@ -0,0 +1,107 @@
|
|||
#
|
||||
# Copyright (c) 2014 Qualcomm Atheros, Inc..
|
||||
#
|
||||
# All Rights Reserved.
|
||||
# Qualcomm Atheros Confidential and Proprietary.
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=qcmbr
|
||||
PKG_NAME:=$(PKG)-10.4
|
||||
PKG_SOURCE_PROTO:=git
|
||||
PKG_BRANCH:=master
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/qcmbr-10.4
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
ifeq ($(BUILD_VARIANT),netlink)
|
||||
QCMBR_APP_OPTS+=USE_NETLINK=1
|
||||
endif
|
||||
|
||||
PKG_SOURCE:=$(PKG)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_SUBDIR:=$(PKG)-$(PKG_VERSION)
|
||||
PKG_SOURCE_VERSION:=$(PKG_VERSION)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)/Default
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:=$(1) - QCA ART Driver & tools
|
||||
DEPENDS:=+libpthread +libc +librt
|
||||
VARIANT:=default
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
ART package support for 10.4
|
||||
endef
|
||||
|
||||
ifeq ($(BUILD_VARIANT),netlink)
|
||||
TARGET_CPPFLAGS += \
|
||||
-I$(STAGING_DIR)/usr/include/libnl-tiny
|
||||
|
||||
TARGET_LDFLAGS+=-lnl-tiny
|
||||
endif
|
||||
|
||||
define Build/Compile
|
||||
$(QCMBR_APP_OPTS) \
|
||||
CFLAGS="$(TARGET_CPPFLAGS) $(TARGET_CFLAGS)" \
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
CC="$(TARGET_CC)" \
|
||||
LD="$(TARGET_CC)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)" \
|
||||
Qcmbr
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install/Default
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_DIR) $(1)/etc/init.d
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/Qcmbr $(1)/usr/sbin
|
||||
$(INSTALL_BIN) ./files/qcmbr.init $(1)/etc/init.d/qcmbr
|
||||
endef
|
||||
|
||||
define Package/qcmbr-10.4
|
||||
$(call Package/qcmbr-10.4/Default)
|
||||
endef
|
||||
|
||||
define Package/qcmbr-10.4/Description
|
||||
$(call Package/$(PKG_NAME)/Description/Default)
|
||||
endef
|
||||
|
||||
define Package/qcmbr-10.4/config
|
||||
$(call Package/qcmbr-10.4/config/Default)
|
||||
endef
|
||||
|
||||
define Package/qcmbr-10.4/install
|
||||
$(call Package/qcmbr-10.4/install/Default,$(1))
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,qcmbr-10.4))
|
||||
|
||||
define Package/qcmbr-10.4-netlink
|
||||
$(call Package/qcmbr-10.4/Default,netlink)
|
||||
VARIANT:=netlink
|
||||
DEPENDS+=+libnl-tiny
|
||||
endef
|
||||
|
||||
define Package/qcmbr-10.4-netlink/Description
|
||||
$(call Package/qcmbr-10.4/Description/Default)
|
||||
endef
|
||||
|
||||
define Package/qcmbr-10.4-netlink/config
|
||||
$(call Package/qcmbr-10.4/config/Default,netlink)
|
||||
endef
|
||||
|
||||
define Package/qcmbr-10.4-netlink/install
|
||||
$(call Package/qcmbr-10.4/install/Default,$(1))
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,qcmbr-10.4-netlink))
|
||||
218
qaa/qca/utils/qcmbr-10.4/files/qcmbr.init
Normal file
218
qaa/qca/utils/qcmbr-10.4/files/qcmbr.init
Normal file
|
|
@ -0,0 +1,218 @@
|
|||
#!/bin/sh /etc/rc.common
|
||||
#
|
||||
# Copyright (c) 2013 Qualcomm Atheros, Inc..
|
||||
#
|
||||
# All Rights Reserved.
|
||||
# Qualcomm Atheros Confidential and Proprietary.
|
||||
#
|
||||
|
||||
. /lib/functions.sh
|
||||
|
||||
# We don't want to start ART2 automatically at boot time as we want the
|
||||
# default to be a working user configuration.
|
||||
# At the end of the boot process, the user can start art using:
|
||||
# /etc/init.d/art start
|
||||
START=
|
||||
SERVICE_DAEMONIZE=1
|
||||
SERVICE_WRITE_PID=1
|
||||
|
||||
#wlan_dir is for ath10K platform
|
||||
wlan_dir=/sys/class/net/wlan
|
||||
wifi_dir=/sys/class/net/wifi
|
||||
|
||||
if [ -f /etc/modules.d/33-qca-wifi* ]; then
|
||||
qcawifi_modules=/etc/modules.d/33-qca-wifi*
|
||||
else
|
||||
qcawifi_modules=/lib/wifi/qca-wifi-modules
|
||||
fi
|
||||
|
||||
arm_platform=`uname -m | grep arm`
|
||||
mips_platform=`uname -m | grep mips`
|
||||
third_party=""
|
||||
|
||||
MTD_ART_PART_NAME="art"
|
||||
|
||||
unload_modules() {
|
||||
for mod in $(cat $qcawifi_modules 2> /dev/null | sed '1!G;h;$!d'); do
|
||||
case ${mod} in
|
||||
mem_manager) continue;
|
||||
;;
|
||||
esac
|
||||
[ -d /sys/module/${mod} ] && rmmod ${mod}
|
||||
done
|
||||
}
|
||||
|
||||
load_modules() {
|
||||
local umac_args
|
||||
local ol_args
|
||||
|
||||
config_load wireless
|
||||
append umac_args "ahbskip=1"
|
||||
append ol_args "testmode=1"
|
||||
config_get otp_mod_param qcawifi otp_mod_param
|
||||
[ -n "$otp_mod_param" ] && append ol_args "otp_mod_param=$otp_mod_param"
|
||||
|
||||
for mod in $(cat $qcawifi_modules 2> /dev/null) ; do
|
||||
case ${mod} in
|
||||
umac) [ -d /sys/module/${mod} ] || { \
|
||||
|
||||
# Read the caldata to before loading umac
|
||||
if [ -f "/lib/read_caldata_to_fs.sh" ]; then
|
||||
. /lib/read_caldata_to_fs.sh
|
||||
do_load_ipq4019_board_bin
|
||||
elif [ -f "/lib/ar71xx_read_caldata_to_fs.sh" ]; then
|
||||
. /lib/ar71xx_read_caldata_to_fs.sh
|
||||
qcmbr_do_load_ar71xx_board_bin
|
||||
fi
|
||||
insmod ${mod} ${umac_args}
|
||||
};;
|
||||
|
||||
qca_ol) [ -d /sys/module/${mod} ] || { \
|
||||
insmod ${mod} ${ol_args}
|
||||
};;
|
||||
|
||||
*) [ -d /sys/module/${mod} ] || insmod ${mod};;
|
||||
esac
|
||||
done
|
||||
}
|
||||
|
||||
is_qcmbr_runnable() {
|
||||
# First argument represents wifi_dir/wlan_dir
|
||||
# Second argument represents wifi index/wlan index
|
||||
local dir_name=$1;
|
||||
local index=$2;
|
||||
if [ -e "$dir_name$index/device/device" ]; then
|
||||
read dev_id < "$dir_name$index/device/device"
|
||||
case "$dev_id" in
|
||||
"0x0040")
|
||||
return 1
|
||||
;;
|
||||
"0x0050")
|
||||
return 1
|
||||
;;
|
||||
"0x0046")
|
||||
return 1
|
||||
;;
|
||||
"0x0056")
|
||||
return 1
|
||||
;;
|
||||
"0x003c")
|
||||
return 1
|
||||
;;
|
||||
*)
|
||||
return 0
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
return 1
|
||||
}
|
||||
start_qcmbr() {
|
||||
# First argument represents the wifi directory name/wlan directory name to be use
|
||||
# Second argument represents the wifi index/wlan index to be use
|
||||
local dir_name=$1
|
||||
local wifi_index=$2
|
||||
local interface_name=$4
|
||||
|
||||
is_qcmbr_runnable $dir_name $wifi_index && return
|
||||
|
||||
if [ -n "$mips_platform" ] && [ -z "$third_party" ]; then
|
||||
SERVICE_PID_FILE=/var/run/qcmbr${3}.pid
|
||||
service_start /usr/sbin/Qcmbr -instance $3 -pcie ${wifi_index} -interface ${interface_name}
|
||||
else
|
||||
SERVICE_PID_FILE=/var/run/qcmbr${wifi_index}.pid
|
||||
service_start /usr/sbin/Qcmbr -instance ${wifi_index} -pcie ${wifi_index} -interface ${interface_name}
|
||||
fi
|
||||
}
|
||||
|
||||
stop_qcmbr() {
|
||||
# First argument represents the wifi directory name/wlan directory name to be use
|
||||
# Second argument represents the wifi index/wlan index to be use
|
||||
local dir_name=$1
|
||||
local wifi_index=$2
|
||||
local interface_name=$4
|
||||
|
||||
is_qcmbr_runnable $dir_name $wifi_index && return
|
||||
|
||||
if [ -n "$mips_platform" ] && [ -z "$third_party" ]; then
|
||||
SERVICE_PID_FILE=/var/run/qcmbr${3}.pid
|
||||
service_stop /usr/sbin/Qcmbr -instance $3 -pcie ${wifi_index} -interface ${interface_name}
|
||||
else
|
||||
SERVICE_PID_FILE=/var/run/qcmbr${wifi_index}.pid
|
||||
service_stop /usr/sbin/Qcmbr -instance ${wifi_index} -pcie ${wifi_index} -interface ${interface_name}
|
||||
fi
|
||||
}
|
||||
|
||||
start() {
|
||||
local emmc_flash=""
|
||||
local nor_flash=""
|
||||
local inst=0
|
||||
|
||||
emmc_flash=$(find_mmc_part 0:ART 2> /dev/null)
|
||||
|
||||
mtd_name=$(grep -i -w ${MTD_ART_PART_NAME} /proc/mtd | cut -f1 -d:)
|
||||
nor_flash=`find /sys/bus/spi/devices/*/mtd -name ${mtd_name} 2> /dev/null`
|
||||
|
||||
if [ -n "$emmc_flash" ]; then
|
||||
[ -L /dev/caldata ] || \
|
||||
ln -s $emmc_flash /dev/caldata
|
||||
elif [ -n "$nor_flash" -a -n "$arm_platform" ]; then
|
||||
[ -L /dev/caldata ] || \
|
||||
ln -s /dev/${mtd_name} /dev/caldata
|
||||
elif [ -n "$mtd_name" ]; then
|
||||
[ -L /dev/caldata ] || \
|
||||
ln -s /dev/${mtd_name//mtd/mtdblock} /dev/caldata
|
||||
fi
|
||||
|
||||
unload_modules
|
||||
load_modules
|
||||
|
||||
if [ -n "$emmc_flash" ] || [ -n "$mtd_name" ]; then
|
||||
third_party=""
|
||||
else
|
||||
third_party="true"
|
||||
fi
|
||||
|
||||
# Start the daemon
|
||||
# Check for ath10K driver
|
||||
# If ath10K driver installed, use wlan_dir instead of wifi_dir to check for device existence
|
||||
# and launch qcmbr application accordingly
|
||||
if [ -n "`lsmod | grep ath10k`" ] ; then
|
||||
for dir in /sys/class/net/wlan*; do
|
||||
[ -d "$dir" ] || continue
|
||||
interface=${dir:15}
|
||||
inst=`expr $inst + 1`
|
||||
start_qcmbr $wlan_dir "${dir#"$wlan_dir"}" $inst $interface
|
||||
done
|
||||
fi
|
||||
for dir in /sys/class/net/wifi*; do
|
||||
[ -d "$dir" ] || continue
|
||||
interface=${dir:15}
|
||||
inst=`expr $inst + 1`
|
||||
start_qcmbr $wifi_dir "${dir#"$wifi_dir"}" $inst $interface
|
||||
done
|
||||
}
|
||||
|
||||
stop() {
|
||||
local inst=0
|
||||
|
||||
# Stop the daemon
|
||||
# Check for ath10K driver
|
||||
# If ath10K driver installed, use wlan_dir instead of wifi_dir to check for device existence
|
||||
# and stop qcmbr application accordingly
|
||||
if [ -n "`lsmod | grep ath10k`" ] ; then
|
||||
for dir in /sys/class/net/wlan*; do
|
||||
[ -d "$dir" ] || continue
|
||||
interface=${dir:15}
|
||||
inst=`expr $inst + 1`
|
||||
stop_qcmbr $wlan_dir "${dir#"$wlan_dir"}" $inst $interface
|
||||
done
|
||||
fi
|
||||
for dir in /sys/class/net/wifi*; do
|
||||
[ -d "$dir" ] || continue
|
||||
interface=${dir:15}
|
||||
inst=`expr $inst + 1`
|
||||
stop_qcmbr $wifi_dir "${dir#"$wifi_dir"}" $inst $interface
|
||||
done
|
||||
unload_modules
|
||||
[ -L /dev/caldata ] && rm /dev/caldata
|
||||
}
|
||||
49
qaa/qca/utils/qmsct_client/Makefile
Normal file
49
qaa/qca/utils/qmsct_client/Makefile
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG:=qmsct_client
|
||||
PKG_NAME:=$(PKG)
|
||||
PKG_RELEASE:=1
|
||||
|
||||
LOCAL_SRC:=$(TOPDIR)/qca/src/common-tools/qmsct_client
|
||||
|
||||
include $(INCLUDE_DIR)/local-development.mk
|
||||
|
||||
ifeq ($(DUMP)$(PKG_VERSION),)
|
||||
PKG_VERSION:=$(shell git ls-remote $(PKG_SOURCE_URL) $(PKG_BRANCH) | cut -b -7)
|
||||
endif
|
||||
|
||||
#PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/$(PKG_NAME)
|
||||
SECTION:=QCA
|
||||
CATEGORY:=$(QTI_SOFTWARE_CATEGORY)
|
||||
URL:=http://www.qca.qualcomm.com
|
||||
MAINTAINER:=Qualcomm Atheros
|
||||
TITLE:= QCA qmsct_client utils
|
||||
DEPENDS:= @TARGET_ipq_ipq807x||TARGET_ipq_ipq807x_64
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/description/Default
|
||||
Qmsct Client application
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS += -MMD -O2 -Wall -g
|
||||
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include
|
||||
TARGET_CFLAGS += -fpie
|
||||
TARGET_LDFLAGS += -pie
|
||||
|
||||
define Build/Compile
|
||||
$(MAKE) -C $(PKG_BUILD_DIR) \
|
||||
CC="$(TARGET_CC)" \
|
||||
CFLAGS="$(TARGET_CFLAGS)" \
|
||||
LDFLAGS="$(TARGET_LDFLAGS)"
|
||||
endef
|
||||
|
||||
define Package/$(PKG_NAME)/install
|
||||
$(INSTALL_DIR) $(1)/usr/sbin
|
||||
$(INSTALL_BIN) $(PKG_BUILD_DIR)/qmsct_client $(1)/usr/sbin/
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,qmsct_client))
|
||||
Loading…
Add table
Add a link
Reference in a new issue