Subject: Re: [PATCH net-next v2 7/8] netdevsim: add debugfs-triggered queue reset

From: Jakub Kicinski <[email-masked]>
Date: Tue, 7 Jan 2025 16:50:45 -0800

On Tue, 7 Jan 2025 15:00:29 -0800 Mina Almasry wrote:
> > +       if (queue >= ns->netdev->real_num_rx_queues) {
> > +               ret = -EINVAL;
> > +               goto exit_unlock;
> > +       }  
> 
> Is it correct that both these above checks are not inside of
> netdev_rx_queue_restart() itself? Or should we fix that?

Crossed my mind, too. But I didn't want to start futzing with
netdev_rx_queue_restart() based on just two callers. I hope
we'll get to a queue API based safe reset sooner rather than
later, and the driver needs will dedicate the final shape.

More concisely put - a debugfs hook in a test harness is not
a strong signal for whether the API is right.