On 09/05/2023 11:19, Verma, Achal wrote:Current pci-j721e driver is composed of host specific and endpoint specific code encapsulated in switch case and shared required common code, last attempt of putting endpoint and host specific code inside EP and HOST CONFIGS respectively failed (also reported by kernel test bot) when tried with different combinations of Y/M/N along with CADENCE driver on which pci-j721e depends, So only way is to break main module into common, host and endpoint files.
On 5/9/2023 1:58 PM, Arnd Bergmann wrote:
On Tue, May 9, 2023, at 10:08, Vignesh Raghavendra wrote:So, my understanding is that following change is expected
Also, see  for history. We really want these to be
modules unless its necessary for bootup.
You may want to revive  and get it to mainline
Agreed, that seems simple enough. Ideally these should even
be removable modules, not just single-load but unremovable.
Doing that may require changes to the cadence PCIe host
code if that does not support unloading yet (I have not
checked), but should not require any changes to the core
PCIe host code that supports loadable/removable modules.
I also want to inform that pci_j721e.c is a single file with both host
and EP functionality, last attempt to build it as modules depending on
host or EP selected failed because of symbols dependency.
Refactoring of pci_j721e.c into common, host and EP specific files could
work similar to the Cadence driver, So I will follow this way and push
Please let me know if there are concerns.
Aren't HOST and EP just customizing main module?