Restructuring to the Linux kernel’s PCI Resizable BAR “ReBAR” support is set to be submitted for the upcoming Linux 6.19 kernel cycle.
Ilpo Järvinen of Intel has been working on improvements to the PCIe Resizable BAR code and is set to appear in the next kernel version. Ilpo explained on the prior patch series:
“pci.c has been used as catch everything that doesn’t fits elsewhere within PCI core and thus resizable BAR code has been placed there as well. Move Resizable BAR related code to a newly introduced rebar.c to reduce size of pci.c. After move, there are no pci_rebar_*() calls from pci.c indicating this is indeed well-defined subset of PCI core.
Endpoint drivers perform Resizable BAR related operations which could well be performed by PCI core to simplify driver-side code. This series adds a few new API functions to that effect and converts the drivers to use the new APIs (in separate patches).
While at it, also convert BAR sizes bitmask to u64 as PCIe spec already specifies more sizes than what will fit u32 to make the API typing more future-proof. The extra sizes beyond 128TB are not added at this point.
Some parts of this are to be used by the resizable BAR changes into the resource fitting/assingment logic but these seem to stand on their own so sending these out now to reduce the size of the other patch series.”
The patches have been queued into PCI.git’s “next” Git branch. With these ReBAR code enhancements now in the PCI next branch, they should in turn be submitted for the Linux 6.19 merge window happening in December.
