Intel-Wired-Lan Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Intel-wired-lan] [bug report] ice: switch to Page Pool
@ 2026-05-09  7:07 Dan Carpenter
  0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2026-05-09  7:07 UTC (permalink / raw)
  To: Michal Kubiak; +Cc: intel-wired-lan

Hello Michal Kubiak,

Commit 93f53db9f9dc ("ice: switch to Page Pool") from Sep 25, 2025
(linux-next), leads to the following Smatch static checker warning:

	drivers/net/ethernet/intel/ice/ice_xsk.c:203 ice_xsk_pool_setup()
	warn: potential bounds check after use 'qid'

drivers/net/ethernet/intel/ice/ice_xsk.c
    197 int ice_xsk_pool_setup(struct ice_vsi *vsi, struct xsk_buff_pool *pool, u16 qid)
    198 {
    199         struct ice_rx_ring *rx_ring = vsi->rx_rings[qid];
                                              ^^^^^^^^^^^^^^^^^^
This looks like potentially an out of bounds read.

    200         bool if_running, pool_present = !!pool;
    201         int ret = 0, pool_failure = 0;
    202 
--> 203         if (qid >= vsi->num_rxq || qid >= vsi->num_txq) {
                    ^^^^^^^^^^^^^^^^^^^
qid is checked here but it's too late.

    204                 netdev_err(vsi->netdev, "Please use queue id in scope of combined queues count\n");
    205                 pool_failure = -EINVAL;
    206                 goto failure;
    207         }

This email is a free service from the Smatch-CI project [smatch.sf.net].

regards,
dan carpenter

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-05-09  7:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-09  7:07 [Intel-wired-lan] [bug report] ice: switch to Page Pool Dan Carpenter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox