Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5928b91a authored by John W. Linville's avatar John W. Linville
Browse files
parents 7d5f01ad 248daa08
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -52,6 +52,16 @@ config WL12XX_SDIO
	  If you choose to build a module, it'll be called wl12xx_sdio.
	  Say N if unsure.

config WL12XX_SDIO_TEST
	tristate "TI wl12xx SDIO testing support"
	depends on WL12XX && MMC
	default n
	---help---
	  This module adds support for the SDIO bus testing with the
	  TI wl12xx chipsets.  You probably don't want this unless you are
	  testing a new hardware platform.  Select this if you want to test the
	  SDIO bus which is connected to the wl12xx chip.

config WL12XX_PLATFORM_DATA
	bool
	depends on WL12XX_SDIO != n || WL1251_SDIO != n
+3 −0
Original line number Diff line number Diff line
@@ -3,11 +3,14 @@ wl12xx-objs = main.o cmd.o io.o event.o tx.o rx.o ps.o acx.o \

wl12xx_spi-objs	= spi.o
wl12xx_sdio-objs	= sdio.o
wl12xx_sdio_test-objs = sdio_test.o

wl12xx-$(CONFIG_NL80211_TESTMODE)	+= testmode.o
obj-$(CONFIG_WL12XX)			+= wl12xx.o
obj-$(CONFIG_WL12XX_SPI)		+= wl12xx_spi.o
obj-$(CONFIG_WL12XX_SDIO)		+= wl12xx_sdio.o

obj-$(CONFIG_WL12XX_SDIO_TEST)	+= wl12xx_sdio_test.o

# small builtin driver bit
obj-$(CONFIG_WL12XX_PLATFORM_DATA)	+= wl12xx_platform_data.o
+2 −2
Original line number Diff line number Diff line
@@ -1041,7 +1041,7 @@ int wl1271_acx_bet_enable(struct wl1271 *wl, bool enable)
	return ret;
}

int wl1271_acx_arp_ip_filter(struct wl1271 *wl, bool enable, __be32 address)
int wl1271_acx_arp_ip_filter(struct wl1271 *wl, u8 enable, __be32 address)
{
	struct wl1271_acx_arp_filter *acx;
	int ret;
@@ -1057,7 +1057,7 @@ int wl1271_acx_arp_ip_filter(struct wl1271 *wl, bool enable, __be32 address)
	acx->version = ACX_IPV4_VERSION;
	acx->enable = enable;

	if (enable == true)
	if (enable)
		memcpy(acx->address, &address, ACX_IPV4_ADDR_SIZE);

	ret = wl1271_cmd_configure(wl, ACX_ARP_IP_FILTER,
+7 −2
Original line number Diff line number Diff line
@@ -868,10 +868,15 @@ struct wl1271_acx_bet_enable {
#define ACX_IPV4_VERSION 4
#define ACX_IPV6_VERSION 6
#define ACX_IPV4_ADDR_SIZE 4

/* bitmap of enabled arp_filter features */
#define ACX_ARP_FILTER_ARP_FILTERING	BIT(0)
#define ACX_ARP_FILTER_AUTO_ARP		BIT(1)

struct wl1271_acx_arp_filter {
	struct acx_header header;
	u8 version;         /* ACX_IPV4_VERSION, ACX_IPV6_VERSION */
	u8 enable;          /* 1 to enable ARP filtering, 0 to disable */
	u8 enable;          /* bitmap of enabled ARP filtering features */
	u8 padding[2];
	u8 address[16];     /* The configured device IP address - all ARP
			       requests directed to this IP address will pass
@@ -1168,7 +1173,7 @@ int wl1271_acx_init_mem_config(struct wl1271 *wl);
int wl1271_acx_init_rx_interrupt(struct wl1271 *wl);
int wl1271_acx_smart_reflex(struct wl1271 *wl);
int wl1271_acx_bet_enable(struct wl1271 *wl, bool enable);
int wl1271_acx_arp_ip_filter(struct wl1271 *wl, bool enable, __be32 address);
int wl1271_acx_arp_ip_filter(struct wl1271 *wl, u8 enable, __be32 address);
int wl1271_acx_pm_config(struct wl1271 *wl);
int wl1271_acx_keep_alive_mode(struct wl1271 *wl, bool enable);
int wl1271_acx_keep_alive_config(struct wl1271 *wl, u8 index, u8 tpl_valid);
+16 −1
Original line number Diff line number Diff line
@@ -467,7 +467,8 @@ static void wl1271_boot_hw_version(struct wl1271 *wl)
	wl->hw_pg_ver = (s8)fuse;
}

int wl1271_boot(struct wl1271 *wl)
/* uploads NVS and firmware */
int wl1271_load_firmware(struct wl1271 *wl)
{
	int ret = 0;
	u32 tmp, clk, pause;
@@ -572,6 +573,20 @@ int wl1271_boot(struct wl1271 *wl)
	if (ret < 0)
		goto out;

out:
	return ret;
}
EXPORT_SYMBOL_GPL(wl1271_load_firmware);

int wl1271_boot(struct wl1271 *wl)
{
	int ret;

	/* upload NVS and firmware */
	ret = wl1271_load_firmware(wl);
	if (ret)
		return ret;

	/* 10.5 start firmware */
	ret = wl1271_boot_run_firmware(wl);
	if (ret < 0)
Loading