Re: [PATCH v6 04/12] PCI: Make pciehp_is_native() stricter

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, May 10, 2018 at 09:51:49PM +0200, Lukas Wunner wrote:
> On Thu, May 10, 2018 at 09:28:36PM +0300, Mika Westerberg wrote:
> > +	pcie_capability_read_dword(bridge, PCI_EXP_SLTCAP, &slot_cap);
> > +	if (!(slot_cap & PCI_EXP_SLTCAP_HPC))
> >  		return false;
> 
> Hm, any reason not to use "if (!bridge->is_hotplug_bridge)" ?

That can be set for non-native PCIe bridges. For example acpiphp sets it
in some cases. Here we read the capability directly to make sure we are
really dealing with native PCIe hotplug.



[Index of Archives]     [DMA Engine]     [Linux Coverity]     [Linux USB]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Greybus]

  Powered by Linux