[kbuild] [ath6kl:ath11k-bringup 47/93] drivers/net/wireless/ath/ath11k/hal_rx.c:939 ath11k_hal_rx_parse_mon_status_tlv() warn: masked condition '(info1 & (1 << (6))) == 1' is always false.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git ath11k-bringup head: 9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 commit: 627a418bbae46c034b1fd8739c0e94fa62190620 [47/93] ath11k: process monitor status ring for RX stats New smatch warnings: drivers/net/wireless/ath/ath11k/hal_rx.c:939 ath11k_hal_rx_parse_mon_status_tlv() warn: masked condition '(info1 & (1 << (6))) == 1' is always false. drivers/net/wireless/ath/ath11k/hal_rx.c:1117 ath11k_hal_rx_parse_mon_status_tlv() warn: masked condition '(info0 & (1 << (20))) == 1' is always false. Old smatch warnings: drivers/net/wireless/ath/ath11k/hal_rx.c:992 ath11k_hal_rx_parse_mon_status_tlv() warn: masked condition '(info1 & (1 << (2))) == 1' is always false. drivers/net/wireless/ath/ath11k/hal_rx.c:1033 ath11k_hal_rx_parse_mon_status_tlv() warn: masked condition '(info1 & (1 << (7))) == 1' is always false. drivers/net/wireless/ath/ath11k/hal_rx.c:1138 ath11k_hal_rx_parse_mon_status_tlv() warn: masked condition '(info0 & (1 << (20))) == 1' is always false. # https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git/commit/?id=627a418bbae46c034b1fd8739c0e94fa62190620 git remote add ath6kl https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git git remote update ath6kl git checkout 627a418bbae46c034b1fd8739c0e94fa62190620 vim +939 drivers/net/wireless/ath/ath11k/hal_rx.c 627a418b Manikanta Pubbisetty 2019-03-07 874 627a418b Manikanta Pubbisetty 2019-03-07 875 static enum hal_rx_mon_status 627a418b Manikanta Pubbisetty 2019-03-07 876 ath11k_hal_rx_parse_mon_status_tlv(struct ath11k_base *ab, 627a418b Manikanta Pubbisetty 2019-03-07 877 struct hal_rx_mon_ppdu_info *ppdu_info, 627a418b Manikanta Pubbisetty 2019-03-07 878 u32 tlv_tag, u8 *tlv_data) 627a418b Manikanta Pubbisetty 2019-03-07 879 { 627a418b Manikanta Pubbisetty 2019-03-07 880 u32 info0, info1; 627a418b Manikanta Pubbisetty 2019-03-07 881 627a418b Manikanta Pubbisetty 2019-03-07 882 switch (tlv_tag) { 627a418b Manikanta Pubbisetty 2019-03-07 883 case HAL_RX_PPDU_START: { 627a418b Manikanta Pubbisetty 2019-03-07 884 struct hal_rx_ppdu_start *ppdu_start = 627a418b Manikanta Pubbisetty 2019-03-07 885 (struct hal_rx_ppdu_start *)tlv_data; 627a418b Manikanta Pubbisetty 2019-03-07 886 627a418b Manikanta Pubbisetty 2019-03-07 887 ppdu_info->ppdu_id = 627a418b Manikanta Pubbisetty 2019-03-07 888 FIELD_GET(HAL_RX_PPDU_START_INFO0_PPDU_ID, 627a418b Manikanta Pubbisetty 2019-03-07 889 __le32_to_cpu(ppdu_start->info0)); 627a418b Manikanta Pubbisetty 2019-03-07 890 ppdu_info->chan_num = __le32_to_cpu(ppdu_start->chan_num); 627a418b Manikanta Pubbisetty 2019-03-07 891 ppdu_info->ppdu_ts = __le32_to_cpu(ppdu_start->ppdu_start_ts); 627a418b Manikanta Pubbisetty 2019-03-07 892 break; 627a418b Manikanta Pubbisetty 2019-03-07 893 } 627a418b Manikanta Pubbisetty 2019-03-07 894 case HAL_RX_PPDU_END_USER_STATS: { 627a418b Manikanta Pubbisetty 2019-03-07 895 struct hal_rx_ppdu_end_user_stats *eu_stats = 627a418b Manikanta Pubbisetty 2019-03-07 896 (struct hal_rx_ppdu_end_user_stats *)tlv_data; 627a418b Manikanta Pubbisetty 2019-03-07 897 627a418b Manikanta Pubbisetty 2019-03-07 898 info0 = __le32_to_cpu(eu_stats->info0); 627a418b Manikanta Pubbisetty 2019-03-07 899 info1 = __le32_to_cpu(eu_stats->info1); 627a418b Manikanta Pubbisetty 2019-03-07 900 627a418b Manikanta Pubbisetty 2019-03-07 901 ppdu_info->tid = 627a418b Manikanta Pubbisetty 2019-03-07 902 ffs(FIELD_GET(HAL_RX_PPDU_END_USER_STATS_INFO6_TID_BITMAP, 627a418b Manikanta Pubbisetty 2019-03-07 903 __le32_to_cpu(eu_stats->info6))) - 1; 627a418b Manikanta Pubbisetty 2019-03-07 904 ppdu_info->tcp_msdu_count = 627a418b Manikanta Pubbisetty 2019-03-07 905 FIELD_GET(HAL_RX_PPDU_END_USER_STATS_INFO4_TCP_MSDU_CNT, 627a418b Manikanta Pubbisetty 2019-03-07 906 __le32_to_cpu(eu_stats->info4)); 627a418b Manikanta Pubbisetty 2019-03-07 907 ppdu_info->udp_msdu_count = 627a418b Manikanta Pubbisetty 2019-03-07 908 FIELD_GET(HAL_RX_PPDU_END_USER_STATS_INFO4_UDP_MSDU_CNT, 627a418b Manikanta Pubbisetty 2019-03-07 909 __le32_to_cpu(eu_stats->info4)); 627a418b Manikanta Pubbisetty 2019-03-07 910 ppdu_info->other_msdu_count = 627a418b Manikanta Pubbisetty 2019-03-07 911
[kbuild] [lunn:v5.1-rc1-cable-test 10/53] net/ethtool/netlink.c:231 ethnl_get_doit() warn: potential spectre issue 'get_requests' [r]
tree: https://github.com/lunn/linux.git v5.1-rc1-cable-test head: b9bb5e57b75afd80ddd0915ffbf68724645e5717 commit: de6fe7af541d1c62d14e0892987321cdee3dad8c [10/53] ethtool: generic handlers for GET requests New smatch warnings: net/ethtool/netlink.c:231 ethnl_get_doit() warn: potential spectre issue 'get_requests' [r] net/ethtool/netlink.c:232 ethnl_get_doit() warn: possible spectre second half. 'ops' net/ethtool/netlink.c:278 ethnl_get_doit() error: dereferencing freed memory 'req_info' # https://github.com/lunn/linux/commit/de6fe7af541d1c62d14e0892987321cdee3dad8c git remote add lunn https://github.com/lunn/linux.git git remote update lunn git checkout de6fe7af541d1c62d14e0892987321cdee3dad8c vim +/get_requests +231 net/ethtool/netlink.c de6fe7af Michal Kubecek 2018-07-24 219 de6fe7af Michal Kubecek 2018-07-24 220 /* generic ->doit() handler for GET type requests */ de6fe7af Michal Kubecek 2018-07-24 221 int ethnl_get_doit(struct sk_buff *skb, struct genl_info *info) de6fe7af Michal Kubecek 2018-07-24 222 { de6fe7af Michal Kubecek 2018-07-24 223 const u8 cmd = info->genlhdr->cmd; de6fe7af Michal Kubecek 2018-07-24 224 struct common_req_info *req_info; de6fe7af Michal Kubecek 2018-07-24 225 const struct get_request_ops *ops; de6fe7af Michal Kubecek 2018-07-24 226 struct sk_buff *rskb; de6fe7af Michal Kubecek 2018-07-24 227 void *reply_payload; de6fe7af Michal Kubecek 2018-07-24 228 int reply_len; de6fe7af Michal Kubecek 2018-07-24 229 int ret; de6fe7af Michal Kubecek 2018-07-24 230 de6fe7af Michal Kubecek 2018-07-24 @231 ops = get_requests[cmd]; de6fe7af Michal Kubecek 2018-07-24 @232 if (WARN_ONCE(!ops, "cmd %u has no get_request_ops\n", cmd)) This is a weird one. Smatch is saying that "cmd" comes from the user somehow but we didn't disable speculation. "cmd" is a u8 so it can't read very far beyond the end of get_requests[] so it's not a huge deal. We (Linus) really only care about Spectre issues where there is a second half. Meaning that we take a value from the user, do a bounds check, read from the get_requests[] and use "ops". The "!ops" is the second half in this context. If we have a nospec barrier or too many instructions between the bounds check and the use of "ops" then it doesn't count. Anyway, I will try remember to look at this code once it hits linux-next to see why it's warning. (This email is generated by the zero day bot, I just forward it. I haven't looked at the code). The use after free warning below is more straight forward. de6fe7af Michal Kubecek 2018-07-24 233 return -EOPNOTSUPP; de6fe7af Michal Kubecek 2018-07-24 234 req_info = ethnl_alloc_get_data(ops); de6fe7af Michal Kubecek 2018-07-24 235 if (!req_info) de6fe7af Michal Kubecek 2018-07-24 236 return -ENOMEM; de6fe7af Michal Kubecek 2018-07-24 237 ret = ops->parse_request(req_info, skb, info, info->nlhdr); de6fe7af Michal Kubecek 2018-07-24 238 if (!ops->allow_nodev_do && !req_info->dev) { de6fe7af Michal Kubecek 2018-07-24 239 ETHNL_SET_ERRMSG(info, "device not specified in do request"); de6fe7af Michal Kubecek 2018-07-24 240 ret = -EINVAL; de6fe7af Michal Kubecek 2018-07-24 241 } de6fe7af Michal Kubecek 2018-07-24 242 if (ret < 0) de6fe7af Michal Kubecek 2018-07-24 243 goto err_dev; de6fe7af Michal Kubecek 2018-07-24 244 ethnl_init_reply_data(req_info, ops, req_info->dev); de6fe7af Michal Kubecek 2018-07-24 245 de6fe7af Michal Kubecek 2018-07-24 246 rtnl_lock(); de6fe7af Michal Kubecek 2018-07-24 247 ret = ops->prepare_data(req_info, info); de6fe7af Michal Kubecek 2018-07-24 248 if (ret < 0) de6fe7af Michal Kubecek 2018-07-24 249 goto err_rtnl; de6fe7af Michal Kubecek 2018-07-24 250 reply_len = ops->reply_size(req_info); de6fe7af Michal Kubecek 2018-07-24 251 if (ret < 0) de6fe7af Michal Kubecek 2018-07-24 252 goto err_rtnl; de6fe7af Michal Kubecek 2018-07-24 253 ret = -ENOMEM; de6fe7af Michal Kubecek 2018-07-24 254 rskb = ethnl_reply_init(reply_len, req_info->dev, ops->reply_cmd, de6fe7af Michal Kubecek 2018-07-24 255 ops->dev_attrtype, info, _payload); de6fe7af Michal Kubecek 2018-07-24 256 if (!rskb) de6fe7af Michal Kubecek 2018-07-24 257 goto err_rtnl; de6fe7af Michal Kubecek 2018-07-24 258 ret = ops->fill_reply(rskb, req_info); de6fe7af Michal Kubecek 2018-07-24 259 if (ret < 0) de6fe7af Michal Kubecek 2018-07-24 260 goto err; de6fe7af Michal Kubecek 2018-07-24 261 rtnl_unlock(); de6fe7af Michal Kubecek 2018-07-24 262 de6fe7af Michal Kubecek 2018-07-24 263 genlmsg_end(rskb, reply_payload); de6fe7af Michal Kubecek 2018-07-24 264
[kbuild] [ambarus:spi-nor/next 1/2] drivers/mtd/spi-nor/spi-nor.c:308 spi_nor_exec_op() error: uninitialized symbol 'usebouncebuf'.
tree: https://github.com/ambarus/linux-0day spi-nor/next head: b266e7342c0c1095237d8408691e30c4cf5210e0 commit: 08e052bc80003c679d700a5759f8ac079a13d05a [1/2] mtd: spi-nor: Move m25p80 code in spi-nor.c :: branch date: 7 hours ago :: commit date: 7 hours ago New smatch warnings: drivers/mtd/spi-nor/spi-nor.c:308 spi_nor_exec_op() error: uninitialized symbol 'usebouncebuf'. Old smatch warnings: drivers/mtd/spi-nor/spi-nor.c:326 spi_nor_exec_op() error: uninitialized symbol 'usebouncebuf'. # https://github.com/ambarus/linux-0day/commit/08e052bc80003c679d700a5759f8ac079a13d05a git remote add ambarus https://github.com/ambarus/linux-0day git remote update ambarus git checkout 08e052bc80003c679d700a5759f8ac079a13d05a vim +/usebouncebuf +308 drivers/mtd/spi-nor/spi-nor.c 08e052bc Boris Brezillon 2019-04-09 292 static int spi_nor_exec_op(struct spi_nor *nor, struct spi_mem_op *op, 08e052bc Boris Brezillon 2019-04-09 293 u64 *addr, void *buf, unsigned int len) 08e052bc Boris Brezillon 2019-04-09 294 { 08e052bc Boris Brezillon 2019-04-09 295int ret; 08e052bc Boris Brezillon 2019-04-09 296bool usebouncebuf; ^ Set to false here. 08e052bc Boris Brezillon 2019-04-09 297 08e052bc Boris Brezillon 2019-04-09 298if (!op || (len && !buf)) 08e052bc Boris Brezillon 2019-04-09 299return -EINVAL; 08e052bc Boris Brezillon 2019-04-09 300 08e052bc Boris Brezillon 2019-04-09 301if (op->addr.nbytes && addr) 08e052bc Boris Brezillon 2019-04-09 302op->addr.val = *addr; 08e052bc Boris Brezillon 2019-04-09 303 08e052bc Boris Brezillon 2019-04-09 304op->data.nbytes = len; 08e052bc Boris Brezillon 2019-04-09 305 08e052bc Boris Brezillon 2019-04-09 306if (object_is_on_stack(buf) || !virt_addr_valid(buf)) 08e052bc Boris Brezillon 2019-04-09 307usebouncebuf = true; ^^^ 08e052bc Boris Brezillon 2019-04-09 @308if (len && usebouncebuf) { 08e052bc Boris Brezillon 2019-04-09 309if (len > nor->bouncebuf_size) 08e052bc Boris Brezillon 2019-04-09 310return -ENOTSUPP; 08e052bc Boris Brezillon 2019-04-09 311 08e052bc Boris Brezillon 2019-04-09 312if (op->data.dir == SPI_MEM_DATA_IN) { 08e052bc Boris Brezillon 2019-04-09 313op->data.buf.in = nor->bouncebuf; 08e052bc Boris Brezillon 2019-04-09 314} else { 08e052bc Boris Brezillon 2019-04-09 315 op->data.buf.out = nor->bouncebuf; 08e052bc Boris Brezillon 2019-04-09 316 memcpy(nor->bouncebuf, buf, len); 08e052bc Boris Brezillon 2019-04-09 317} 08e052bc Boris Brezillon 2019-04-09 318} else { 08e052bc Boris Brezillon 2019-04-09 319op->data.buf.out = buf; 08e052bc Boris Brezillon 2019-04-09 320} 08e052bc Boris Brezillon 2019-04-09 321 08e052bc Boris Brezillon 2019-04-09 322ret = spi_mem_exec_op(nor->spimem, op); 08e052bc Boris Brezillon 2019-04-09 323if (ret) 08e052bc Boris Brezillon 2019-04-09 324return ret; 08e052bc Boris Brezillon 2019-04-09 325 08e052bc Boris Brezillon 2019-04-09 326if (usebouncebuf && len && op->data.dir == SPI_MEM_DATA_IN) 08e052bc Boris Brezillon 2019-04-09 327memcpy(buf, nor->bouncebuf, len); 08e052bc Boris Brezillon 2019-04-09 328 08e052bc Boris Brezillon 2019-04-09 329return 0; 08e052bc Boris Brezillon 2019-04-09 330 } --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation ___ kbuild mailing list kbuild@lists.01.org https://lists.01.org/mailman/listinfo/kbuild
[kbuild] [ath6kl:ath11k-bringup 66/93] drivers/net/wireless/ath/ath11k/core.c:755 ath11k_core_restart() warn: inconsistent returns 'mutex:>core_lock'.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git ath11k-bringup head: 9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 commit: 3a7b4838b6f6f234239f263ef3dc02e612a083ad [66/93] ath11k: Add support for subsystem recovery :: branch date: 4 days ago :: commit date: 12 days ago New smatch warnings: drivers/net/wireless/ath/ath11k/core.c:755 ath11k_core_restart() warn: inconsistent returns 'mutex:>core_lock'. Locked on: line 722 Unlocked on: line 755 # https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git/commit/?id=3a7b4838b6f6f234239f263ef3dc02e612a083ad git remote add ath6kl https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git git remote update ath6kl git checkout 3a7b4838b6f6f234239f263ef3dc02e612a083ad vim +755 drivers/net/wireless/ath/ath11k/core.c 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 683 static void ath11k_core_restart(struct work_struct *work) 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 684 { 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 685 struct ath11k_base *sc = container_of(work, struct ath11k_base, restart_work); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 686 struct ath11k *ar; 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 687 struct ath11k_pdev *pdev; 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 688 int i, ret = 0; 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 689 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 690 spin_lock_bh(>data_lock); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 691 sc->stats.fw_crash_counter++; 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 692 spin_unlock_bh(>data_lock); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 693 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 694 for (i = 0; i < sc->num_radios; i++) { 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 695 pdev = >pdevs[i]; 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 696 ar = pdev->ar; 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 697 if (!ar || ar->state == ATH11K_STATE_OFF) 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 698 continue; 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 699 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 700 ieee80211_stop_queues(ar->hw); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 701 ath11k_drain_tx(ar); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 702 complete(>scan.started); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 703 complete(>scan.completed); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 704 complete(>peer_assoc_done); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 705 complete(>install_key_done); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 706 complete(>vdev_setup_done); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 707 complete(>bss_survey_done); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 708 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 709 wake_up(>dp.tx_empty_waitq); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 710 idr_for_each(>txmgmt_idr, 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 711 ath11k_mac_tx_mgmt_pending_free, ar); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 712 idr_destroy(>txmgmt_idr); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 713 } 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 714 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 715 wake_up(>wmi_sc.tx_credits_wq); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 716 wake_up(>peer_mapping_wq); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 717 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 718 mutex_lock(>core_lock); ^^ 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 719 ret = ath11k_core_reconfigure_on_crash(sc); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 720 if (ret) { 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 721 ath11k_err(sc, "failed to reconfigure driver on crash recovery\n"); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 722 return; ^^^ Need to unlock. 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 723 } 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 724 mutex_unlock(>core_lock); 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 725 3a7b4838 Pradeep Kumar Chitrapu 2019-03-21 726 for (i = 0; i < sc->num_radios; i++) { --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation ___ kbuild mailing list kbuild@lists.01.org https://lists.01.org/mailman/listinfo/kbuild
[kbuild] [ath6kl:ath11k-bringup 92/93] drivers/net/wireless/ath/ath11k/dp_rx.c:991 ath11k_htt_pull_ppdu_stats() warn: add some parenthesis here?
tree: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git ath11k-bringup head: 9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 commit: b186001339ca6058afd49d7611647bd766dd555e [92/93] ath11k: add pktlog rxbuf support New smatch warnings: drivers/net/wireless/ath/ath11k/dp_rx.c:991 ath11k_htt_pull_ppdu_stats() warn: add some parenthesis here? Old smatch warnings: drivers/net/wireless/ath/ath11k/dp_rx.c:320 ath11k_dp_rx_tid_del_func() error: not allocating enough data 36 vs 4 drivers/net/wireless/ath/ath11k/dp_rx.c:951 ath11k_dp_htt_get_ppdu_desc() error: we previously assumed 'ppdu_info' could be null (see line 952) # https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git/commit/?id=b186001339ca6058afd49d7611647bd766dd555e git remote add ath6kl https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git git remote update ath6kl git checkout b186001339ca6058afd49d7611647bd766dd555e vim +991 drivers/net/wireless/ath/ath11k/dp_rx.c 258bbf52 Kalle Valo 2019-02-05 976 static int ath11k_htt_pull_ppdu_stats(struct ath11k_base *ab, 258bbf52 Kalle Valo 2019-02-05 977 struct sk_buff *skb) { 258bbf52 Kalle Valo 2019-02-05 978 u8 *data = (u8 *)skb->data; 258bbf52 Kalle Valo 2019-02-05 979 struct htt_ppdu_stats_info *ppdu_info; 258bbf52 Kalle Valo 2019-02-05 980 struct ath11k *ar; 258bbf52 Kalle Valo 2019-02-05 981 int ret; 258bbf52 Kalle Valo 2019-02-05 982 u8 pdev_id; 258bbf52 Kalle Valo 2019-02-05 983 u32 ppdu_id, len; 258bbf52 Kalle Valo 2019-02-05 984 258bbf52 Kalle Valo 2019-02-05 985 len = FIELD_GET(HTT_T2H_PPDU_STATS_PAYLOAD_SIZE_M, *(u32 *)data); 258bbf52 Kalle Valo 2019-02-05 986 pdev_id = FIELD_GET(HTT_T2H_PPDU_STATS_PDEV_ID_M, *(u32 *)data); 258bbf52 Kalle Valo 2019-02-05 987 pdev_id = DP_HW2SW_MACID(pdev_id); 258bbf52 Kalle Valo 2019-02-05 988 ppdu_id = *((u32 *)data + 1); 258bbf52 Kalle Valo 2019-02-05 989 ar = ab->pdevs[pdev_id].ar; 258bbf52 Kalle Valo 2019-02-05 990 b1860013 Anilkumar Kolli 2019-04-05 @991 if (!ar->debug.pktlog_mode == ATH11K_PKTLOG_MODE_LITE) { ^ This should be != instead of !foo == bar. b1860013 Anilkumar Kolli 2019-04-05 992 /* TODO update the pktlog tracing */ b1860013 Anilkumar Kolli 2019-04-05 993 } af4ab3f8 Anilkumar Kolli 2019-04-05 994 258bbf52 Kalle Valo 2019-02-05 995 /* TLV info starts after 16bytes of header */ 258bbf52 Kalle Valo 2019-02-05 996 data = (u8 *)data + 16; 258bbf52 Kalle Valo 2019-02-05 997 258bbf52 Kalle Valo 2019-02-05 998 ppdu_info = ath11k_dp_htt_get_ppdu_desc(ar, ppdu_id); 258bbf52 Kalle Valo 2019-02-05 999 if (!ppdu_info) 258bbf52 Kalle Valo 2019-02-05 1000 return 0; 258bbf52 Kalle Valo 2019-02-05 1001 258bbf52 Kalle Valo 2019-02-05 1002 ppdu_info->ppdu_id = ppdu_id; 258bbf52 Kalle Valo 2019-02-05 1003 ret = ath11k_dp_htt_tlv_iter(ab, data, len, 258bbf52 Kalle Valo 2019-02-05 1004 ath11k_htt_tlv_ppdu_stats_parse, 258bbf52 Kalle Valo 2019-02-05 1005 (void *)ppdu_info); 258bbf52 Kalle Valo 2019-02-05 1006 if (ret) { 258bbf52 Kalle Valo 2019-02-05 1007 ath11k_warn(ab, "Failed to parse tlv %d\n", ret); 258bbf52 Kalle Valo 2019-02-05 1008 return ret; 258bbf52 Kalle Valo 2019-02-05 1009 } 258bbf52 Kalle Valo 2019-02-05 1010 258bbf52 Kalle Valo 2019-02-05 1011 return 0; 258bbf52 Kalle Valo 2019-02-05 1012 } --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation ___ kbuild mailing list kbuild@lists.01.org https://lists.01.org/mailman/listinfo/kbuild
[kbuild] [ath6kl:ath11k-bringup 93/93] drivers/net/wireless/ath/ath11k/debug.c:1143 ath11k_write_pktlog_filter() warn: inconsistent returns 'mutex:>conf_mutex'.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git ath11k-bringup head: 9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 commit: 9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 [93/93] ath11k: enable pktlog filter per peer New smatch warnings: drivers/net/wireless/ath/ath11k/debug.c:1143 ath11k_write_pktlog_filter() warn: inconsistent returns 'mutex:>conf_mutex'. Locked on: line 1115 Unlocked on: line 1143 Old smatch warnings: drivers/net/wireless/ath/ath11k/debug.c:700 ath11k_write_simulate_fw_crash() error: uninitialized symbol 'radioup'. # https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git/commit/?id=9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 git remote add ath6kl https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git git remote update ath6kl git checkout 9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 vim +1143 drivers/net/wireless/ath/ath11k/debug.c d25cb35c Sathishkumar Muruganandam 2019-02-13 988 62a55be6 Anilkumar Kolli 2019-04-05 989 static ssize_t ath11k_write_pktlog_filter(struct file *file, 62a55be6 Anilkumar Kolli 2019-04-05 990 const char __user *ubuf, 62a55be6 Anilkumar Kolli 2019-04-05 991 size_t count, loff_t *ppos) 62a55be6 Anilkumar Kolli 2019-04-05 992 { 62a55be6 Anilkumar Kolli 2019-04-05 993 struct ath11k *ar = file->private_data; b1860013 Anilkumar Kolli 2019-04-05 994 struct htt_rx_ring_tlv_filter tlv_filter = {0}; 9bcbbf4c Anilkumar Kolli 2019-04-05 995 u32 rx_filter = 0, ring_id, filter, peer_valid; 9bcbbf4c Anilkumar Kolli 2019-04-05 996 u8 buf[128] = {0}, mac_addr[ETH_ALEN] = {0}, mode; b1860013 Anilkumar Kolli 2019-04-05 997 char *token, *sptr; 9bcbbf4c Anilkumar Kolli 2019-04-05 998 int ret, i; b1860013 Anilkumar Kolli 2019-04-05 999 ssize_t rc; 62a55be6 Anilkumar Kolli 2019-04-05 1000 62a55be6 Anilkumar Kolli 2019-04-05 1001 mutex_lock(>conf_mutex); 62a55be6 Anilkumar Kolli 2019-04-05 1002 if (ar->state != ATH11K_STATE_ON) { 62a55be6 Anilkumar Kolli 2019-04-05 1003 ret = -ENETDOWN; 62a55be6 Anilkumar Kolli 2019-04-05 1004 goto out; 62a55be6 Anilkumar Kolli 2019-04-05 1005 } 62a55be6 Anilkumar Kolli 2019-04-05 1006 b1860013 Anilkumar Kolli 2019-04-05 1007 rc = simple_write_to_buffer(buf, sizeof(buf) - 1, ppos, ubuf, count); b1860013 Anilkumar Kolli 2019-04-05 1008 if (rc < 0) { b1860013 Anilkumar Kolli 2019-04-05 1009 ret = rc; b1860013 Anilkumar Kolli 2019-04-05 1010 goto out; b1860013 Anilkumar Kolli 2019-04-05 1011 } b1860013 Anilkumar Kolli 2019-04-05 1012 buf[rc] = '\0'; b1860013 Anilkumar Kolli 2019-04-05 1013 sptr = buf; b1860013 Anilkumar Kolli 2019-04-05 1014 b1860013 Anilkumar Kolli 2019-04-05 1015 token = strsep(, " "); b1860013 Anilkumar Kolli 2019-04-05 1016 if (!token) { b1860013 Anilkumar Kolli 2019-04-05 1017 ret = -EINVAL; b1860013 Anilkumar Kolli 2019-04-05 1018 goto out; b1860013 Anilkumar Kolli 2019-04-05 1019 } b1860013 Anilkumar Kolli 2019-04-05 1020 b1860013 Anilkumar Kolli 2019-04-05 1021 if (kstrtou32(token, 0, )) { b1860013 Anilkumar Kolli 2019-04-05 1022 ret = -EINVAL; b1860013 Anilkumar Kolli 2019-04-05 1023 goto out; b1860013 Anilkumar Kolli 2019-04-05 1024 } b1860013 Anilkumar Kolli 2019-04-05 1025 62a55be6 Anilkumar Kolli 2019-04-05 1026 if (filter == ar->debug.pktlog_filter) { 62a55be6 Anilkumar Kolli 2019-04-05 1027 ret = count; 62a55be6 Anilkumar Kolli 2019-04-05 1028 goto out; 62a55be6 Anilkumar Kolli 2019-04-05 1029 } 62a55be6 Anilkumar Kolli 2019-04-05 1030 b1860013 Anilkumar Kolli 2019-04-05 1031 if (filter) { b1860013 Anilkumar Kolli 2019-04-05 1032 ret = ath11k_wmi_pdev_pktlog_enable(ar, filter); b1860013 Anilkumar Kolli 2019-04-05 1033 if (ret) { 62a55be6 Anilkumar Kolli 2019-04-05 1034 ath11k_warn(ar->ab, 62a55be6 Anilkumar Kolli 2019-04-05 1035 "failed to enable pktlog filter %x: %d\n", 62a55be6 Anilkumar Kolli 2019-04-05 1036 ar->debug.pktlog_filter, ret); b1860013 Anilkumar Kolli 2019-04-05 1037 goto out; b1860013 Anilkumar Kolli 2019-04-05 1038 } 62a55be6 Anilkumar Kolli 2019-04-05
[kbuild] [dsahern-linux:5.1-next-v6-refactor 5/13] net/ipv6/route.c:1063 ip6_create_rt_rcu() error: uninitialized symbol 'dev'.
[ I haven't seen David's patch but maybe this was a merge problem? -dan ] tree: https://github.com/dsahern/linux 5.1-next-v6-refactor head: 0293742ba53011833a9a1fc9f596a89f595e3c55 commit: 4a35ef611a939c3047937c58d935021ab08788ce [5/13] ipv6: Pass fib6_result to ip6_create_rt_rcu New smatch warnings: net/ipv6/route.c:1063 ip6_create_rt_rcu() error: uninitialized symbol 'dev'. Old smatch warnings: net/ipv6/route.c:2838 ip6_route_check_nh() error: we previously assumed '_dev' could be null (see line 2808) net/ipv6/route.c:4487 ip6_route_multipath_add() error: we previously assumed 'cfg->fc_nlinfo.nlh' could be null (see line 4389) # https://github.com/dsahern/linux/commit/4a35ef611a939c3047937c58d935021ab08788ce git remote add dsahern-linux https://github.com/dsahern/linux git remote update dsahern-linux git checkout 4a35ef611a939c3047937c58d935021ab08788ce vim +/dev +1063 net/ipv6/route.c d3843fe5 Wei Wang2017-10-06 1039 dec9b0e2 David Ahern 2018-04-17 1040 /* called with rcu_lock held */ 4a35ef61 David Ahern 2019-04-13 1041 static struct rt6_info *ip6_create_rt_rcu(const struct fib6_result *res) dec9b0e2 David Ahern 2018-04-17 1042 { 4a35ef61 David Ahern 2019-04-13 1043 struct fib6_info *f6i = res->f6i; 4a35ef61 David Ahern 2019-04-13 1044 struct net_device *dev; ^^^ 4a35ef61 David Ahern 2019-04-13 1045 unsigned short flags; dec9b0e2 David Ahern 2018-04-17 1046 struct rt6_info *nrt; dec9b0e2 David Ahern 2018-04-17 1047 4a35ef61 David Ahern 2019-04-13 1048 if (!fib6_info_hold_safe(f6i)) 1c87e79a Xin Long2019-03-20 1049 goto fallback; ^^ e873e4b9 Wei Wang2018-07-21 1050 4a35ef61 David Ahern 2019-04-13 1051 flags = fib6_info_dst_flags(f6i); 4a35ef61 David Ahern 2019-04-13 1052 dev = res->nh->fib_nh_dev; 93531c67 David Ahern 2018-04-17 1053 nrt = ip6_dst_alloc(dev_net(dev), dev, flags); 1c87e79a Xin Long2019-03-20 1054 if (!nrt) { 4a35ef61 David Ahern 2019-04-13 1055 fib6_info_release(f6i); 1c87e79a Xin Long2019-03-20 1056 goto fallback; 1c87e79a Xin Long2019-03-20 1057 } 1c87e79a Xin Long2019-03-20 1058 4a35ef61 David Ahern 2019-04-13 1059 ip6_rt_copy_init(nrt, f6i); 1c87e79a Xin Long2019-03-20 1060 return nrt; dec9b0e2 David Ahern 2018-04-17 1061 1c87e79a Xin Long2019-03-20 1062 fallback: 1c87e79a Xin Long2019-03-20 @1063 nrt = dev_net(dev)->ipv6.ip6_null_entry; ^^^ 1c87e79a Xin Long2019-03-20 1064 dst_hold(>dst); dec9b0e2 David Ahern 2018-04-17 1065 return nrt; dec9b0e2 David Ahern 2018-04-17 1066 } dec9b0e2 David Ahern 2018-04-17 1067 --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation ___ kbuild mailing list kbuild@lists.01.org https://lists.01.org/mailman/listinfo/kbuild
[kbuild] [ath6kl:ath11k-bringup 58/93] drivers/net/wireless/ath/ath11k/debug.c:697 ath11k_write_simulate_fw_crash() error: uninitialized symbol 'radioup'.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git ath11k-bringup head: 9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 commit: 5cf3588467b76d48542fd0ff70fc666a723df3bb [58/93] ath11k: make simulate_fw_crash to work if any radio is up smatch warnings: drivers/net/wireless/ath/ath11k/debug.c:697 ath11k_write_simulate_fw_crash() error: uninitialized symbol 'radioup'. # https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git/commit/?id=5cf3588467b76d48542fd0ff70fc666a723df3bb git remote add ath6kl https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git git remote update ath6kl git checkout 5cf3588467b76d48542fd0ff70fc666a723df3bb vim +/radioup +697 drivers/net/wireless/ath/ath11k/debug.c 258bbf52 Kalle Valo2019-02-05 657 258bbf52 Kalle Valo2019-02-05 658 /* Simulate firmware crash: 258bbf52 Kalle Valo2019-02-05 659 * 'soft': Call wmi command causing firmware hang. This firmware hang is 258bbf52 Kalle Valo2019-02-05 660 * recoverable by warm firmware reset. 258bbf52 Kalle Valo2019-02-05 661 * 'hard': Force firmware crash by setting any vdev parameter for not allowed 258bbf52 Kalle Valo2019-02-05 662 * vdev id. This is hard firmware crash because it is recoverable only by cold 258bbf52 Kalle Valo2019-02-05 663 * firmware reset. 258bbf52 Kalle Valo2019-02-05 664 */ 258bbf52 Kalle Valo2019-02-05 665 static ssize_t ath11k_write_simulate_fw_crash(struct file *file, 258bbf52 Kalle Valo2019-02-05 666 const char __user *user_buf, 258bbf52 Kalle Valo2019-02-05 667 size_t count, loff_t *ppos) 258bbf52 Kalle Valo2019-02-05 668 { d25cb35c Sathishkumar Muruganandam 2019-02-13 669 struct ath11k_base *ab = file->private_data; 5cf35884 Pradeep Kumar Chitrapu2019-03-15 670 struct ath11k_pdev *pdev; d25cb35c Sathishkumar Muruganandam 2019-02-13 671 struct ath11k *ar = ab->pdevs[0].ar; 258bbf52 Kalle Valo2019-02-05 672 struct crash_inject param; 258bbf52 Kalle Valo2019-02-05 673 char buf[32] = {0}; 258bbf52 Kalle Valo2019-02-05 674 ssize_t rc; 5cf35884 Pradeep Kumar Chitrapu2019-03-15 675 int i, ret, radioup; ^^^ Never set to zero. 258bbf52 Kalle Valo2019-02-05 676 5cf35884 Pradeep Kumar Chitrapu2019-03-15 677 for (i = 0; i < ab->num_radios; i++) { 5cf35884 Pradeep Kumar Chitrapu2019-03-15 678 pdev = >pdevs[i]; 5cf35884 Pradeep Kumar Chitrapu2019-03-15 679 ar = pdev->ar; 5cf35884 Pradeep Kumar Chitrapu2019-03-15 680 if (ar && ar->state == ATH11K_STATE_ON) { 5cf35884 Pradeep Kumar Chitrapu2019-03-15 681 radioup = 1; ^^^ 5cf35884 Pradeep Kumar Chitrapu2019-03-15 682 break; 5cf35884 Pradeep Kumar Chitrapu2019-03-15 683 } 5cf35884 Pradeep Kumar Chitrapu2019-03-15 684 } 258bbf52 Kalle Valo2019-02-05 685 /* filter partial writes and invalid commands */ 258bbf52 Kalle Valo2019-02-05 686 if (*ppos != 0 || count >= sizeof(buf) || count == 0) 258bbf52 Kalle Valo2019-02-05 687 return -EINVAL; 258bbf52 Kalle Valo2019-02-05 688 258bbf52 Kalle Valo2019-02-05 689 rc = simple_write_to_buffer(buf, sizeof(buf) - 1, ppos, user_buf, count); 258bbf52 Kalle Valo2019-02-05 690 if (rc < 0) 258bbf52 Kalle Valo2019-02-05 691 return rc; 258bbf52 Kalle Valo2019-02-05 692 258bbf52 Kalle Valo2019-02-05 693 /* drop the possible '\n' from the end */ 258bbf52 Kalle Valo2019-02-05 694 if (buf[*ppos - 1] == '\n') 258bbf52 Kalle Valo2019-02-05 695 buf[*ppos - 1] = '\0'; 258bbf52 Kalle Valo2019-02-05 696 5cf35884 Pradeep Kumar Chitrapu2019-03-15 @697 if (radioup == 0) { 258bbf52 Kalle Valo2019-02-05 698 ret = -ENETDOWN; 258bbf52 Kalle Valo2019-02-05 699 goto exit; 258bbf52 Kalle Valo2019-02-05 700 } 258bbf52 Kalle Valo2019-02-05 701 258bbf52 Kalle Valo2019-02-05 702 if (!strcmp(buf, "assert")) { d25cb35c Sathishkumar Muruganandam 2019-02-13 703 ath11k_info(ab, "simulating firmware assert crash\n"); 258bbf52
[kbuild] [lunn:v5.1-rc1-cable-test 12/53] net/ethtool/strset.c:168 parse_strset() warn: passing zero to 'PTR_ERR'
tree: https://github.com/lunn/linux.git v5.1-rc1-cable-test head: b9bb5e57b75afd80ddd0915ffbf68724645e5717 commit: b1e164cd0b8cfd588738d646298e44264c72e16f [12/53] ethtool: provide string sets with GET_STRSET request New smatch warnings: net/ethtool/strset.c:187 parse_strset() error: we previously assumed 'info' could be null (see line 157) net/ethtool/strset.c:279 prepare_strset() error: we previously assumed 'dev' could be null (see line 257) # https://github.com/lunn/linux/commit/b1e164cd0b8cfd588738d646298e44264c72e16f git remote add lunn https://github.com/lunn/linux.git git remote update lunn git checkout b1e164cd0b8cfd588738d646298e44264c72e16f vim +/PTR_ERR +168 net/ethtool/strset.c b1e164cd Michal Kubecek 2018-07-23 146 b1e164cd Michal Kubecek 2018-07-23 147 /* parse_request() handler */ b1e164cd Michal Kubecek 2018-07-23 148 static int parse_strset(struct common_req_info *req_info, struct sk_buff *skb, b1e164cd Michal Kubecek 2018-07-23 149 struct genl_info *info, const struct nlmsghdr *nlhdr) b1e164cd Michal Kubecek 2018-07-23 150 { b1e164cd Michal Kubecek 2018-07-23 151 struct strset_data *data = b1e164cd Michal Kubecek 2018-07-23 152 container_of(req_info, struct strset_data, reqinfo_base); b1e164cd Michal Kubecek 2018-07-23 153 struct nlattr *attr; b1e164cd Michal Kubecek 2018-07-23 154 int rem, ret; b1e164cd Michal Kubecek 2018-07-23 155 b1e164cd Michal Kubecek 2018-07-23 156 ret = nlmsg_validate(nlhdr, GENL_HDRLEN, ETHA_STRSET_MAX, b1e164cd Michal Kubecek 2018-07-23 @157 get_strset_policy, info ? info->extack : NULL); b1e164cd Michal Kubecek 2018-07-23 158 if (ret < 0) b1e164cd Michal Kubecek 2018-07-23 159 return ret; b1e164cd Michal Kubecek 2018-07-23 160 b1e164cd Michal Kubecek 2018-07-23 161 nlmsg_for_each_attr(attr, nlhdr, GENL_HDRLEN, rem) { b1e164cd Michal Kubecek 2018-07-23 162 u32 id; b1e164cd Michal Kubecek 2018-07-23 163 b1e164cd Michal Kubecek 2018-07-23 164 switch (nla_type(attr)) { b1e164cd Michal Kubecek 2018-07-23 165 case ETHA_STRSET_DEV: b1e164cd Michal Kubecek 2018-07-23 166 req_info->dev = ethnl_dev_get(info, attr); b1e164cd Michal Kubecek 2018-07-23 167 if (IS_ERR(req_info->dev)) { b1e164cd Michal Kubecek 2018-07-23 168 ret = PTR_ERR(req_info->dev); b1e164cd Michal Kubecek 2018-07-23 169 req_info->dev = NULL; b1e164cd Michal Kubecek 2018-07-23 170 return ret; b1e164cd Michal Kubecek 2018-07-23 171 } b1e164cd Michal Kubecek 2018-07-23 172 break; b1e164cd Michal Kubecek 2018-07-23 173 case ETHA_STRSET_COUNTS: b1e164cd Michal Kubecek 2018-07-23 174 data->counts_only = true; b1e164cd Michal Kubecek 2018-07-23 175 break; b1e164cd Michal Kubecek 2018-07-23 176 case ETHA_STRSET_STRINGSET: b1e164cd Michal Kubecek 2018-07-23 177 ret = get_strset_id(attr, , info); b1e164cd Michal Kubecek 2018-07-23 178 if (ret < 0) b1e164cd Michal Kubecek 2018-07-23 179 return ret; b1e164cd Michal Kubecek 2018-07-23 180 if (ret >= ETH_SS_COUNT) b1e164cd Michal Kubecek 2018-07-23 181 return -EOPNOTSUPP; b1e164cd Michal Kubecek 2018-07-23 182 data->req_ids |= (1U << id); b1e164cd Michal Kubecek 2018-07-23 183 break; b1e164cd Michal Kubecek 2018-07-23 184 default: b1e164cd Michal Kubecek 2018-07-23 185 ETHNL_SET_ERRMSG(info, b1e164cd Michal Kubecek 2018-07-23 186 "unexpected attribute in ETHNL_CMD_GET_STRSET message"); b1e164cd Michal Kubecek 2018-07-23 @187 return genl_err_attr(info, -EINVAL, attr); Presumably dereferenced inside the function call. b1e164cd Michal Kubecek 2018-07-23 188 } b1e164cd Michal Kubecek 2018-07-23 189 } b1e164cd Michal Kubecek 2018-07-23 190 b1e164cd Michal Kubecek 2018-07-23 191 return 0; b1e164cd Michal Kubecek 2018-07-23 192 } b1e164cd Michal Kubecek 2018-07-23 193 b1e164cd Michal Kubecek 2018-07-23 194 static void free_strset(struct strset_data *data) b1e164cd Michal Kubecek 2018-07-23 195 { b1e164cd Michal Kubecek 2018-07-23 196 unsigned int i; b1e164cd Michal Kubecek 2018-07-23 197 b1e164cd Michal Kubecek
[kbuild] [ath6kl:ath11k-bringup 89/93] drivers/net/wireless/ath/ath11k/core.c:621 ath11k_qmi_firmware_indication() warn: inconsistent returns 'mutex:>core_lock'.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git ath11k-bringup head: 9bcbbf4cedb7a1f30cb547cf87dc480d7f8a5e87 commit: 426598fdbef82ace7b4a728445f61ecf034f233c [89/93] ath11k: add qmi API support and rproc_boot for Q6 New smatch warnings: drivers/net/wireless/ath/ath11k/core.c:621 ath11k_qmi_firmware_indication() warn: inconsistent returns 'mutex:>core_lock'. Locked on: line 621 Unlocked on: line 591 Locked on: line 714 Unlocked on: line 747 # https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git/commit/?id=426598fdbef82ace7b4a728445f61ecf034f233c git remote add ath6kl https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/ath.git git remote update ath6kl git checkout 426598fdbef82ace7b4a728445f61ecf034f233c vim +621 drivers/net/wireless/ath/ath11k/core.c 426598fd Anilkumar Kolli 2019-04-04 584 int ath11k_qmi_firmware_indication(struct ath11k_base *ab) 426598fd Anilkumar Kolli 2019-04-04 585 { 426598fd Anilkumar Kolli 2019-04-04 586int ret; 426598fd Anilkumar Kolli 2019-04-04 587 426598fd Anilkumar Kolli 2019-04-04 588ret = ath11k_ce_init_pipes(ab); 426598fd Anilkumar Kolli 2019-04-04 589if (ret) { 426598fd Anilkumar Kolli 2019-04-04 590ath11k_err(ab, "failed to initialize CE: %d\n", ret); 426598fd Anilkumar Kolli 2019-04-04 591return ret; 426598fd Anilkumar Kolli 2019-04-04 592} 426598fd Anilkumar Kolli 2019-04-04 593 426598fd Anilkumar Kolli 2019-04-04 594ret = ath11k_dp_alloc(ab); 426598fd Anilkumar Kolli 2019-04-04 595if (ret) { 426598fd Anilkumar Kolli 2019-04-04 596ath11k_err(ab, "failed to init DP: %d\n", ret); 426598fd Anilkumar Kolli 2019-04-04 597return ret; 426598fd Anilkumar Kolli 2019-04-04 598} 426598fd Anilkumar Kolli 2019-04-04 599 426598fd Anilkumar Kolli 2019-04-04 600mutex_lock(>core_lock); ^^ The static checker doesn't complain but is this a double lock actually? It looks like we took the lock eaerlier in ath11k_core_restart(). This is restart code so it's probably hard to test. 426598fd Anilkumar Kolli 2019-04-04 601ret = ath11k_core_start(ab, ATH11K_FIRMWARE_MODE_NORMAL); 426598fd Anilkumar Kolli 2019-04-04 602if (ret) { 426598fd Anilkumar Kolli 2019-04-04 603ath11k_err(ab, "failed to start core: %d\n", ret); 426598fd Anilkumar Kolli 2019-04-04 604goto err_dp_free; 426598fd Anilkumar Kolli 2019-04-04 605} 426598fd Anilkumar Kolli 2019-04-04 606 426598fd Anilkumar Kolli 2019-04-04 607ret = ath11k_core_pdev_create(ab); 426598fd Anilkumar Kolli 2019-04-04 608if (ret) { 426598fd Anilkumar Kolli 2019-04-04 609ath11k_err(ab, "failed to create pdev core: %d\n", ret); 426598fd Anilkumar Kolli 2019-04-04 610goto err_core_stop; 426598fd Anilkumar Kolli 2019-04-04 611} 426598fd Anilkumar Kolli 2019-04-04 612ath11k_ahb_ext_irq_enable(ab); 426598fd Anilkumar Kolli 2019-04-04 613mutex_unlock(>core_lock); 426598fd Anilkumar Kolli 2019-04-04 614 426598fd Anilkumar Kolli 2019-04-04 615return 0; 426598fd Anilkumar Kolli 2019-04-04 616 426598fd Anilkumar Kolli 2019-04-04 617 err_core_stop: 426598fd Anilkumar Kolli 2019-04-04 618ath11k_core_stop(ab); 426598fd Anilkumar Kolli 2019-04-04 619 err_dp_free: 426598fd Anilkumar Kolli 2019-04-04 620ath11k_dp_free(ab); 426598fd Anilkumar Kolli 2019-04-04 @621return ret; 426598fd Anilkumar Kolli 2019-04-04 622 } --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation ___ kbuild mailing list kbuild@lists.01.org https://lists.01.org/mailman/listinfo/kbuild
[kbuild] [nf-next:nft-bridge8 8/8] net/netfilter/nf_conntrack_proto.c:557 nf_ct_netns_do_put() error: we previously assumed 'nf_ct_bridge_info' could be null (see line 552)
tree: https://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next.git nft-bridge8 head: ae378c12525a3fa600ba9c615a3b9f49ed1b2101 commit: ae378c12525a3fa600ba9c615a3b9f49ed1b2101 [8/8] netfilter: bridge: add basic conntrack support smatch warnings: net/netfilter/nf_conntrack_proto.c:557 nf_ct_netns_do_put() error: we previously assumed 'nf_ct_bridge_info' could be null (see line 552) # https://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next.git/commit/?id=ae378c12525a3fa600ba9c615a3b9f49ed1b2101 git remote add nf-next https://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next.git git remote update nf-next git checkout ae378c12525a3fa600ba9c615a3b9f49ed1b2101 vim +/nf_ct_bridge_info +557 net/netfilter/nf_conntrack_proto.c 2c41f33c Florian Westphal 2017-05-30 532 a0ae2562 Florian Westphal 2018-06-29 533 static void nf_ct_netns_do_put(struct net *net, u8 nfproto) a0ae2562 Florian Westphal 2018-06-29 534 { a0ae2562 Florian Westphal 2018-06-29 535 struct nf_conntrack_net *cnet = net_generic(net, nf_conntrack_net_id); a0ae2562 Florian Westphal 2018-06-29 536 a0ae2562 Florian Westphal 2018-06-29 537 mutex_lock(_ct_proto_mutex); a0ae2562 Florian Westphal 2018-06-29 538 switch (nfproto) { a0ae2562 Florian Westphal 2018-06-29 539 case NFPROTO_IPV4: a0ae2562 Florian Westphal 2018-06-29 540 if (cnet->users4 && (--cnet->users4 == 0)) a0ae2562 Florian Westphal 2018-06-29 541 nf_unregister_net_hooks(net, ipv4_conntrack_ops, a0ae2562 Florian Westphal 2018-06-29 542 ARRAY_SIZE(ipv4_conntrack_ops)); a0ae2562 Florian Westphal 2018-06-29 543 break; a0ae2562 Florian Westphal 2018-06-29 544 #if IS_ENABLED(CONFIG_IPV6) a0ae2562 Florian Westphal 2018-06-29 545 case NFPROTO_IPV6: a0ae2562 Florian Westphal 2018-06-29 546 if (cnet->users6 && (--cnet->users6 == 0)) a0ae2562 Florian Westphal 2018-06-29 547 nf_unregister_net_hooks(net, ipv6_conntrack_ops, a0ae2562 Florian Westphal 2018-06-29 548 ARRAY_SIZE(ipv6_conntrack_ops)); a0ae2562 Florian Westphal 2018-06-29 549 break; a0ae2562 Florian Westphal 2018-06-29 550 #endif ae378c12 Pablo Neira Ayuso 2019-03-29 551 case NFPROTO_BRIDGE: ae378c12 Pablo Neira Ayuso 2019-03-29 @552 if (nf_ct_bridge_info && ^ ae378c12 Pablo Neira Ayuso 2019-03-29 553 cnet->users_bridge && (--cnet->users_bridge == 0)) ae378c12 Pablo Neira Ayuso 2019-03-29 554 nf_unregister_net_hooks(net, nf_ct_bridge_info->ops, ae378c12 Pablo Neira Ayuso 2019-03-29 555 nf_ct_bridge_info->ops_size); ae378c12 Pablo Neira Ayuso 2019-03-29 556 ae378c12 Pablo Neira Ayuso 2019-03-29 @557 module_put(nf_ct_bridge_info->me); ^ ae378c12 Pablo Neira Ayuso 2019-03-29 558 break; 0e54d217 Davide Caratti2016-11-07 559 } 0e54d217 Davide Caratti2016-11-07 560 a0ae2562 Florian Westphal 2018-06-29 561 mutex_unlock(_ct_proto_mutex); a0ae2562 Florian Westphal 2018-06-29 562 } a0ae2562 Florian Westphal 2018-06-29 563 --- 0-DAY kernel test infrastructureOpen Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation ___ kbuild mailing list kbuild@lists.01.org https://lists.01.org/mailman/listinfo/kbuild