summaryrefslogtreecommitdiff
path: root/recipes-bsp/ti-wifi-utils
diff options
context:
space:
mode:
authorJohn Klug <john.klug@multitech.com>2019-02-22 16:38:30 -0600
committerJohn Klug <john.klug@multitech.com>2019-02-22 16:38:30 -0600
commit1d7494802ec6f683648ef2087915d7f9ceb75fcf (patch)
tree671fece18c16c87389b400f52eac432aba4efc42 /recipes-bsp/ti-wifi-utils
parentd49fbd2e259c75638c2d0f9d6f00d68da18d4522 (diff)
downloadmeta-multitech-atmel-1d7494802ec6f683648ef2087915d7f9ceb75fcf.tar.gz
meta-multitech-atmel-1d7494802ec6f683648ef2087915d7f9ceb75fcf.tar.bz2
meta-multitech-atmel-1d7494802ec6f683648ef2087915d7f9ceb75fcf.zip
Add the TI wifi stuff to Linux4
Diffstat (limited to 'recipes-bsp/ti-wifi-utils')
-rw-r--r--recipes-bsp/ti-wifi-utils/ti-wifi-utils/plt_drop_insmod_rmmod.patch35
-rw-r--r--recipes-bsp/ti-wifi-utils/ti-wifi-utils/upgrade_libnl_to_32.patch28
-rw-r--r--recipes-bsp/ti-wifi-utils/ti-wifi-utils_R8.7.bb51
3 files changed, 114 insertions, 0 deletions
diff --git a/recipes-bsp/ti-wifi-utils/ti-wifi-utils/plt_drop_insmod_rmmod.patch b/recipes-bsp/ti-wifi-utils/ti-wifi-utils/plt_drop_insmod_rmmod.patch
new file mode 100644
index 0000000..5bdafef
--- /dev/null
+++ b/recipes-bsp/ti-wifi-utils/ti-wifi-utils/plt_drop_insmod_rmmod.patch
@@ -0,0 +1,35 @@
+--- a/plt.c 2016-05-31 17:23:45.000000000 +0300
++++ b/plt.c 2016-05-31 18:04:25.022788401 +0300
+@@ -1158,10 +1158,10 @@
+ }
+
+ /* Load module */
+- res = insmod(modpath);
+- if (res) {
+- goto out_removenvs;
+- }
++// res = insmod(modpath);
++// if (res) {
++// goto out_removenvs;
++// }
+
+ res = plt_do_power_on(state, devname);
+ if (res < 0)
+@@ -1188,7 +1188,7 @@
+
+ /* we can ignore the return value, because we rmmod anyway */
+ plt_do_power_off(state, devname);
+- rmmod(modpath);
++// rmmod(modpath);
+
+ printf("Calibration done. ");
+ if (cmn.fem0_bands) {
+@@ -1214,7 +1214,7 @@
+ /* we can ignore the return value, because we rmmod anyway */
+ plt_do_power_off(state, devname);
+ out_rmmod:
+- rmmod(modpath);
++// rmmod(modpath);
+
+ out_removenvs:
+ fprintf(stderr, "Calibration not complete. Removing half-baked nvs\n");
diff --git a/recipes-bsp/ti-wifi-utils/ti-wifi-utils/upgrade_libnl_to_32.patch b/recipes-bsp/ti-wifi-utils/ti-wifi-utils/upgrade_libnl_to_32.patch
new file mode 100644
index 0000000..c5b6efa
--- /dev/null
+++ b/recipes-bsp/ti-wifi-utils/ti-wifi-utils/upgrade_libnl_to_32.patch
@@ -0,0 +1,28 @@
+--- a/Makefile 2016-05-31 17:23:45.000000000 +0300
++++ b/Makefile 2016-05-31 17:36:55.582844952 +0300
+@@ -1,21 +1,12 @@
+ CC = $(CROSS_COMPILE)gcc
+ CFLAGS = -O2 -Wall
+-CFLAGS += -I$(NFSROOT)/usr/include -I$(NFSROOT)/include
++CFLAGS += -I=/usr/include -I=/include -I=/usr/include/libnl3
+
+-ifdef NLROOT
+-CFLAGS += -I${NLROOT}
+-endif
+-
+-LDFLAGS += -L$(NFSROOT)/lib
++LDFLAGS += -L=/lib
+ LIBS += -lm
+
+-ifeq ($(NLVER),3)
+- CFLAGS+=-DCONFIG_LIBNL32
+- LIBS += -lnl-3 -lnl-genl-3
+-else
+- CFLAGS+=-DCONFIG_LIBNL20
+- LIBS += -lnl -lnl-genl
+-endif
++CFLAGS+=-DCONFIG_LIBNL32
++LIBS += -lnl-3 -lnl-genl-3
+
+ OBJS = nvs.o misc_cmds.o calibrator.o plt.o wl18xx_plt.o ini.o
+
diff --git a/recipes-bsp/ti-wifi-utils/ti-wifi-utils_R8.7.bb b/recipes-bsp/ti-wifi-utils/ti-wifi-utils_R8.7.bb
new file mode 100644
index 0000000..ee3ca65
--- /dev/null
+++ b/recipes-bsp/ti-wifi-utils/ti-wifi-utils_R8.7.bb
@@ -0,0 +1,51 @@
+DESCRIPTION = "The calibrator and other useful utilities for TI wireless solution based on wl12xx driver"
+HOMEPAGE = "http://software-dl.ti.com/ecs/WiLink8/latest/index_FDS.html"
+SECTION = "console/utils"
+PRIORITY = "optional"
+LICENSE = "BSD"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/BSD;md5=3775480a712fc46a69647678acb234cb"
+DEPENDS = "libnl"
+# ti-compat-wireless-wl12xx
+RDEPENDS_${PN} = "wl12xx-firmware"
+
+inherit autotools-brokensep
+
+do_compile () {
+ unset CFLAGS LDFLAGS CXXFLAGS CPPFLAGS
+ # For Newer Yocto/Bitbake, CC does not
+ # include the staging directory
+ # by default
+ CC="${CC} --sysroot=${STAGING_DIR_HOST}"
+ LD="${LD} --sysroot=${STAGING_DIR_HOST}"
+ oe_runmake CC="${CC}" LD="${LD}"
+}
+
+PR = "r2"
+# tag R8.7
+SRCREV = "39542357111d1f24e866c2857d561a348c04cce4"
+
+SRC_URI = " \
+ git://git.ti.com/wilink8-wlan/18xx-ti-utils.git;protocol=git;branch=master \
+ file://upgrade_libnl_to_32.patch \
+ file://plt_drop_insmod_rmmod.patch "
+
+
+
+S = "${WORKDIR}/git"
+
+export CROSS_COMPILE = "${TARGET_PREFIX}"
+
+do_install() {
+ install -d ${D}${bindir}
+ install -d ${D}${datadir}/ti/wifi-utils/ini_files/127x
+ install -d ${D}${datadir}/ti/wifi-utils/ini_files/128x
+
+ install -m 0755 calibrator ${D}${bindir}/
+ install -m 0755 ${S}/hw/ini_files/127x/* ${D}${datadir}/ti/wifi-utils/ini_files/127x
+ install -m 0755 ${S}/hw/ini_files/128x/* ${D}${datadir}/ti/wifi-utils/ini_files/128x
+}
+
+FILES_${PN} += " \
+ ${datadir}/ti/wifi-utils/ini_files/127x \
+ ${datadir}/ti/wifi-utils/ini_files/128x \
+"