[Intel-wired-lan] [PATCH net v2] ixgbe: add NULL pointer check before calling xdp_rxq_info_reg

Nguyen, Anthony L anthony.l.nguyen at intel.com
Sat Jan 23 00:13:08 UTC 2021


On Fri, 2021-01-22 at 09:54 -0800, Alexander Duyck wrote:
> On Fri, Jan 22, 2021 at 5:29 AM wangyunjian <wangyunjian at huawei.com>
> wrote:
> > 
> > From: Yunjian Wang <wangyunjian at huawei.com>
> > 
> > The rx_ring->q_vector could be NULL, so it needs to be checked
> > before
> > calling xdp_rxq_info_reg.
> > 
> > Fixes: b02e5a0ebb172 ("xsk: Propagate napi_id to XDP socket Rx
> > path")
> > Addresses-Coverity: ("Dereference after null check")
> > Signed-off-by: Yunjian Wang <wangyunjian at huawei.com>
> 
> This is kind of a big escape for the driver. From what I can tell it
> looks like the "ethtool -t" test now causes a NULL pointer
> dereference.
> 
> As far as the patch itself it looks good to me. This should probably
> be pushed for any of the other Intel drivers that follow a similar
> model as I suspect they were exhibit the same symptom with "ethtool
> -t" triggering a NULL pointer dereference.

Thanks for the review Alex. We'll look into fixing the other Intel
drivers.

Thanks,
Tony


More information about the Intel-wired-lan mailing list