summaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ti/wlcore/tx.c
diff options
context:
space:
mode:
authorIdo Yariv <ido@wizery.com>2012-06-20 00:48:23 +0300
committerLuciano Coelho <coelho@ti.com>2012-06-22 10:49:44 +0300
commitb0f0ad39e3d2716fe9ca6e50ce4cda87eb409ee0 (patch)
tree08e84e24d5ff77eced2eabc23d648c4240fe14f1 /drivers/net/wireless/ti/wlcore/tx.c
parent6134323f42b0dbae8e8206414d26cb167b9bedfc (diff)
downloadop-kernel-dev-b0f0ad39e3d2716fe9ca6e50ce4cda87eb409ee0.zip
op-kernel-dev-b0f0ad39e3d2716fe9ca6e50ce4cda87eb409ee0.tar.gz
wlcore: Propagate errors from wl1271_raw_write32
Propagate errors from wl1271_raw_write32 and request for recovery when appropriate. Also rename prefixes of wlcore functions which their prototypes had to be changed. Signed-off-by: Ido Yariv <ido@wizery.com> Signed-off-by: Luciano Coelho <coelho@ti.com>
Diffstat (limited to 'drivers/net/wireless/ti/wlcore/tx.c')
-rw-r--r--drivers/net/wireless/ti/wlcore/tx.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/drivers/net/wireless/ti/wlcore/tx.c b/drivers/net/wireless/ti/wlcore/tx.c
index 90bddf5..b5211be 100644
--- a/drivers/net/wireless/ti/wlcore/tx.c
+++ b/drivers/net/wireless/ti/wlcore/tx.c
@@ -746,9 +746,12 @@ out_ack:
* Interrupt the firmware with the new packets. This is only
* required for older hardware revisions
*/
- if (wl->quirks & WLCORE_QUIRK_END_OF_TRANSACTION)
- wl1271_write32(wl, WL12XX_HOST_WR_ACCESS,
- wl->tx_packets_count);
+ if (wl->quirks & WLCORE_QUIRK_END_OF_TRANSACTION) {
+ ret = wlcore_write32(wl, WL12XX_HOST_WR_ACCESS,
+ wl->tx_packets_count);
+ if (ret < 0)
+ goto out;
+ }
wl1271_handle_tx_low_watermark(wl);
}
@@ -911,9 +914,11 @@ int wlcore_tx_complete(struct wl1271 *wl)
fw_counter = le32_to_cpu(wl->tx_res_if->tx_result_fw_counter);
/* write host counter to chipset (to ack) */
- wl1271_write32(wl, le32_to_cpu(memmap->tx_result) +
- offsetof(struct wl1271_tx_hw_res_if,
- tx_result_host_counter), fw_counter);
+ ret = wlcore_write32(wl, le32_to_cpu(memmap->tx_result) +
+ offsetof(struct wl1271_tx_hw_res_if,
+ tx_result_host_counter), fw_counter);
+ if (ret < 0)
+ goto out;
count = fw_counter - wl->tx_results_count;
wl1271_debug(DEBUG_TX, "tx_complete received, packets: %d", count);
OpenPOWER on IntegriCloud