Message ID | 20240611023324.1485426-1-dw@davidwei.uk (mailing list archive) |
---|---|
Headers | show |
Series | bnxt_en: implement netdev_queue_mgmt_ops | expand |
On 6/10/24 8:33 PM, David Wei wrote: > Implement netdev_queue_mgmt_ops for bnxt added in [1]. This will be used > in the io_uring ZC Rx patchset to configure queues with a custom page > pool w/ a special memory provider for zero copy support. > I do not see it explicitly called out, so asking here: does this change enable / require header split if using memory from this "special memory provider"?
On 2024-06-10 19:40, David Ahern wrote: > On 6/10/24 8:33 PM, David Wei wrote: >> Implement netdev_queue_mgmt_ops for bnxt added in [1]. This will be used >> in the io_uring ZC Rx patchset to configure queues with a custom page >> pool w/ a special memory provider for zero copy support. >> > > > I do not see it explicitly called out, so asking here: does this change > enable / require header split if using memory from this "special memory > provider"? This patchset is orthogonal to header split and page pool memory providers. It implements netdev_queue_mgmt_ops which enables dynamically resetting a single Rx queue without needing a full device close/open, and pre-allocates queue descriptor memory _before_ stopping the queue to minimise downtime. It shows that, with FW support and carefully written code, it is possible for drivers to move away from doing full resets on changes. My first intent is to use it for reconfiguring an Rx queue with a different page pool, but that isn't the only purpose. For example, it opens up the possibility of dynamically creating queues that share a single napi instance.
On 6/10/24 9:41 PM, David Wei wrote: > > This patchset is orthogonal to header split and page pool memory > providers. It implements netdev_queue_mgmt_ops which enables dynamically Ok, where is the validation that these queues must be configured for header-data split to use non-kernel memory?
On 2024-06-12 08:52, David Ahern wrote: > On 6/10/24 9:41 PM, David Wei wrote: >> >> This patchset is orthogonal to header split and page pool memory >> providers. It implements netdev_queue_mgmt_ops which enables dynamically > > Ok, where is the validation that these queues must be configured for > header-data split to use non-kernel memory? Any validation would be done outside of this patchset, which only focuses on resetting an Rx queue. Reconfiguring page pools and HDS is orthogonal and unrelated to this patchset. The netdev core API consuming netdev_queue_mgmt_ops would be netdev_rx_queue_restart() added in [1]. [1]: https://lore.kernel.org/lkml/20240607005127.3078656-2-almasrymina@google.com/ Validation would be done at a layer above, i.e. whatever that calls netdev_rx_queue_restart(), as opposed to netdev_rx_queue_restart() or netdev_queue_mgmt_ops itself.
On Wed, 12 Jun 2024 11:19:47 -0700 David Wei wrote: > Any validation would be done outside of this patchset, which only > focuses on resetting an Rx queue. Reconfiguring page pools and HDS is > orthogonal and unrelated to this patchset. > > The netdev core API consuming netdev_queue_mgmt_ops would be > netdev_rx_queue_restart() added in [1]. > > [1]: https://lore.kernel.org/lkml/20240607005127.3078656-2-almasrymina@google.com/ > > Validation would be done at a layer above, i.e. whatever that calls > netdev_rx_queue_restart(), as opposed to netdev_rx_queue_restart() or > netdev_queue_mgmt_ops itself. One could be tempted to pass a "configuration" object to tell the driver that this queue will be required to run with HDS enabled. I wonder where I've seen such a thing...
On Wed, Jun 12, 2024 at 11:19:47AM -0700, David Wei wrote: > On 2024-06-12 08:52, David Ahern wrote: > > On 6/10/24 9:41 PM, David Wei wrote: > >> > >> This patchset is orthogonal to header split and page pool memory > >> providers. It implements netdev_queue_mgmt_ops which enables dynamically > > > > Ok, where is the validation that these queues must be configured for > > header-data split to use non-kernel memory? > > Any validation would be done outside of this patchset, which only > focuses on resetting an Rx queue. Reconfiguring page pools and HDS is > orthogonal and unrelated to this patchset. I can confirm this. These changes are just to keep the allocation schemes the same as they are today, but add support for stopping/freeing and starting/allocating rings individually and via the new API. > The netdev core API consuming netdev_queue_mgmt_ops would be > netdev_rx_queue_restart() added in [1]. > > [1]: https://lore.kernel.org/lkml/20240607005127.3078656-2-almasrymina@google.com/ > > Validation would be done at a layer above, i.e. whatever that calls > netdev_rx_queue_restart(), as opposed to netdev_rx_queue_restart() or > netdev_queue_mgmt_ops itself.