From: Bruce Richardson <bruce.richardson@intel.com>
To: Sandeep Penigalapati <sandeep.penigalapati@intel.com>
Cc: <dev@dpdk.org>, Anatoly Burakov <anatoly.burakov@intel.com>,
"Vladimir Medvedkin" <vladimir.medvedkin@intel.com>,
Piotr Kwapulinski <piotr.kwapulinski@intel.com>,
Jedrzej Jagielski <jedrzej.jagielski@intel.com>,
<stable@dpdk.org>
Subject: Re: [PATCH v2] net/ixgbe: fix null dereference on EEPROM write for E610
Date: Mon, 28 Sep 2026 14:14:11 +0100 [thread overview]
Message-ID: <arpoI5ltCdcblnwI@bricha3-mobl1.ger.corp.intel.com> (raw)
In-Reply-To: <20260928201253.45484-1-sandeep.penigalapati@intel.com>
On Mon, Sep 28, 2026 at 04:12:53PM -0400, Sandeep Penigalapati wrote:
> E610 does not support EEPROM writes and leaves eeprom.ops.write_buffer
> as NULL. ixgbe_set_eeprom() calls this pointer without checking it,
> causing a NULL pointer dereference when a set-eeprom request is issued
> on an E610 port.
>
> Check the op for NULL and return -ENOTSUP instead.
>
> Fixes: 316637762a5f ("net/ixgbe/base: enable E610 device")
> Cc: stable@dpdk.org
>
> Signed-off-by: Sandeep Penigalapati <sandeep.penigalapati@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
> v2:
> - Moved the NULL check before the argument validation so an
> unsupported request returns -ENOTSUP instead of -EINVAL.
>
> drivers/net/intel/ixgbe/ixgbe_ethdev.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/drivers/net/intel/ixgbe/ixgbe_ethdev.c b/drivers/net/intel/ixgbe/ixgbe_ethdev.c
> index 78e19f94c0..b7b2b92e3c 100644
> --- a/drivers/net/intel/ixgbe/ixgbe_ethdev.c
> +++ b/drivers/net/intel/ixgbe/ixgbe_ethdev.c
> @@ -7362,6 +7362,9 @@ ixgbe_set_eeprom(struct rte_eth_dev *dev,
> if (rte_eal_process_type() != RTE_PROC_PRIMARY)
> return -E_RTE_SECONDARY;
>
> + if (eeprom->ops.write_buffer == NULL)
> + return -ENOTSUP;
> +
> first = in_eeprom->offset >> 1;
> length = in_eeprom->length >> 1;
> if ((first > hw->eeprom.word_size) ||
> --
> 2.27.0
>
next prev parent reply other threads:[~2026-09-28 13:14 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-28 16:50 [PATCH] net/ixgbe: fix null dereference on EEPROM write for E610 Sandeep Penigalapati
2026-09-28 10:36 ` Bruce Richardson
2026-09-28 20:12 ` [PATCH v2] " Sandeep Penigalapati
2026-09-28 13:14 ` Bruce Richardson [this message]
2026-09-28 13:44 ` Bruce Richardson
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=arpoI5ltCdcblnwI@bricha3-mobl1.ger.corp.intel.com \
--to=bruce.richardson@intel.com \
--cc=anatoly.burakov@intel.com \
--cc=dev@dpdk.org \
--cc=jedrzej.jagielski@intel.com \
--cc=piotr.kwapulinski@intel.com \
--cc=sandeep.penigalapati@intel.com \
--cc=stable@dpdk.org \
--cc=vladimir.medvedkin@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox