Re: [PATCH net] PCI: fix the return value for the pci_find_pcie_root_port()

2017-08-17 Thread Ding Tianhong
On 2017/8/17 21:30, Thierry Reding wrote: > On Thu, Aug 17, 2017 at 08:40:16PM +0800, Ding Tianhong wrote: >> >> >> On 2017/8/17 18:51, Thierry Reding wrote: >>> On Thu, Aug 17, 2017 at 10:25:30AM +0800, Ding Tianhong wrote: The pci_find_pcie_root_port() would return NULL if the given

Re: [PATCH net] PCI: fix the return value for the pci_find_pcie_root_port()

2017-08-17 Thread Thierry Reding
On Thu, Aug 17, 2017 at 08:40:16PM +0800, Ding Tianhong wrote: > > > On 2017/8/17 18:51, Thierry Reding wrote: > > On Thu, Aug 17, 2017 at 10:25:30AM +0800, Ding Tianhong wrote: > >> The pci_find_pcie_root_port() would return NULL if the given > >> dev is already a Root Port, it looks like

Re: [PATCH net] PCI: fix the return value for the pci_find_pcie_root_port()

2017-08-17 Thread Ding Tianhong
On 2017/8/17 18:51, Thierry Reding wrote: > On Thu, Aug 17, 2017 at 10:25:30AM +0800, Ding Tianhong wrote: >> The pci_find_pcie_root_port() would return NULL if the given >> dev is already a Root Port, it looks like unfriendly to the >> PCIe Root Port device, Thierry and Bjorn suggest to let

Re: [PATCH net] PCI: fix the return value for the pci_find_pcie_root_port()

2017-08-17 Thread Thierry Reding
On Thu, Aug 17, 2017 at 10:25:30AM +0800, Ding Tianhong wrote: > The pci_find_pcie_root_port() would return NULL if the given > dev is already a Root Port, it looks like unfriendly to the > PCIe Root Port device, Thierry and Bjorn suggest to let this > function return the given dev under this

Re: [PATCH net] PCI: fix the return value for the pci_find_pcie_root_port()

2017-08-16 Thread David Miller
From: Ding Tianhong Date: Thu, 17 Aug 2017 10:25:30 +0800 > The pci_find_pcie_root_port() would return NULL if the given > dev is already a Root Port, it looks like unfriendly to the > PCIe Root Port device, Thierry and Bjorn suggest to let this > function return the

[PATCH net] PCI: fix the return value for the pci_find_pcie_root_port()

2017-08-16 Thread Ding Tianhong
The pci_find_pcie_root_port() would return NULL if the given dev is already a Root Port, it looks like unfriendly to the PCIe Root Port device, Thierry and Bjorn suggest to let this function return the given dev under this circumstances. Fixes: 0e405232871d6 ("PCI: fix oops when try to find Root