[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports
From: |
Michael S. Tsirkin |
Subject: |
Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports |
Date: |
Mon, 15 Nov 2021 06:13:38 -0500 |
On Fri, Nov 12, 2021 at 12:15:28PM +0100, Gerd Hoffmann wrote:
> On Thu, Nov 11, 2021 at 10:39:59AM -0500, Michael S. Tsirkin wrote:
> > On Thu, Nov 11, 2021 at 01:09:05PM +0100, Gerd Hoffmann wrote:
> > > Hi,
> > >
> > > > When the acpihp driver is used the linux kernel will just call the aml
> > > > methods and I suspect the pci device will stay invisible then because
> > > > nobody flips the slot power control bit (with native-hotplug=on, for
> > > > native-hotplug=off this isn't a problem of course).
> > >
> > > Hmm, on a quick smoke test with both patch series (mine + igors) applied
> > > everything seems to work fine on a quick glance. Dunno why. Maybe the
> > > pcieport driver turns on slot power even in case pciehp is not active.
>
> Digged deeper. Updating power status is handled by the plug() callback,
> which is never called in case acpi hotplug is active. The guest seems
> to never touch slot power control either, so it's working fine. Still
> feels a bit fragile though.
>
> > Well power and hotplug capabilities are mostly unrelated, right?
>
> At least they are separate slot capabilities. The linux pciehp driver
> checks whenever the power control is present before using it, so having
> PwrCtrl- HotPlug+ seems to be a valid combination.
>
> We even have an option for that: pcie-root-port.power_controller_present
>
> So flipping that to off in case apci hotplug is active should make sure
> we never run into trouble with pci devices being powered off.
>
> Igor? Can you add that to your patch series?
>
> > I feel switching to native so late would be inappropriate, looks more
> > like a feature than a bugfix. Given that - we need Igor's patches.
> > Given that - would you say I should apply yours?
>
> I think when setting power_controller_present=off for acpi hotplug it is
> safe to merge both mine and igor's.
>
> take care,
> Gerd
So this did not surface yet but I guess we can do this as
a patch on top, either of you can post it.
--
MST
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Michael S. Tsirkin, 2021/11/01
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Michael S. Tsirkin, 2021/11/10
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Gerd Hoffmann, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Michael S. Tsirkin, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Gerd Hoffmann, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Gerd Hoffmann, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Michael S. Tsirkin, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Gerd Hoffmann, 2021/11/12
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Igor Mammedov, 2021/11/12
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports,
Michael S. Tsirkin <=
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Daniel P . Berrangé, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Michael S. Tsirkin, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Daniel P . Berrangé, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Michael S. Tsirkin, 2021/11/11
- Re: [PATCH 0/6] RfC: try improve native hotplug for pcie root ports, Gerd Hoffmann, 2021/11/12