Hi Emil, FYI, the error/warning was bisected to this commit, please ignore it if it's irrelevant.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/tnguy/net-queue.git dev-queue head: e50b34f0f3fb86c9be2f9ad3b7ed483f18b46896 commit: 7c0e8a950dbd30ca46e999cf1d25f3e97a98f174 [7/17] idpf: convert vport state to bitmap config: loongarch-allyesconfig (https://download.01.org/0day-ci/archive/20251004/[email protected]/config) compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 39f292ffa13d7ca0d1edff27ac8fd55024bb4d19) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251004/[email protected]/reproduce) 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 <[email protected]> | Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ All warnings (new ones prefixed by >>): drivers/net/ethernet/intel/idpf/idpf_ethtool.c:1713:19: error: use of undeclared identifier '__IDPF_VPORT_UP'; did you mean 'IDPF_VPORT_UP'? 1713 | if (np->state != __IDPF_VPORT_UP) | ^~~~~~~~~~~~~~~ | IDPF_VPORT_UP drivers/net/ethernet/intel/idpf/idpf.h:138:2: note: 'IDPF_VPORT_UP' declared here 138 | IDPF_VPORT_UP, | ^ >> drivers/net/ethernet/intel/idpf/idpf_ethtool.c:1713:10: warning: comparison >> of array 'np->state' not equal to a null pointer is always true >> [-Wtautological-pointer-compare] 1713 | if (np->state != __IDPF_VPORT_UP) | ~~~~^~~~~ ~~~~~~~~~~~~~~~ 1 warning and 1 error generated. -- drivers/net/ethernet/intel/idpf/xdp.c:421:20: error: use of undeclared identifier '__IDPF_VPORT_UP'; did you mean 'IDPF_VPORT_UP'? 421 | if (np->state == __IDPF_VPORT_UP) | ^~~~~~~~~~~~~~~ | IDPF_VPORT_UP drivers/net/ethernet/intel/idpf/idpf.h:138:2: note: 'IDPF_VPORT_UP' declared here 138 | IDPF_VPORT_UP, | ^ >> drivers/net/ethernet/intel/idpf/xdp.c:421:11: warning: comparison of array >> 'np->state' equal to a null pointer is always false >> [-Wtautological-pointer-compare] 421 | if (np->state == __IDPF_VPORT_UP) | ~~~~^~~~~ ~~~~~~~~~~~~~~~ 1 warning and 1 error generated. vim +1713 drivers/net/ethernet/intel/idpf/idpf_ethtool.c 1a49cf814fe1ed Milena Olech 2025-04-16 1687 7a5a03869801e2 Milena Olech 2025-08-29 1688 /** 7a5a03869801e2 Milena Olech 2025-08-29 1689 * idpf_get_ts_stats - Collect HW tstamping statistics 7a5a03869801e2 Milena Olech 2025-08-29 1690 * @netdev: network interface device structure 7a5a03869801e2 Milena Olech 2025-08-29 1691 * @ts_stats: HW timestamping stats structure 7a5a03869801e2 Milena Olech 2025-08-29 1692 * 7a5a03869801e2 Milena Olech 2025-08-29 1693 * Collect HW timestamping statistics including successfully timestamped 7a5a03869801e2 Milena Olech 2025-08-29 1694 * packets, discarded due to illegal values, flushed during releasing PTP and 7a5a03869801e2 Milena Olech 2025-08-29 1695 * skipped due to lack of the free index. 7a5a03869801e2 Milena Olech 2025-08-29 1696 */ 7a5a03869801e2 Milena Olech 2025-08-29 1697 static void idpf_get_ts_stats(struct net_device *netdev, 7a5a03869801e2 Milena Olech 2025-08-29 1698 struct ethtool_ts_stats *ts_stats) 7a5a03869801e2 Milena Olech 2025-08-29 1699 { 7a5a03869801e2 Milena Olech 2025-08-29 1700 struct idpf_netdev_priv *np = netdev_priv(netdev); 7a5a03869801e2 Milena Olech 2025-08-29 1701 struct idpf_vport *vport; 7a5a03869801e2 Milena Olech 2025-08-29 1702 unsigned int start; 7a5a03869801e2 Milena Olech 2025-08-29 1703 7a5a03869801e2 Milena Olech 2025-08-29 1704 idpf_vport_ctrl_lock(netdev); 7a5a03869801e2 Milena Olech 2025-08-29 1705 vport = idpf_netdev_to_vport(netdev); 7a5a03869801e2 Milena Olech 2025-08-29 1706 do { 7a5a03869801e2 Milena Olech 2025-08-29 1707 start = u64_stats_fetch_begin(&vport->tstamp_stats.stats_sync); 7a5a03869801e2 Milena Olech 2025-08-29 1708 ts_stats->pkts = u64_stats_read(&vport->tstamp_stats.packets); 7a5a03869801e2 Milena Olech 2025-08-29 1709 ts_stats->lost = u64_stats_read(&vport->tstamp_stats.flushed); 7a5a03869801e2 Milena Olech 2025-08-29 1710 ts_stats->err = u64_stats_read(&vport->tstamp_stats.discarded); 7a5a03869801e2 Milena Olech 2025-08-29 1711 } while (u64_stats_fetch_retry(&vport->tstamp_stats.stats_sync, start)); 7a5a03869801e2 Milena Olech 2025-08-29 1712 7a5a03869801e2 Milena Olech 2025-08-29 @1713 if (np->state != __IDPF_VPORT_UP) 7a5a03869801e2 Milena Olech 2025-08-29 1714 goto exit; 7a5a03869801e2 Milena Olech 2025-08-29 1715 7a5a03869801e2 Milena Olech 2025-08-29 1716 for (u16 i = 0; i < vport->num_txq_grp; i++) { 7a5a03869801e2 Milena Olech 2025-08-29 1717 struct idpf_txq_group *txq_grp = &vport->txq_grps[i]; 7a5a03869801e2 Milena Olech 2025-08-29 1718 7a5a03869801e2 Milena Olech 2025-08-29 1719 for (u16 j = 0; j < txq_grp->num_txq; j++) { 7a5a03869801e2 Milena Olech 2025-08-29 1720 struct idpf_tx_queue *txq = txq_grp->txqs[j]; 7a5a03869801e2 Milena Olech 2025-08-29 1721 struct idpf_tx_queue_stats *stats; 7a5a03869801e2 Milena Olech 2025-08-29 1722 u64 ts; 7a5a03869801e2 Milena Olech 2025-08-29 1723 7a5a03869801e2 Milena Olech 2025-08-29 1724 if (!txq) 7a5a03869801e2 Milena Olech 2025-08-29 1725 continue; 7a5a03869801e2 Milena Olech 2025-08-29 1726 7a5a03869801e2 Milena Olech 2025-08-29 1727 stats = &txq->q_stats; 7a5a03869801e2 Milena Olech 2025-08-29 1728 do { 7a5a03869801e2 Milena Olech 2025-08-29 1729 start = u64_stats_fetch_begin(&txq->stats_sync); 7a5a03869801e2 Milena Olech 2025-08-29 1730 7a5a03869801e2 Milena Olech 2025-08-29 1731 ts = u64_stats_read(&stats->tstamp_skipped); 7a5a03869801e2 Milena Olech 2025-08-29 1732 } while (u64_stats_fetch_retry(&txq->stats_sync, 7a5a03869801e2 Milena Olech 2025-08-29 1733 start)); 7a5a03869801e2 Milena Olech 2025-08-29 1734 7a5a03869801e2 Milena Olech 2025-08-29 1735 ts_stats->lost += ts; 7a5a03869801e2 Milena Olech 2025-08-29 1736 } 7a5a03869801e2 Milena Olech 2025-08-29 1737 } 7a5a03869801e2 Milena Olech 2025-08-29 1738 7a5a03869801e2 Milena Olech 2025-08-29 1739 exit: 7a5a03869801e2 Milena Olech 2025-08-29 1740 idpf_vport_ctrl_unlock(netdev); 7a5a03869801e2 Milena Olech 2025-08-29 1741 } 7a5a03869801e2 Milena Olech 2025-08-29 1742 :::::: The code at line 1713 was first introduced by commit :::::: 7a5a03869801e2f1cabdc55b2e697fea20da5c68 idpf: add HW timestamping statistics :::::: TO: Milena Olech <[email protected]> :::::: CC: Tony Nguyen <[email protected]> -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
