RE: [Intel-wired-lan] [PATCH iwl-next v6 08/14] idpf: refactor idpf to use libie control queues

From: Salin, Samuel

Date: Tue Mar 31 2026 - 12:25:10 EST




> -----Original Message-----
> From: Intel-wired-lan <intel-wired-lan-bounces@xxxxxxxxxx> On Behalf Of
> Paul Menzel
> Sent: Monday, March 23, 2026 11:59 AM
> To: Zaremba, Larysa <larysa.zaremba@xxxxxxxxx>
> Cc: intel-wired-lan@xxxxxxxxxxxxxxxx; Nguyen, Anthony L
> <anthony.l.nguyen@xxxxxxxxx>; Lobakin, Aleksander
> <aleksander.lobakin@xxxxxxxxx>; Samudrala, Sridhar
> <sridhar.samudrala@xxxxxxxxx>; Singhai, Anjali <anjali.singhai@xxxxxxxxx>;
> Michal Swiatkowski <michal.swiatkowski@xxxxxxxxxxxxxxx>; Fijalkowski, Maciej
> <maciej.fijalkowski@xxxxxxxxx>; Tantilov, Emil S <emil.s.tantilov@xxxxxxxxx>;
> Chittim, Madhu <madhu.chittim@xxxxxxxxx>; Hay, Joshua A
> <joshua.a.hay@xxxxxxxxx>; Keller, Jacob E <jacob.e.keller@xxxxxxxxx>;
> Shanmugam, Jayaprakash <jayaprakash.shanmugam@xxxxxxxxx>; Jiri Pirko
> <jiri@xxxxxxxxxxx>; David S. Miller <davem@xxxxxxxxxxxxx>; Eric Dumazet
> <edumazet@xxxxxxxxxx>; Jakub Kicinski <kuba@xxxxxxxxxx>; Paolo Abeni
> <pabeni@xxxxxxxxxx>; Simon Horman <horms@xxxxxxxxxx>; Jonathan
> Corbet <corbet@xxxxxxx>; Richard Cochran <richardcochran@xxxxxxxxx>;
> Kitszel, Przemyslaw <przemyslaw.kitszel@xxxxxxxxx>; Andrew Lunn
> <andrew+netdev@xxxxxxx>; netdev@xxxxxxxxxxxxxxx; linux-
> doc@xxxxxxxxxxxxxxx; linux-kernel@xxxxxxxxxxxxxxx
> Subject: Re: [Intel-wired-lan] [PATCH iwl-next v6 08/14] idpf: refactor idpf to
> use libie control queues
>
> Dear Larysa, dear Pavan,
>
>
> Thank you for your patch.
>
> Am 23.03.26 um 18:40 schrieb Larysa Zaremba:
> > From: Pavan Kumar Linga <pavan.kumar.linga@xxxxxxxxx>
> >
> > Support to initialize and configure controlqs, and manage their
> > transactions was introduced in libie. As part of it, most of the existing
> > controlq structures are renamed and modified. Use those APIs in idpf and
> > make all the necessary changes.
> >
> > Previously for the send and receive virtchnl messages, there used to be a
> > memcpy involved in controlq code to copy the buffer info passed by the send
> > function into the controlq specific buffers. There was no restriction to
> > use automatic memory in that case. The new implementation in libie
> removed
> > copying of the send buffer info and introduced DMA mapping of the send
> > buffer itself. To accommodate it, use dynamic memory for the larger send
> > buffers. For smaller ones (<= 128 bytes) libie still can copy them into the
> > pre-allocated message memory.
> >
> > In case of receive, idpf receives a page pool buffer allocated by the libie
> > and care should be taken to release it after use in the idpf.
> >
> > The changes are fairly trivial and localized, with a notable exception
> > being the consolidation of idpf_vc_xn_shutdown and idpf_deinit_dflt_mbx
> > under the latter name. This has some additional consequences that are
> > addressed in the following patches.
> >
> > This refactoring introduces roughly additional 40KB of module storage used
> > for systems that only run idpf, so idpf + libie_cp + libie_pci takes about
> > 7% more storage than just idpf before refactoring.
>
> Excuse my ignorance, but what is “module storage”? Size of the build module?
>
> > We now pre-allocate small TX buffers, so that does increase the memory
> > usage, but reduces the need to allocate. This results in additional 256 *
> > 128B of memory permanently used, increasing the worst-case memory
> usage by
> > 32KB but our ctlq RX buffers need to be of size 4096B anyway (not changed
> > by the patchset), so this is hardly noticeable.
>
> Thank you for adding this information.
>
> > As for the timings, the fact that we are mostly limited by the HW response
> > time which is far from instant, is not changed by this refactor.
>
> It’d be great if you named a benchmark you used to test this.
>
> > Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@xxxxxxxxx>
> > Signed-off-by: Pavan Kumar Linga <pavan.kumar.linga@xxxxxxxxx>
> > Co-developed-by: Larysa Zaremba <larysa.zaremba@xxxxxxxxx>
> > Signed-off-by: Larysa Zaremba <larysa.zaremba@xxxxxxxxx>
> > Signed-off-by: Tony Nguyen <anthony.l.nguyen@xxxxxxxxx>
> > ---
>
> Great diffstat!
>
>
>
> Kind regards,
>
> Paul

Tested-by: Samuel Salin <Samuel.salin@xxxxxxxxx>