Re: [PATCH 18/18] rtw89: add Kconfig and Makefile
by kernel test robot
Hi Ping-Ke,
I love your patch! Perhaps something to improve:
[auto build test WARNING on wireless-drivers-next/master]
[also build test WARNING on wireless-drivers/master v5.11-rc1 next-20201223]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Ping-Ke-Shih/rtw89-add-Realtek-8...
base: https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-ne... master
config: i386-allyesconfig (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce (this is a W=1 build):
# https://github.com/0day-ci/linux/commit/b4945b490f8d3df1d3e1aa0c9e1665417...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Ping-Ke-Shih/rtw89-add-Realtek-802-11ax-driver/20201230-124948
git checkout b4945b490f8d3df1d3e1aa0c9e16654172195a08
# save the attached .config to linux build tree
make W=1 ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
drivers/net/wireless/realtek/rtw89/phy.c: In function 'rtw89_phy_average_cfo_calc':
>> drivers/net/wireless/realtek/rtw89/phy.c:1367:24: warning: variable 'cfo_min_macid' set but not used [-Wunused-but-set-variable]
1367 | u8 cfo_max_macid = 0, cfo_min_macid = 0, i;
| ^~~~~~~~~~~~~
>> drivers/net/wireless/realtek/rtw89/phy.c:1367:5: warning: variable 'cfo_max_macid' set but not used [-Wunused-but-set-variable]
1367 | u8 cfo_max_macid = 0, cfo_min_macid = 0, i;
| ^~~~~~~~~~~~~
>> drivers/net/wireless/realtek/rtw89/phy.c:1366:24: warning: variable 'cnt_min_macid' set but not used [-Wunused-but-set-variable]
1366 | u8 cnt_max_macid = 0, cnt_min_macid = 0;
| ^~~~~~~~~~~~~
--
drivers/net/wireless/realtek/rtw89/rtw8852a_rfk.c: In function '_lok_finetune_check':
>> drivers/net/wireless/realtek/rtw89/rtw8852a_rfk.c:1191:6: warning: variable 'fine_q' set but not used [-Wunused-but-set-variable]
1191 | u32 fine_q = 0x0;
| ^~~~~~
>> drivers/net/wireless/realtek/rtw89/rtw8852a_rfk.c:1190:6: warning: variable 'fine_i' set but not used [-Wunused-but-set-variable]
1190 | u32 fine_i = 0x0;
| ^~~~~~
drivers/net/wireless/realtek/rtw89/rtw8852a_rfk.c: In function '_iqk_get_ch_info':
>> drivers/net/wireless/realtek/rtw89/rtw8852a_rfk.c:1384:6: warning: variable 'reg_rf18' set but not used [-Wunused-but-set-variable]
1384 | u32 reg_rf18 = 0x0;
| ^~~~~~~~
--
drivers/net/wireless/realtek/rtw89/pci.c: In function 'rtw89_pci_release_rpp':
>> drivers/net/wireless/realtek/rtw89/pci.c:407:7: warning: variable 'polluted' set but not used [-Wunused-but-set-variable]
407 | bool polluted;
| ^~~~~~~~
>> drivers/net/wireless/realtek/rtw89/pci.c:406:5: warning: variable 'mac_id' set but not used [-Wunused-but-set-variable]
406 | u8 mac_id, qsel, tx_status, txch;
| ^~~~~~
drivers/net/wireless/realtek/rtw89/pci.c: In function 'rtw89_pci_reset_trx_rings':
>> drivers/net/wireless/realtek/rtw89/pci.c:1009:6: warning: variable 'addr_desa_h' set but not used [-Wunused-but-set-variable]
1009 | u32 addr_desa_h;
| ^~~~~~~~~~~
drivers/net/wireless/realtek/rtw89/pci.c: In function 'rtw89_pci_remove':
>> drivers/net/wireless/realtek/rtw89/pci.c:2549:20: warning: variable 'rtwpci' set but not used [-Wunused-but-set-variable]
2549 | struct rtw89_pci *rtwpci;
| ^~~~~~
vim +/cfo_min_macid +1367 drivers/net/wireless/realtek/rtw89/phy.c
eb46958227be930 Ping-Ke Shih 2020-12-30 1358
eb46958227be930 Ping-Ke Shih 2020-12-30 1359 static void rtw89_phy_average_cfo_calc(struct rtw89_dev *rtwdev)
eb46958227be930 Ping-Ke Shih 2020-12-30 1360 {
eb46958227be930 Ping-Ke Shih 2020-12-30 1361 struct rtw89_cfo_tracking_info *cfo = &rtwdev->cfo_tracking;
eb46958227be930 Ping-Ke Shih 2020-12-30 1362 s32 cfo_khz_avg[CFO_TRACK_MAX_USER] = {0};
eb46958227be930 Ping-Ke Shih 2020-12-30 1363 s32 cfo_max = 0, cfo_min = U16_MAX, cfo_khz_all = 0;
eb46958227be930 Ping-Ke Shih 2020-12-30 1364 s32 cnt_max = 0, cnt_min = U16_MAX, cfo_cnt_all = 0;
eb46958227be930 Ping-Ke Shih 2020-12-30 1365 s16 val;
eb46958227be930 Ping-Ke Shih 2020-12-30 @1366 u8 cnt_max_macid = 0, cnt_min_macid = 0;
eb46958227be930 Ping-Ke Shih 2020-12-30 @1367 u8 cfo_max_macid = 0, cfo_min_macid = 0, i;
eb46958227be930 Ping-Ke Shih 2020-12-30 1368
eb46958227be930 Ping-Ke Shih 2020-12-30 1369 rtw89_debug(rtwdev, RTW89_DBG_CFO, "one_entry_only=%d\n",
eb46958227be930 Ping-Ke Shih 2020-12-30 1370 rtwdev->total_sta_assoc == 1);
eb46958227be930 Ping-Ke Shih 2020-12-30 1371
eb46958227be930 Ping-Ke Shih 2020-12-30 1372 if (rtwdev->total_sta_assoc == 1) {
eb46958227be930 Ping-Ke Shih 2020-12-30 1373 for (i = 0; i < CFO_TRACK_MAX_USER; i++) {
eb46958227be930 Ping-Ke Shih 2020-12-30 1374 if (cfo->cfo_cnt[i] == 0)
eb46958227be930 Ping-Ke Shih 2020-12-30 1375 continue;
eb46958227be930 Ping-Ke Shih 2020-12-30 1376 cfo_khz_all += cfo->cfo_tail[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1377 cfo_cnt_all += cfo->cfo_cnt[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1378 if (cfo_cnt_all == 0)
eb46958227be930 Ping-Ke Shih 2020-12-30 1379 cfo->cfo_avg_pre = 0;
eb46958227be930 Ping-Ke Shih 2020-12-30 1380 else
eb46958227be930 Ping-Ke Shih 2020-12-30 1381 cfo->cfo_avg_pre = cfo_khz_all / cfo_cnt_all;
eb46958227be930 Ping-Ke Shih 2020-12-30 1382 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1383 rtw89_debug(rtwdev, RTW89_DBG_CFO,
eb46958227be930 Ping-Ke Shih 2020-12-30 1384 "CFO track for one entry only\n");
eb46958227be930 Ping-Ke Shih 2020-12-30 1385 rtw89_debug(rtwdev, RTW89_DBG_CFO,
eb46958227be930 Ping-Ke Shih 2020-12-30 1386 "Total cfo=(%dK), pkt_cnt=(%d), avg_cfo=(%dK)\n",
eb46958227be930 Ping-Ke Shih 2020-12-30 1387 cfo_khz_all >> 2, cfo_cnt_all,
eb46958227be930 Ping-Ke Shih 2020-12-30 1388 cfo->cfo_avg_pre >> 2);
eb46958227be930 Ping-Ke Shih 2020-12-30 1389 return;
eb46958227be930 Ping-Ke Shih 2020-12-30 1390 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1391
eb46958227be930 Ping-Ke Shih 2020-12-30 1392 for (i = 0; i < CFO_TRACK_MAX_USER; i++) {
eb46958227be930 Ping-Ke Shih 2020-12-30 1393 if (cfo->cfo_cnt[i] == 0)
eb46958227be930 Ping-Ke Shih 2020-12-30 1394 continue;
eb46958227be930 Ping-Ke Shih 2020-12-30 1395
eb46958227be930 Ping-Ke Shih 2020-12-30 1396 cfo_khz_all += cfo->cfo_tail[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1397 cfo_cnt_all += cfo->cfo_cnt[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1398 if (cfo->cfo_cnt[i] == 0)
eb46958227be930 Ping-Ke Shih 2020-12-30 1399 cfo_khz_avg[i] = 0;
eb46958227be930 Ping-Ke Shih 2020-12-30 1400 else
eb46958227be930 Ping-Ke Shih 2020-12-30 1401 cfo_khz_avg[i] = cfo->cfo_tail[i] / cfo->cfo_cnt[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1402
eb46958227be930 Ping-Ke Shih 2020-12-30 1403 if (cfo->cfo_cnt[i] > cnt_max) {
eb46958227be930 Ping-Ke Shih 2020-12-30 1404 cnt_max = cfo->cfo_cnt[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1405 cnt_max_macid = i;
eb46958227be930 Ping-Ke Shih 2020-12-30 1406 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1407 if (cfo->cfo_cnt[i] < cnt_min) {
eb46958227be930 Ping-Ke Shih 2020-12-30 1408 cnt_min = cfo->cfo_cnt[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1409 cnt_min_macid = i;
eb46958227be930 Ping-Ke Shih 2020-12-30 1410 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1411 if (cfo_khz_avg[i] > cfo_max) {
eb46958227be930 Ping-Ke Shih 2020-12-30 1412 cfo_max = cfo_khz_avg[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1413 cfo_max_macid = i;
eb46958227be930 Ping-Ke Shih 2020-12-30 1414 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1415 if (cfo_khz_avg[i] < cfo_min) {
eb46958227be930 Ping-Ke Shih 2020-12-30 1416 cfo_min = cfo_khz_avg[i];
eb46958227be930 Ping-Ke Shih 2020-12-30 1417 cfo_min_macid = i;
eb46958227be930 Ping-Ke Shih 2020-12-30 1418 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1419 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1420
eb46958227be930 Ping-Ke Shih 2020-12-30 1421 /* Multi-sta CFO tracking strategy */
eb46958227be930 Ping-Ke Shih 2020-12-30 1422 val = (s16)abs(cfo_max - cfo_min);
eb46958227be930 Ping-Ke Shih 2020-12-30 1423 if (val < MAX_CFO_TOLERANCE || val > (MAX_CFO_TOLERANCE << 1)) {
eb46958227be930 Ping-Ke Shih 2020-12-30 1424 rtw89_debug(rtwdev, RTW89_DBG_CFO,
eb46958227be930 Ping-Ke Shih 2020-12-30 1425 "CFO track for only pri-user\n");
eb46958227be930 Ping-Ke Shih 2020-12-30 1426 rtw89_debug(rtwdev, RTW89_DBG_CFO,
eb46958227be930 Ping-Ke Shih 2020-12-30 1427 "Total cfo=(%dK), pkt_cnt=(%d), avg_cfo=(%dK)\n",
eb46958227be930 Ping-Ke Shih 2020-12-30 1428 cfo->cfo_tail[cnt_max_macid] >> 2,
eb46958227be930 Ping-Ke Shih 2020-12-30 1429 cfo->cfo_cnt[cnt_max_macid],
eb46958227be930 Ping-Ke Shih 2020-12-30 1430 cfo_khz_avg[cnt_max_macid] >> 2);
eb46958227be930 Ping-Ke Shih 2020-12-30 1431 cfo->cfo_avg_pre = cfo_khz_avg[cnt_max_macid];
eb46958227be930 Ping-Ke Shih 2020-12-30 1432 } else {
eb46958227be930 Ping-Ke Shih 2020-12-30 1433 rtw89_debug(rtwdev, RTW89_DBG_CFO,
eb46958227be930 Ping-Ke Shih 2020-12-30 1434 "CFO track for average of all user\n");
eb46958227be930 Ping-Ke Shih 2020-12-30 1435 rtw89_debug(rtwdev, RTW89_DBG_CFO,
eb46958227be930 Ping-Ke Shih 2020-12-30 1436 "Total cfo=(%dK), pkt_cnt=(%d), avg_cfo=(%dK)\n",
eb46958227be930 Ping-Ke Shih 2020-12-30 1437 cfo_khz_all >> 2, cfo_cnt_all,
eb46958227be930 Ping-Ke Shih 2020-12-30 1438 cfo->cfo_avg_pre >> 2);
eb46958227be930 Ping-Ke Shih 2020-12-30 1439 if (cfo_cnt_all == 0)
eb46958227be930 Ping-Ke Shih 2020-12-30 1440 cfo->cfo_avg_pre = 0;
eb46958227be930 Ping-Ke Shih 2020-12-30 1441 else
eb46958227be930 Ping-Ke Shih 2020-12-30 1442 cfo->cfo_avg_pre = cfo_khz_all / cfo_cnt_all;
eb46958227be930 Ping-Ke Shih 2020-12-30 1443 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1444 }
eb46958227be930 Ping-Ke Shih 2020-12-30 1445
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[PATCH] sparc32: fix badzero.cocci warnings
by kernel test robot
From: kernel test robot <lkp(a)intel.com>
arch/sparc/mm/srmmu.c:317:42-43: WARNING comparing pointer to 0
arch/sparc/mm/srmmu.c:317:42-43: WARNING comparing pointer to 0
Compare pointer-typed values to NULL rather than 0
Semantic patch information:
This makes an effort to choose between !x and x == NULL. !x is used
if it has previously been used with the function used to initialize x.
This relies on type information. More type information can be obtained
using the option -all_includes and the option -I to specify an
include path.
Generated by: scripts/coccinelle/null/badzero.cocci
CC: Sam Ravnborg <sam(a)ravnborg.org>
Reported-by: kernel test robot <lkp(a)intel.com>
Signed-off-by: kernel test robot <lkp(a)intel.com>
---
url: https://github.com/0day-ci/linux/commits/Sam-Ravnborg/sparc32-sunset-sun4...
base: https://git.kernel.org/pub/scm/linux/kernel/git/soc/soc.git for-next
srmmu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/arch/sparc/mm/srmmu.c
+++ b/arch/sparc/mm/srmmu.c
@@ -314,7 +314,7 @@ pgtable_t pte_alloc_one(struct mm_struct
pte_t *ptep;
struct page *page;
- if ((ptep = pte_alloc_one_kernel(mm)) == 0)
+ if ((ptep = pte_alloc_one_kernel(mm)) == NULL)
return NULL;
page = pfn_to_page(__nocache_pa((unsigned long)ptep) >> PAGE_SHIFT);
spin_lock(&mm->page_table_lock);
1 year, 6 months
ERROR: modpost: ".__warn_printk" undefined!
by kernel test robot
Hi Christoph,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 139711f033f636cc78b6aaf7363252241b9698ef
commit: a7b75c5a8c41445f33efb663887ff5f5c3b4454b net: pass a sockptr_t into ->setsockopt
date: 5 months ago
config: powerpc-randconfig-r034-20201225 (attached as .config)
compiler: powerpc64-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/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout a7b75c5a8c41445f33efb663887ff5f5c3b4454b
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>, old ones prefixed by <<):
ERROR: modpost: ".ktime_get_with_offset" [net/nfc/nfc.ko] undefined!
ERROR: modpost: ".sock_alloc_send_skb" [net/nfc/nfc.ko] undefined!
ERROR: modpost: ".skb_recv_datagram" [net/nfc/nfc.ko] undefined!
ERROR: modpost: ".skb_queue_head" [net/nfc/nfc.ko] undefined!
ERROR: modpost: "._copy_from_user" [net/nfc/nfc.ko] undefined!
ERROR: modpost: "._raw_read_lock" [net/nfc/nfc.ko] undefined!
ERROR: modpost: ".request_key_tag" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".strlen" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".key_put" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".user_read" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".up_read" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".revert_creds" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".kstrtoull" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".key_revoke" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".__kmalloc" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".down_read" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".key_invalidate" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".seq_puts" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".prepare_kernel_cred" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".strcasecmp" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".seq_printf" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".register_key_type" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".key_validate" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".memcpy" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".strncasecmp" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".__put_cred" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".memchr" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".__invalid_creds" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".unregister_key_type" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".kmemdup_nul" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".keyring_alloc" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".override_creds" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".creds_are_invalid" [net/dns_resolver/dns_resolver.ko] undefined!
ERROR: modpost: ".dev_remove_pack" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".unregister_netdevice_notifier" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".register_netdevice_notifier" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".strlcpy" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".dev_add_pack" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".caif_enroll_dev" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".snprintf" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".kmem_cache_alloc" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".__module_get" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".module_put" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".strcmp" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".cfpkt_extr_head" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".cfpkt_add_head" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".memset" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".kfree_skb" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".cfpkt_info" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".cfpkt_tonative" [net/caif/caif_usb.ko] undefined!
ERROR: modpost: ".sock_unregister" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".sock_register" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".skb_pull" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".skb_queue_head" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._copy_to_iter" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".mutex_unlock" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".skb_dequeue" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".mutex_lock" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".send_sig" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._copy_from_iter_full" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".skb_put" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".sock_alloc_send_skb" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".memcpy" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._copy_from_user" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".refcount_warn_saturate" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".sk_free" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._raw_write_unlock_bh" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._raw_write_lock_bh" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".__wake_up" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".debugfs_remove" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._raw_spin_unlock_bh" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._raw_spin_lock_bh" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".prepare_to_wait" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".cfpkt_set_prio" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".cfpkt_fromnative" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".finish_wait" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".schedule_timeout" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".prepare_to_wait_event" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".init_wait_entry" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".__might_sleep" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".__rcu_read_unlock" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".dev_get_by_index_rcu" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".__rcu_read_lock" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".caif_connect_client" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".caif_disconnect_client" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".release_sock" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".__mutex_init" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".sock_init_data" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".lock_sock_nested" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".sk_alloc" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".skb_free_datagram" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".skb_copy_datagram_iter" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".skb_recv_datagram" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._raw_spin_unlock_irqrestore" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: "._raw_spin_lock_irqsave" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".__sk_mem_schedule" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".sk_filter_trim_cap" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".net_ratelimit" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".kfree_skb" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".cfpkt_tonative" [net/caif/caif_socket.ko] undefined!
>> ERROR: modpost: ".__warn_printk" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".caif_free_client" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".sk_stream_kill_queues" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".caif_client_register_refcnt" [net/caif/caif_socket.ko] undefined!
ERROR: modpost: ".unregister_netdevice_queue" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".rtnl_link_unregister" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".rtnl_link_register" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".netif_rx_ni" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".netif_rx" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".skb_copy_bits" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".cfpkt_tonative" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".strncpy" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".finish_wait" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".schedule_timeout" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".prepare_to_wait_event" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".init_wait_entry" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".dev_set_mtu" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".__dev_get_by_index" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".caif_connect_client" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".__might_sleep" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".caif_disconnect_client" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".cfpkt_fromnative" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".kfree_skb" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".caif_free_client" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".__wake_up" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".caif_client_register_refcnt" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".netif_tx_wake_queue" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".queue_work_on" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".__local_bh_enable_ip" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: "._raw_spin_unlock" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: "._raw_spin_lock" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".rtnl_unlock" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".dev_close" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".rtnl_lock" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".arch_local_irq_restore" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".__init_waitqueue_head" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".register_netdevice" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".netdev_state_change" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".__warn_printk" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".rtnl_is_locked" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".nla_put" [net/caif/chnl_net.ko] undefined!
ERROR: modpost: ".register_netdevice_notifier" [net/caif/caif.ko] undefined!
ERROR: modpost: ".synchronize_rcu" [net/caif/caif.ko] undefined!
ERROR: modpost: ".snprintf" [net/caif/caif.ko] undefined!
ERROR: modpost: ".register_pernet_subsys" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__mutex_init" [net/caif/caif.ko] undefined!
ERROR: modpost: ".strlen" [net/caif/caif.ko] undefined!
ERROR: modpost: ".free_percpu" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__rcu_read_lock" [net/caif/caif.ko] undefined!
ERROR: modpost: ".unregister_netdevice_notifier" [net/caif/caif.ko] undefined!
ERROR: modpost: ".kfree_skb" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__alloc_percpu" [net/caif/caif.ko] undefined!
ERROR: modpost: ".memcmp" [net/caif/caif.ko] undefined!
ERROR: modpost: "._raw_spin_lock_bh" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__might_sleep" [net/caif/caif.ko] undefined!
ERROR: modpost: ".skb_trim" [net/caif/caif.ko] undefined!
ERROR: modpost: ".skb_push" [net/caif/caif.ko] undefined!
ERROR: modpost: ".mutex_lock" [net/caif/caif.ko] undefined!
ERROR: modpost: ".unregister_pernet_subsys" [net/caif/caif.ko] undefined!
ERROR: modpost: ".skb_put" [net/caif/caif.ko] undefined!
ERROR: modpost: ".arch_local_irq_restore" [net/caif/caif.ko] undefined!
ERROR: modpost: ".strlcpy" [net/caif/caif.ko] undefined!
ERROR: modpost: "._raw_spin_lock" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__alloc_skb" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__raw_spin_lock_init" [net/caif/caif.ko] undefined!
ERROR: modpost: ".dev_remove_pack" [net/caif/caif.ko] undefined!
ERROR: modpost: ".rtnl_lock" [net/caif/caif.ko] undefined!
ERROR: modpost: ".skb_pull" [net/caif/caif.ko] undefined!
ERROR: modpost: "._raw_spin_unlock" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__local_bh_enable_ip" [net/caif/caif.ko] undefined!
ERROR: modpost: ".memcpy" [net/caif/caif.ko] undefined!
ERROR: modpost: ".memset" [net/caif/caif.ko] undefined!
ERROR: modpost: ".kmem_cache_alloc" [net/caif/caif.ko] undefined!
ERROR: modpost: ".pskb_put" [net/caif/caif.ko] undefined!
ERROR: modpost: "._raw_spin_unlock_bh" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__rcu_read_unlock" [net/caif/caif.ko] undefined!
ERROR: modpost: ".skb_cow_data" [net/caif/caif.ko] undefined!
ERROR: modpost: ".__pskb_pull_tail" [net/caif/caif.ko] undefined!
ERROR: modpost: ".msleep" [net/caif/caif.ko] undefined!
ERROR: modpost: ".mutex_unlock" [net/caif/caif.ko] undefined!
ERROR: modpost: ".strcmp" [net/caif/caif.ko] undefined!
ERROR: modpost: ".___pskb_trim" [net/caif/caif.ko] undefined!
ERROR: modpost: ".dev_add_pack" [net/caif/caif.ko] undefined!
ERROR: modpost: ".rtnl_unlock" [net/caif/caif.ko] undefined!
ERROR: modpost: ".dst_discard_out" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".skb_queue_purge" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".skb_clone" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".neigh_table_clear" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".register_netdevice_notifier" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".__warn_printk" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".kmalloc_order" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".panic" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".dst_dev_put" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".__neigh_create" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".__nlmsg_put" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".net_ratelimit" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".__dev_get_by_index" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".consume_skb" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".rtnetlink_put_metrics" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".rtnl_register_module" [net/decnet/decnet.ko] undefined!
ERROR: modpost: ".mod_timer" [net/decnet/decnet.ko] undefined!
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
Re: [PATCH 1/8] mac80211: minstrel_ht: clean up CCK code
by kernel test robot
Hi Felix,
I love your patch! Perhaps something to improve:
[auto build test WARNING on mac80211-next/master]
[also build test WARNING on mac80211/master v5.11-rc1 next-20201223]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Felix-Fietkau/mac80211-minstrel_...
base: https://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next.git master
config: i386-randconfig-c001-20201229 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-15) 9.3.0
reproduce (this is a W=1 build):
# https://github.com/0day-ci/linux/commit/5899ab94b901a3c2e4fbeefae344f5464...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Felix-Fietkau/mac80211-minstrel_ht-clean-up-CCK-code/20201230-000429
git checkout 5899ab94b901a3c2e4fbeefae344f54649662b1c
# save the attached .config to linux build tree
make W=1 ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
net/mac80211/rc80211_minstrel_ht.c: In function 'minstrel_ht_get_tp_avg':
>> net/mac80211/rc80211_minstrel_ht.c:348:26: warning: variable 'overhead' set but not used [-Wunused-but-set-variable]
348 | unsigned int nsecs = 0, overhead = mi->overhead;
| ^~~~~~~~
vim +/overhead +348 net/mac80211/rc80211_minstrel_ht.c
339
340 /*
341 * Return current throughput based on the average A-MPDU length, taking into
342 * account the expected number of retransmissions and their expected length
343 */
344 int
345 minstrel_ht_get_tp_avg(struct minstrel_ht_sta *mi, int group, int rate,
346 int prob_avg)
347 {
> 348 unsigned int nsecs = 0, overhead = mi->overhead;
349 unsigned int ampdu_len = 1;
350
351 /* do not account throughput if sucess prob is below 10% */
352 if (prob_avg < MINSTREL_FRAC(10, 100))
353 return 0;
354
355 if (group == MINSTREL_CCK_GROUP)
356 overhead = mi->overhead_legacy;
357 else
358 ampdu_len = minstrel_ht_avg_ampdu_len(mi);
359
360 nsecs = 1000 * mi->overhead / ampdu_len;
361 nsecs += minstrel_mcs_groups[group].duration[rate] <<
362 minstrel_mcs_groups[group].shift;
363
364 /*
365 * For the throughput calculation, limit the probability value to 90% to
366 * account for collision related packet error rate fluctuation
367 * (prob is scaled - see MINSTREL_FRAC above)
368 */
369 if (prob_avg > MINSTREL_FRAC(90, 100))
370 return MINSTREL_TRUNC(100000 * ((MINSTREL_FRAC(90, 100) * 1000)
371 / nsecs));
372 else
373 return MINSTREL_TRUNC(100000 * ((prob_avg * 1000) / nsecs));
374 }
375
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[chrome-os:chromeos-5.10 144/1140] arch/arc/kernel/devtree.c:20:21: error: no previous prototype for 'arc_early_base_baud'
by kernel test robot
tree: https://chromium.googlesource.com/chromiumos/third_party/kernel chromeos-5.10
head: e29aeefa77c834e2a10a1c5a6733e44e77288916
commit: 91df3c40faddd7b33f5ae12ade27857c3d4fd974 [144/1140] CHROMIUM: Add -Werror build option
config: arc-randconfig-r021-20201230 (attached as .config)
compiler: arc-elf-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
git remote add chrome-os https://chromium.googlesource.com/chromiumos/third_party/kernel
git fetch --no-tags chrome-os chromeos-5.10
git checkout 91df3c40faddd7b33f5ae12ade27857c3d4fd974
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> arch/arc/kernel/devtree.c:20:21: error: no previous prototype for 'arc_early_base_baud' [-Werror=missing-prototypes]
20 | unsigned int __init arc_early_base_baud(void)
| ^~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
arch/arc/kernel/disasm.c: In function 'disasm_instr':
>> arch/arc/kernel/disasm.c:28:12: error: variable 'ins_ptr' set but not used [-Werror=unused-but-set-variable]
28 | uint16_t *ins_ptr;
| ^~~~~~~
cc1: all warnings being treated as errors
--
arch/arc/kernel/kgdb.c: In function 'kgdb_arch_handle_exception':
>> arch/arc/kernel/kgdb.c:141:6: error: this statement may fall through [-Werror=implicit-fallthrough=]
141 | if (kgdb_hex2long(&ptr, &addr))
| ^
arch/arc/kernel/kgdb.c:144:2: note: here
144 | case 'D':
| ^~~~
cc1: all warnings being treated as errors
--
>> drivers/iio/accel/mxc6255.c:168:36: error: 'mxc6255_acpi_match' defined but not used [-Werror=unused-const-variable=]
168 | static const struct acpi_device_id mxc6255_acpi_match[] = {
| ^~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
drivers/input/mouse/synaptics.c: In function 'synaptics_process_packet':
drivers/input/mouse/synaptics.c:1110:6: error: suggest braces around empty body in an 'if' statement [-Werror=empty-body]
1110 | ; /* Nothing, treat a pen as a single finger */
| ^
At top level:
>> drivers/input/mouse/synaptics.c:164:27: error: 'smbus_pnp_ids' defined but not used [-Werror=unused-const-variable=]
164 | static const char * const smbus_pnp_ids[] = {
| ^~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
>> drivers/iio/imu/fxos8700_i2c.c:46:36: error: 'fxos8700_acpi_match' defined but not used [-Werror=unused-const-variable=]
46 | static const struct acpi_device_id fxos8700_acpi_match[] = {
| ^~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
>> drivers/iio/imu/fxos8700_spi.c:34:36: error: 'fxos8700_acpi_match' defined but not used [-Werror=unused-const-variable=]
34 | static const struct acpi_device_id fxos8700_acpi_match[] = {
| ^~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
--
>> lib/crypto/blake2s-selftest.c:566:13: error: no previous prototype for 'blake2s_selftest' [-Werror=missing-prototypes]
566 | bool __init blake2s_selftest(void)
| ^~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
vim +/arc_early_base_baud +20 arch/arc/kernel/devtree.c
ffb7fcd66f14bc7 Vineet Gupta 2014-10-28 19
ffb7fcd66f14bc7 Vineet Gupta 2014-10-28 @20 unsigned int __init arc_early_base_baud(void)
ffb7fcd66f14bc7 Vineet Gupta 2014-10-28 21 {
ffb7fcd66f14bc7 Vineet Gupta 2014-10-28 22 return arc_base_baud/16;
ffb7fcd66f14bc7 Vineet Gupta 2014-10-28 23 }
ffb7fcd66f14bc7 Vineet Gupta 2014-10-28 24
:::::: The code at line 20 was first introduced by commit
:::::: ffb7fcd66f14bc716b9fdf559e71909131fef39b ARC: Dynamically determine BASE_BAUD from DeviceTree
:::::: TO: Vineet Gupta <vgupta(a)synopsys.com>
:::::: CC: Vineet Gupta <vgupta(a)synopsys.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
Re: [Intel-gfx] [PATCH 52/56] drm/i915/gt: Infrastructure for ring scheduling
by kernel test robot
Hi Chris,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on drm-tip/drm-tip]
[also build test WARNING on drm-intel/drm-intel-gt-next]
[cannot apply to drm-intel/for-linux-next v5.11-rc1 next-20201223]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Chris-Wilson/drm-i915-gt-Restore...
base: git://anongit.freedesktop.org/drm/drm-tip drm-tip
config: x86_64-randconfig-r026-20201229 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project a8970dff1aece1f83e63f723847098ba992ef185)
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
# install x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
# https://github.com/0day-ci/linux/commit/3668247b4851376f9fd1c943043a86cab...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Chris-Wilson/drm-i915-gt-Restore-ce-signal-flush-before-releasing-virtual-engine/20201229-200517
git checkout 3668247b4851376f9fd1c943043a86cabf3a0f08
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
drivers/gpu/drm/i915/gt/intel_ring_scheduler.c:28:19: warning: unused function 'rq_prio' [-Wunused-function]
static inline int rq_prio(const struct i915_request *rq)
^
drivers/gpu/drm/i915/gt/intel_ring_scheduler.c:33:19: warning: unused function 'rq_deadline' [-Wunused-function]
static inline u64 rq_deadline(const struct i915_request *rq)
^
>> drivers/gpu/drm/i915/gt/intel_ring_scheduler.c:38:20: warning: function 'reset_in_progress' is not needed and will not be emitted [-Wunneeded-internal-declaration]
static inline bool reset_in_progress(const struct intel_engine_cs *engine)
^
drivers/gpu/drm/i915/gt/intel_ring_scheduler.c:135:20: warning: unused function 'ring_map_dw' [-Wunused-function]
static inline u32 *ring_map_dw(struct intel_ring *ring, u32 len)
^
4 warnings generated.
vim +/reset_in_progress +38 drivers/gpu/drm/i915/gt/intel_ring_scheduler.c
37
> 38 static inline bool reset_in_progress(const struct intel_engine_cs *engine)
39 {
40 return unlikely(!__tasklet_is_enabled(&engine->active.tasklet));
41 }
42
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
samples/vfio-mdev/mbochs.c:1270:21: sparse: sparse: incorrect type in argument 1 (different address spaces)
by kernel test robot
Hi Robin,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: dea8dcf2a9fa8cc540136a6cd885c3beece16ec3
commit: b4ceb4a5359ed1c9ba4a20acf3a70d4bbead3248 iommu: Tidy up Kconfig for SoC IOMMUs
date: 6 months ago
config: csky-randconfig-s032-20201227 (attached as .config)
compiler: csky-linux-gcc (GCC) 9.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-184-g1b896707-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout b4ceb4a5359ed1c9ba4a20acf3a70d4bbead3248
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=csky
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
"sparse warnings: (new ones prefixed by >>)"
>> samples/vfio-mdev/mbochs.c:1270:21: sparse: sparse: incorrect type in argument 1 (different address spaces) @@ expected void const *addr @@ got unsigned int const [noderef] __user *__gu_ptr @@
samples/vfio-mdev/mbochs.c:1270:21: sparse: expected void const *addr
samples/vfio-mdev/mbochs.c:1270:21: sparse: got unsigned int const [noderef] __user *__gu_ptr
samples/vfio-mdev/mbochs.c:1346:1: sparse: sparse: symbol 'mdev_type_attr_name' was not declared. Should it be static?
samples/vfio-mdev/mbochs.c:1356:1: sparse: sparse: symbol 'mdev_type_attr_description' was not declared. Should it be static?
samples/vfio-mdev/mbochs.c:1366:1: sparse: sparse: symbol 'mdev_type_attr_available_instances' was not declared. Should it be static?
samples/vfio-mdev/mbochs.c:1373:1: sparse: sparse: symbol 'mdev_type_attr_device_api' was not declared. Should it be static?
vim +1270 samples/vfio-mdev/mbochs.c
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1166
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1167 static long mbochs_ioctl(struct mdev_device *mdev, unsigned int cmd,
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1168 unsigned long arg)
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1169 {
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1170 int ret = 0;
104c7405a64d937 Gerd Hoffmann 2018-09-21 1171 unsigned long minsz, outsz;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1172
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1173 switch (cmd) {
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1174 case VFIO_DEVICE_GET_INFO:
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1175 {
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1176 struct vfio_device_info info;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1177
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1178 minsz = offsetofend(struct vfio_device_info, num_irqs);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1179
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1180 if (copy_from_user(&info, (void __user *)arg, minsz))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1181 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1182
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1183 if (info.argsz < minsz)
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1184 return -EINVAL;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1185
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1186 ret = mbochs_get_device_info(mdev, &info);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1187 if (ret)
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1188 return ret;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1189
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1190 if (copy_to_user((void __user *)arg, &info, minsz))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1191 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1192
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1193 return 0;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1194 }
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1195 case VFIO_DEVICE_GET_REGION_INFO:
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1196 {
104c7405a64d937 Gerd Hoffmann 2018-09-21 1197 struct vfio_region_info_ext info;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1198
104c7405a64d937 Gerd Hoffmann 2018-09-21 1199 minsz = offsetofend(typeof(info), base.offset);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1200
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1201 if (copy_from_user(&info, (void __user *)arg, minsz))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1202 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1203
104c7405a64d937 Gerd Hoffmann 2018-09-21 1204 outsz = info.base.argsz;
104c7405a64d937 Gerd Hoffmann 2018-09-21 1205 if (outsz < minsz)
104c7405a64d937 Gerd Hoffmann 2018-09-21 1206 return -EINVAL;
104c7405a64d937 Gerd Hoffmann 2018-09-21 1207 if (outsz > sizeof(info))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1208 return -EINVAL;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1209
104c7405a64d937 Gerd Hoffmann 2018-09-21 1210 ret = mbochs_get_region_info(mdev, &info);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1211 if (ret)
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1212 return ret;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1213
104c7405a64d937 Gerd Hoffmann 2018-09-21 1214 if (copy_to_user((void __user *)arg, &info, outsz))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1215 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1216
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1217 return 0;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1218 }
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1219
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1220 case VFIO_DEVICE_GET_IRQ_INFO:
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1221 {
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1222 struct vfio_irq_info info;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1223
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1224 minsz = offsetofend(struct vfio_irq_info, count);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1225
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1226 if (copy_from_user(&info, (void __user *)arg, minsz))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1227 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1228
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1229 if ((info.argsz < minsz) ||
104c7405a64d937 Gerd Hoffmann 2018-09-21 1230 (info.index >= VFIO_PCI_NUM_IRQS))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1231 return -EINVAL;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1232
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1233 ret = mbochs_get_irq_info(mdev, &info);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1234 if (ret)
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1235 return ret;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1236
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1237 if (copy_to_user((void __user *)arg, &info, minsz))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1238 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1239
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1240 return 0;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1241 }
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1242
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1243 case VFIO_DEVICE_QUERY_GFX_PLANE:
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1244 {
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1245 struct vfio_device_gfx_plane_info plane;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1246
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1247 minsz = offsetofend(struct vfio_device_gfx_plane_info,
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1248 region_index);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1249
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1250 if (copy_from_user(&plane, (void __user *)arg, minsz))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1251 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1252
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1253 if (plane.argsz < minsz)
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1254 return -EINVAL;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1255
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1256 ret = mbochs_query_gfx_plane(mdev, &plane);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1257 if (ret)
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1258 return ret;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1259
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1260 if (copy_to_user((void __user *)arg, &plane, minsz))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1261 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1262
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1263 return 0;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1264 }
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1265
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1266 case VFIO_DEVICE_GET_GFX_DMABUF:
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1267 {
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1268 u32 dmabuf_id;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1269
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 @1270 if (get_user(dmabuf_id, (__u32 __user *)arg))
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1271 return -EFAULT;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1272
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1273 return mbochs_get_gfx_dmabuf(mdev, dmabuf_id);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1274 }
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1275
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1276 case VFIO_DEVICE_SET_IRQS:
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1277 return -EINVAL;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1278
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1279 case VFIO_DEVICE_RESET:
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1280 return mbochs_reset(mdev);
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1281 }
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1282 return -ENOTTY;
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1283 }
a5e6e6505f38f7b Gerd Hoffmann 2018-05-11 1284
:::::: The code at line 1270 was first introduced by commit
:::::: a5e6e6505f38f7bce1d3576503a2bffff3fa888c sample: vfio bochs vbe display (host device for bochs-drm)
:::::: TO: Gerd Hoffmann <kraxel(a)redhat.com>
:::::: CC: Alex Williamson <alex.williamson(a)redhat.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months