mbox

[RFC,v2,v2,00/29] Bus and device cleanup for 22.11

Message ID 20220709082644.664675-1-david.marchand@redhat.com (mailing list archive)
Headers

Message

David Marchand July 9, 2022, 8:26 a.m. UTC
  This is a PoC for hiding the rte_bus, rte_driver and rte_device objects.
And mark associated driver only API as internal.

A good amount of the patches are preparation work on rte_bus.h,
rte_dev.h, rte_devargs.h and rte_eal.h headers, removing dependencies
between them. This is something I had in store for some time, maybe I
should have dropped it from the PoC, but I think those cleanups are
worth it in any case.

Then PCI bus specific handling are moved from unit tests and examples,
though there is still a special case left in testpmd that may require a
new API, to be discussed.

After this series, driver-only API headers for registering to buses are
not exported anymore, unless the enable_driver_sdk meson option is
selected.

New accessors for rte_bus, rte_driver and rte_device have been added,
marked with an experimental tag though we may declare them as stable
right away so that users can switch to them directly. That's also
something to agree on.

I simplified my series and switched to only update "external" users,
like app/ and examples/ files.
We need some checkpatch new checks to be sure we won't get some
driver-only headers included in these areas. That's something I'll work
on in the non RFC series.

"Internal" users are simply using the internal headers. That helps
greatly reducing the size of the changes.

Disclaimer: again, in this v2, this series is a bit rushed (I brute forced
compilation tests in GHA so that it passes between patches, but there still
may be something broken...).
Not surprisingly, the ABI check in the CI is expected to fail.


Comments welcome.

Changes since RFC v1:
- added two more cleanups (new patch 3 and 4) for unit test and examples
  relying on PCI specific info,
- went on with masking rte_driver and rte_device too,