From: sashiko-bot@kernel.org
To: "Harshitha Ramamurthy" <hramamurthy@google.com>
Cc: bpf@vger.kernel.org
Subject: Re: [PATCH net-next v5 07/12] gve: add gve_ctrl_ops for gve initialization/teardown sequences
Date: Fri, 04 Sep 2026 21:56:32 +0000 [thread overview]
Message-ID: <20260904215632.D98E61F00A3F@smtp.kernel.org> (raw)
In-Reply-To: <20260903215606.31633-8-hramamurthy@google.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] The ethtool callback `gve_set_rxfh` bypasses the `gve_ctrl_ops` abstraction by calling `gve_adminq_configure_rss` directly.
--
commit 10b1b0685ff2bac01a7188b6c0dc5c2a0e9dae42
Author: Joshua Washington <joshwash@google.com>
gve: add gve_ctrl_ops for gve initialization/teardown sequences
Driver initialization and teardown involve a number of control plane
operations that need to be defined for gve_probe to operate in both
mailbox and adminq modes.
> diff --git a/drivers/net/ethernet/google/gve/gve_main.c b/drivers/net/ethernet/google/gve/gve_main.c
> index acd09e9f416c1..5ad7a8f9bbddb 100644
> --- a/drivers/net/ethernet/google/gve/gve_main.c
> +++ b/drivers/net/ethernet/google/gve/gve_main.c
[ ... ]
> @@ -1815,6 +1820,7 @@ static int gve_xdp(struct net_device *dev, struct netdev_bpf *xdp)
>
> int gve_init_rss_config(struct gve_priv *priv, u16 num_queues)
> {
> + const struct gve_ctrl_ops *ops = priv->ctrl_ops;
> struct gve_rss_config *rss_config = &priv->rss_config;
> struct ethtool_rxfh_param rxfh = {0};
> u16 i;
> @@ -1830,15 +1836,17 @@ int gve_init_rss_config(struct gve_priv *priv, u16 num_queues)
>
> rxfh.hfunc = ETH_RSS_HASH_TOP;
>
> - return gve_adminq_configure_rss(priv, &rxfh);
> + return ops->configure_rss(priv, &rxfh);
> }
[Severity: Medium]
While this function is updated to use the new ops->configure_rss abstraction,
does gve_set_rxfh() in drivers/net/ethernet/google/gve/gve_ethtool.c also need
to be updated?
It appears to still call gve_adminq_configure_rss() directly:
drivers/net/ethernet/google/gve/gve_ethtool.c:gve_set_rxfh() {
...
if (!priv->rss_key_size || !priv->rss_lut_size)
return -EOPNOTSUPP;
err = gve_adminq_configure_rss(priv, rxfh);
...
}
Should this also be calling ops->configure_rss() to prevent bypassing the
abstraction and potentially causing undefined behavior when alternative control
plane modes are used?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260903215606.31633-1-hramamurthy@google.com?part=7
next prev parent reply other threads:[~2026-09-04 21:56 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-03 21:55 [PATCH net-next v5 00/12] gve: AdminQ mode related refactors Harshitha Ramamurthy
2026-09-03 21:55 ` [PATCH net-next v5 01/12] gve: add struct gve_device_info to hold device properties Harshitha Ramamurthy
2026-09-04 21:56 ` sashiko-bot
2026-09-03 21:55 ` [PATCH net-next v5 02/12] gve: introduce control plane operations structure Harshitha Ramamurthy
2026-09-03 21:55 ` [PATCH net-next v5 03/12] gve: introduce ctrl ops to set vectors and Qs Harshitha Ramamurthy
2026-09-03 21:55 ` [PATCH net-next v5 04/12] gve: introduce gve_adminq_get_device_properties() Harshitha Ramamurthy
2026-09-03 21:55 ` [PATCH net-next v5 05/12] gve: refactor gve_init_priv for reset path Harshitha Ramamurthy
2026-09-03 21:56 ` [PATCH net-next v5 06/12] gve: simplify reset logic Harshitha Ramamurthy
2026-09-04 21:56 ` sashiko-bot
2026-09-03 21:56 ` [PATCH net-next v5 07/12] gve: add gve_ctrl_ops for gve initialization/teardown sequences Harshitha Ramamurthy
2026-09-04 21:56 ` sashiko-bot [this message]
2026-09-03 21:56 ` [PATCH net-next v5 08/12] gve: split up notify block allocation and setup paths Harshitha Ramamurthy
2026-09-03 21:56 ` [PATCH net-next v5 09/12] gve: introduce new methods to handle IRQ doorbells Harshitha Ramamurthy
2026-09-04 21:56 ` sashiko-bot
2026-09-03 21:56 ` [PATCH net-next v5 10/12] gve: setup and teardown management interrupts Harshitha Ramamurthy
2026-09-04 21:56 ` sashiko-bot
2026-09-03 21:56 ` [PATCH net-next v5 11/12] gve: add ctrl ops to for queue operations Harshitha Ramamurthy
2026-09-03 21:56 ` [PATCH net-next v5 12/12] gve: add link status/speed ctrl ops Harshitha Ramamurthy
2026-09-04 21:56 ` sashiko-bot
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=20260904215632.D98E61F00A3F@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=hramamurthy@google.com \
--cc=sashiko-reviews@lists.linux.dev \
/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