Re: [PATCH] virt-pci: add platform bus support

From: Rob Herring
Date: Mon Mar 06 2023 - 19:31:39 EST


On Tue, Feb 14, 2023 at 01:12:25PM +0100, Vincent Whitchurch wrote:
> On Mon, Feb 13, 2023 at 06:54:49PM +0100, Johannes Berg wrote:
> > On Fri, 2023-01-27 at 15:30 +0100, Vincent Whitchurch wrote:
> > > My first approach to getting platform drivers working on UML was by
> > > adding a minimal PCI-to-platform bridge driver, which worked without
> > > modifications to virt-pci, but that got shot down:
> > >
> > > https://lore.kernel.org/lkml/20230120-simple-mfd-pci-v1-1-c46b3d6601ef@xxxxxxxx/
> >
> > Reading through that ... OK that isn't fun either :-)
> >
> > Sounds like there's a use case for something else though, but the PCI
> > IDs issue also makes that thorny.
>
> Yes, Greg was initially totally opposed to the idea of putting platform
> devices under PCI devices, but in his latest email he seemed to
> allow it in some cases. It's still unclear if he'd be OK with a
> "virtual PCI-to-platform bridge" though. And yes, adding platform
> devices support like in this patch removes one layer and also eliminates
> the disadvantage of having to wait for user space to specify a PCI ID
> for the bridge device.

Like I said in that thread, we have multiple usecases needing something
similar for non-discoverable MMIO devices behind a PCI device. And I
convinced Greg a platform device was okay, so please continue that path.

I'm adding you to the thread of other usecases.

Rob