From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Dan Carpenter <error27@gmail.com>
Subject: Re: [PATCH wireless-next v3 3/6] wifi: brcmfmac: create and remove the AWDL interface
Date: Sun, 29 Nov 2026 00:08:00 +0100 [thread overview]
Message-ID: <20261129000248.BRevkZNG-lkp@intel.com> (raw)
Unfiltered warning: this smatch report is sent as-is and has not been
reviewed for false positives, so please treat it with due skepticism.
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
In-Reply-To: <20261127124104.233236-4-dev@deq.rocks>
References: <20261127124104.233236-4-dev@deq.rocks>
TO: Andre Eikmeyer <dev@deq.rocks>
TO: arend.vanspriel@broadcom.com
CC: linux-wireless@vger.kernel.org
CC: brcm80211@lists.linux.dev
CC: brcm80211-dev-list.pdl@broadcom.com
CC: linux-kernel@vger.kernel.org
CC: Sasha Finkelstein <k@chaosmail.tech>
CC: Sven Peter <sven@kernel.org>
CC: Janne Grunau <j@jannau.net>
CC: Aditya Garg <aditya.garg@linux.dev>
CC: Andre Eikmeyer <dev@deq.rocks>
CC: Yossef Osman <Yossef.Osman@proton.me>
Hi Andre,
kernel test robot noticed the following build warnings:
[auto build test WARNING on 18d0bedbb5f0538396cb7f763ed9cd1dd69c5b23]
url: https://github.com/intel-lab-lkp/linux/commits/Andre-Eikmeyer/wifi-brcmfmac-move-the-interface_create-definitions-to-fwil_types-h/20261127-134059
base: 18d0bedbb5f0538396cb7f763ed9cd1dd69c5b23
patch link: https://lore.kernel.org/r/20261127124104.233236-4-dev%40deq.rocks
patch subject: [PATCH wireless-next v3 3/6] wifi: brcmfmac: create and remove the AWDL interface
:::::: branch date: 34 hours ago
:::::: commit date: 34 hours ago
config: xtensa-randconfig-2200-20261128 (https://download.01.org/0day-ci/archive/20261129/20261129000248.BRevkZNG-lkp@intel.com/config)
compiler: xtensa-linux-gcc (GCC) 8.5.0
smatch: v0.5.0-9187-g5189e3fb
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Closes: https://lore.kernel.org/r/20261129000248.BRevkZNG-lkp@intel.com/
New smatch warnings:
drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c:1064 brcmf_inetaddr_changed() error: we previously assumed 'ifp' could be null (see line 1055)
Old smatch warnings:
arch/xtensa/include/asm/thread_info.h:97 current_thread_info() warn: inconsistent indenting
vim +/ifp +1064 drivers/net/wireless/broadcom/brcm80211/brcmfmac/core.c
f1ac3aa212af6dd Rafał Miłecki 2017-02-24 1037
44129ed04b2b01c Franky Lin 2016-01-02 1038 #ifdef CONFIG_INET
44129ed04b2b01c Franky Lin 2016-01-02 1039 #define ARPOL_MAX_ENTRIES 8
44129ed04b2b01c Franky Lin 2016-01-02 1040 static int brcmf_inetaddr_changed(struct notifier_block *nb,
44129ed04b2b01c Franky Lin 2016-01-02 1041 unsigned long action, void *data)
44129ed04b2b01c Franky Lin 2016-01-02 1042 {
44129ed04b2b01c Franky Lin 2016-01-02 1043 struct brcmf_pub *drvr = container_of(nb, struct brcmf_pub,
44129ed04b2b01c Franky Lin 2016-01-02 1044 inetaddr_notifier);
44129ed04b2b01c Franky Lin 2016-01-02 1045 struct in_ifaddr *ifa = data;
44129ed04b2b01c Franky Lin 2016-01-02 1046 struct net_device *ndev = ifa->ifa_dev->dev;
44129ed04b2b01c Franky Lin 2016-01-02 1047 struct brcmf_if *ifp;
44129ed04b2b01c Franky Lin 2016-01-02 1048 int idx, i, ret;
44129ed04b2b01c Franky Lin 2016-01-02 1049 u32 val;
44129ed04b2b01c Franky Lin 2016-01-02 1050 __be32 addr_table[ARPOL_MAX_ENTRIES] = {0};
44129ed04b2b01c Franky Lin 2016-01-02 1051
44129ed04b2b01c Franky Lin 2016-01-02 1052 /* Find out if the notification is meant for us */
44129ed04b2b01c Franky Lin 2016-01-02 1053 for (idx = 0; idx < BRCMF_MAX_IFS; idx++) {
44129ed04b2b01c Franky Lin 2016-01-02 1054 ifp = drvr->iflist[idx];
44129ed04b2b01c Franky Lin 2016-01-02 @1055 if (ifp && ifp->ndev == ndev)
44129ed04b2b01c Franky Lin 2016-01-02 1056 break;
44129ed04b2b01c Franky Lin 2016-01-02 1057 if (idx == BRCMF_MAX_IFS - 1)
44129ed04b2b01c Franky Lin 2016-01-02 1058 return NOTIFY_DONE;
44129ed04b2b01c Franky Lin 2016-01-02 1059 }
44129ed04b2b01c Franky Lin 2016-01-02 1060
8b2b9df358a00c4 Andre Eikmeyer 2026-11-27 1061 /* ARP offload would put the address into the table of the primary
8b2b9df358a00c4 Andre Eikmeyer 2026-11-27 1062 * interface, the AWDL interface has none of its own
8b2b9df358a00c4 Andre Eikmeyer 2026-11-27 1063 */
8b2b9df358a00c4 Andre Eikmeyer 2026-11-27 @1064 if (ifp->awdl)
8b2b9df358a00c4 Andre Eikmeyer 2026-11-27 1065 return NOTIFY_DONE;
8b2b9df358a00c4 Andre Eikmeyer 2026-11-27 1066
44129ed04b2b01c Franky Lin 2016-01-02 1067 /* check if arp offload is supported */
44129ed04b2b01c Franky Lin 2016-01-02 1068 ret = brcmf_fil_iovar_int_get(ifp, "arpoe", &val);
44129ed04b2b01c Franky Lin 2016-01-02 1069 if (ret)
44129ed04b2b01c Franky Lin 2016-01-02 1070 return NOTIFY_OK;
44129ed04b2b01c Franky Lin 2016-01-02 1071
44129ed04b2b01c Franky Lin 2016-01-02 1072 /* old version only support primary index */
44129ed04b2b01c Franky Lin 2016-01-02 1073 ret = brcmf_fil_iovar_int_get(ifp, "arp_version", &val);
44129ed04b2b01c Franky Lin 2016-01-02 1074 if (ret)
44129ed04b2b01c Franky Lin 2016-01-02 1075 val = 1;
44129ed04b2b01c Franky Lin 2016-01-02 1076 if (val == 1)
44129ed04b2b01c Franky Lin 2016-01-02 1077 ifp = drvr->iflist[0];
44129ed04b2b01c Franky Lin 2016-01-02 1078
44129ed04b2b01c Franky Lin 2016-01-02 1079 /* retrieve the table from firmware */
44129ed04b2b01c Franky Lin 2016-01-02 1080 ret = brcmf_fil_iovar_data_get(ifp, "arp_hostip", addr_table,
44129ed04b2b01c Franky Lin 2016-01-02 1081 sizeof(addr_table));
44129ed04b2b01c Franky Lin 2016-01-02 1082 if (ret) {
dcb1471bc6d0541 Rafał Miłecki 2019-02-19 1083 bphy_err(drvr, "fail to get arp ip table err:%d\n", ret);
44129ed04b2b01c Franky Lin 2016-01-02 1084 return NOTIFY_OK;
44129ed04b2b01c Franky Lin 2016-01-02 1085 }
44129ed04b2b01c Franky Lin 2016-01-02 1086
44129ed04b2b01c Franky Lin 2016-01-02 1087 for (i = 0; i < ARPOL_MAX_ENTRIES; i++)
44129ed04b2b01c Franky Lin 2016-01-02 1088 if (ifa->ifa_address == addr_table[i])
44129ed04b2b01c Franky Lin 2016-01-02 1089 break;
44129ed04b2b01c Franky Lin 2016-01-02 1090
44129ed04b2b01c Franky Lin 2016-01-02 1091 switch (action) {
44129ed04b2b01c Franky Lin 2016-01-02 1092 case NETDEV_UP:
44129ed04b2b01c Franky Lin 2016-01-02 1093 if (i == ARPOL_MAX_ENTRIES) {
44129ed04b2b01c Franky Lin 2016-01-02 1094 brcmf_dbg(TRACE, "add %pI4 to arp table\n",
44129ed04b2b01c Franky Lin 2016-01-02 1095 &ifa->ifa_address);
44129ed04b2b01c Franky Lin 2016-01-02 1096 /* set it directly */
44129ed04b2b01c Franky Lin 2016-01-02 1097 ret = brcmf_fil_iovar_data_set(ifp, "arp_hostip",
44129ed04b2b01c Franky Lin 2016-01-02 1098 &ifa->ifa_address, sizeof(ifa->ifa_address));
44129ed04b2b01c Franky Lin 2016-01-02 1099 if (ret)
dcb1471bc6d0541 Rafał Miłecki 2019-02-19 1100 bphy_err(drvr, "add arp ip err %d\n", ret);
44129ed04b2b01c Franky Lin 2016-01-02 1101 }
44129ed04b2b01c Franky Lin 2016-01-02 1102 break;
44129ed04b2b01c Franky Lin 2016-01-02 1103 case NETDEV_DOWN:
44129ed04b2b01c Franky Lin 2016-01-02 1104 if (i < ARPOL_MAX_ENTRIES) {
44129ed04b2b01c Franky Lin 2016-01-02 1105 addr_table[i] = 0;
44129ed04b2b01c Franky Lin 2016-01-02 1106 brcmf_dbg(TRACE, "remove %pI4 from arp table\n",
44129ed04b2b01c Franky Lin 2016-01-02 1107 &ifa->ifa_address);
44129ed04b2b01c Franky Lin 2016-01-02 1108 /* clear the table in firmware */
44129ed04b2b01c Franky Lin 2016-01-02 1109 ret = brcmf_fil_iovar_data_set(ifp, "arp_hostip_clear",
44129ed04b2b01c Franky Lin 2016-01-02 1110 NULL, 0);
44129ed04b2b01c Franky Lin 2016-01-02 1111 if (ret) {
dcb1471bc6d0541 Rafał Miłecki 2019-02-19 1112 bphy_err(drvr, "fail to clear arp ip table err:%d\n",
44129ed04b2b01c Franky Lin 2016-01-02 1113 ret);
44129ed04b2b01c Franky Lin 2016-01-02 1114 return NOTIFY_OK;
44129ed04b2b01c Franky Lin 2016-01-02 1115 }
44129ed04b2b01c Franky Lin 2016-01-02 1116 for (i = 0; i < ARPOL_MAX_ENTRIES; i++) {
cd2bc19c61b2da8 Franky Lin 2016-02-17 1117 if (addr_table[i] == 0)
cd2bc19c61b2da8 Franky Lin 2016-02-17 1118 continue;
cd2bc19c61b2da8 Franky Lin 2016-02-17 1119 ret = brcmf_fil_iovar_data_set(ifp, "arp_hostip",
cd2bc19c61b2da8 Franky Lin 2016-02-17 1120 &addr_table[i],
44129ed04b2b01c Franky Lin 2016-01-02 1121 sizeof(addr_table[i]));
44129ed04b2b01c Franky Lin 2016-01-02 1122 if (ret)
dcb1471bc6d0541 Rafał Miłecki 2019-02-19 1123 bphy_err(drvr, "add arp ip err %d\n",
44129ed04b2b01c Franky Lin 2016-01-02 1124 ret);
44129ed04b2b01c Franky Lin 2016-01-02 1125 }
44129ed04b2b01c Franky Lin 2016-01-02 1126 }
44129ed04b2b01c Franky Lin 2016-01-02 1127 break;
44129ed04b2b01c Franky Lin 2016-01-02 1128 default:
44129ed04b2b01c Franky Lin 2016-01-02 1129 break;
44129ed04b2b01c Franky Lin 2016-01-02 1130 }
44129ed04b2b01c Franky Lin 2016-01-02 1131
44129ed04b2b01c Franky Lin 2016-01-02 1132 return NOTIFY_OK;
44129ed04b2b01c Franky Lin 2016-01-02 1133 }
44129ed04b2b01c Franky Lin 2016-01-02 1134 #endif
44129ed04b2b01c Franky Lin 2016-01-02 1135
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next reply other threads:[~2026-11-28 23:08 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-28 23:08 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2026-11-27 12:40 [PATCH wireless-next v3 0/6] wifi: brcmfmac: AWDL for AirDrop on Apple T2 Macs Andre Eikmeyer
2026-11-27 12:41 ` [PATCH wireless-next v3 3/6] wifi: brcmfmac: create and remove the AWDL interface Andre Eikmeyer
2026-11-29 15:38 ` Arend van Spriel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261129000248.BRevkZNG-lkp@intel.com \
--to=lkp@intel.com \
--cc=error27@gmail.com \
--cc=oe-kbuild@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.