* [linux-next:master 2265/2770] drivers/net/wireless/ath/ath10k/htt_rx.c:1780:7: warning: variable 'more_frags' set but not used
@ 2021-05-13 12:28 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-05-13 12:28 UTC (permalink / raw)
To: Wen Gong
Cc: kbuild-all, Linux Memory Management List, Johannes Berg, Jouni Malinen
[-- Attachment #1: Type: text/plain, Size: 3173 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: ec2618180c3450d06a6a4ba951d4c9a2c689b517
commit: a1166b2653db2f3de7338b9fb8a0f6e924b904ee [2265/2770] ath10k: add CCMP PN replay protection for fragmented frames for PCIe
config: h8300-randconfig-r035-20210513 (attached as .config)
compiler: h8300-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=a1166b2653db2f3de7338b9fb8a0f6e924b904ee
git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
git fetch --no-tags linux-next master
git checkout a1166b2653db2f3de7338b9fb8a0f6e924b904ee
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross W=1 ARCH=h8300
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
drivers/net/wireless/ath/ath10k/htt_rx.c: In function 'ath10k_htt_rx_h_frag_pn_check':
>> drivers/net/wireless/ath/ath10k/htt_rx.c:1780:7: warning: variable 'more_frags' set but not used [-Wunused-but-set-variable]
1780 | bool more_frags;
| ^~~~~~~~~~
vim +/more_frags +1780 drivers/net/wireless/ath/ath10k/htt_rx.c
1770
1771 static bool ath10k_htt_rx_h_frag_pn_check(struct ath10k *ar,
1772 struct sk_buff *skb,
1773 u16 peer_id,
1774 u16 offset,
1775 enum htt_rx_mpdu_encrypt_type enctype)
1776 {
1777 struct ath10k_peer *peer;
1778 union htt_rx_pn_t *last_pn, new_pn = {0};
1779 struct ieee80211_hdr *hdr;
> 1780 bool more_frags;
1781 u8 tid, frag_number;
1782 u32 seq;
1783
1784 peer = ath10k_peer_find_by_id(ar, peer_id);
1785 if (!peer) {
1786 ath10k_dbg(ar, ATH10K_DBG_HTT, "invalid peer for frag pn check\n");
1787 return false;
1788 }
1789
1790 hdr = (struct ieee80211_hdr *)(skb->data + offset);
1791 if (ieee80211_is_data_qos(hdr->frame_control))
1792 tid = ieee80211_get_tid(hdr);
1793 else
1794 tid = ATH10K_TXRX_NON_QOS_TID;
1795
1796 last_pn = &peer->frag_tids_last_pn[tid];
1797 new_pn.pn48 = ath10k_htt_rx_h_get_pn(ar, skb, offset, enctype);
1798 more_frags = ieee80211_has_morefrags(hdr->frame_control);
1799 frag_number = le16_to_cpu(hdr->seq_ctrl) & IEEE80211_SCTL_FRAG;
1800 seq = (__le16_to_cpu(hdr->seq_ctrl) & IEEE80211_SCTL_SEQ) >> 4;
1801
1802 if (frag_number == 0) {
1803 last_pn->pn48 = new_pn.pn48;
1804 peer->frag_tids_seq[tid] = seq;
1805 } else {
1806 if (seq != peer->frag_tids_seq[tid])
1807 return false;
1808
1809 if (new_pn.pn48 != last_pn->pn48 + 1)
1810 return false;
1811
1812 last_pn->pn48 = new_pn.pn48;
1813 }
1814
1815 return true;
1816 }
1817
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 27844 bytes --]
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-05-13 12:29 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-13 12:28 [linux-next:master 2265/2770] drivers/net/wireless/ath/ath10k/htt_rx.c:1780:7: warning: variable 'more_frags' set but not used kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).