Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

ath6kl: remove redundant variables netlen, orig_buf, orig_len, dropped and stats

Variables netlen, orig_buf, orig_len, dropped and stats are assigned values
but are never used hence they are redundant and can be removed.

Cleans up clang warnings:
warning: variable 'netlen' set but not used [-Wunused-but-set-variable]
warning: variable 'orig_buf' set but not used [-Wunused-but-set-variable]
warning: variable 'orig_len' set but not used [-Wunused-but-set-variable]
warning: variable 'dropped' set but not used [-Wunused-but-set-variable]
warning: variable 'stats' set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>

authored by

Colin Ian King and committed by
Kalle Valo
619c9700 e8c38062

+3 -12
+2 -8
drivers/net/wireless/ath/ath6kl/htc_pipe.c
··· 746 746 struct htc_endpoint *ep; 747 747 struct htc_packet *packet; 748 748 u8 ep_id, *netdata; 749 - u32 netlen; 750 749 751 750 netdata = skb->data; 752 - netlen = skb->len; 753 751 754 752 htc_hdr = (struct htc_frame_hdr *) netdata; 755 753 ··· 853 855 { 854 856 struct htc_credit_report *report; 855 857 struct htc_record_hdr *record; 856 - u8 *record_buf, *orig_buf; 857 - int orig_len, status; 858 - 859 - orig_buf = buffer; 860 - orig_len = len; 861 - status = 0; 858 + u8 *record_buf; 859 + int status = 0; 862 860 863 861 while (len > 0) { 864 862 if (len < sizeof(struct htc_record_hdr)) {
+1 -2
drivers/net/wireless/ath/ath6kl/main.c
··· 272 272 { 273 273 struct ath6kl_dbglog_hdr debug_hdr; 274 274 struct ath6kl_dbglog_buf debug_buf; 275 - u32 address, length, dropped, firstbuf, debug_hdr_addr; 275 + u32 address, length, firstbuf, debug_hdr_addr; 276 276 int ret, loop; 277 277 u8 *buf; 278 278 ··· 303 303 address = TARG_VTOP(ar->target_type, 304 304 le32_to_cpu(debug_hdr.dbuf_addr)); 305 305 firstbuf = address; 306 - dropped = le32_to_cpu(debug_hdr.dropped); 307 306 ret = ath6kl_diag_read(ar, address, &debug_buf, sizeof(debug_buf)); 308 307 if (ret) 309 308 goto out;
-2
drivers/net/wireless/ath/ath6kl/txrx.c
··· 1701 1701 struct ath6kl_sta *sta; 1702 1702 struct aggr_info_conn *aggr_conn = NULL; 1703 1703 struct rxtid *rxtid; 1704 - struct rxtid_stats *stats; 1705 1704 u16 hold_q_size; 1706 1705 u8 tid, aid; 1707 1706 ··· 1721 1722 return; 1722 1723 1723 1724 rxtid = &aggr_conn->rx_tid[tid]; 1724 - stats = &aggr_conn->stat[tid]; 1725 1725 1726 1726 if (win_sz < AGGR_WIN_SZ_MIN || win_sz > AGGR_WIN_SZ_MAX) 1727 1727 ath6kl_dbg(ATH6KL_DBG_WLAN_RX, "%s: win_sz %d, tid %d\n",