[PATCH net-next v6 1/2] net: ethtool: Introduce per-PHY DUMP operations
Paolo Abeni
pabeni at redhat.com
Thu Apr 17 03:03:43 PDT 2025
On 4/15/25 10:51 AM, Maxime Chevallier wrote:
> +static int ethnl_perphy_dump_all_dev(struct sk_buff *skb,
> + struct ethnl_perphy_dump_ctx *ctx,
> + const struct genl_info *info)
> +{
> + struct ethnl_dump_ctx *ethnl_ctx = &ctx->ethnl_ctx;
> + struct net *net = sock_net(skb->sk);
> + struct net_device *dev;
> + int ret = 0;
> +
> + rcu_read_lock();
> + for_each_netdev_dump(net, dev, ethnl_ctx->pos_ifindex) {
> + dev_hold(dev);
Minor nit: please use netdev_hold() instead.
Thanks,
Paolo
More information about the linux-arm-kernel
mailing list