PCI: vmd: Free up IRQs on suspend path
Subsystems (2)
PATCH 1/1 PCI: vmd: Free up IRQs on suspend path
commit e2b1820bd5d09 upstream
Free up the IRQs we request on the suspend path and reallocate them on the resume path.
Fixes this error:
CPU 111 disable failed: CPU has 9 vectors assigned and there are only 0 available. Error taking CPU111 down: -34
Non-boot CPUs are not disabled
Enabling non-boot CPUs ...
For consistency, this patch also includes the VMD portion of:3eefa790c9681: PCI: host: Mark PCIe/PCI (MSI) cascade ISR as IRQF_NO_THREAD
--- drivers/pci/host/vmd.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-)
drivers/pci/host/vmd.c +17 -1
@@ -698,7 +698,8 @@ static int vmd_probe(struct pci_dev *dev, const struct pci_device_id *id)for (i =0 ; i < vmd->msix_count; i++) {INIT_LIST_HEAD (&vmd->irqs[i].irq_list); err =devm_request_irq (&dev->dev,pci_irq_vector (dev, i), - vmd_irq,0 ,"vmd" , &vmd->irqs[i]); + vmd_irq,IRQF_NO_THREAD , +"vmd" , &vmd->irqs[i]);if (err)return err; }
@@ -731,6 +732,11 @@ static void vmd_remove(struct pci_dev *dev)static int vmd_suspend (struct device *dev) {struct pci_dev *pdev =to_pci_dev (dev); +struct vmd_dev *vmd =pci_get_drvdata (pdev); +int i; + +for (i =0 ; i < vmd->msix_count; i++) +devm_free_irq (dev,pci_irq_vector (pdev, i), &vmd->irqs[i]);pci_save_state (pdev);return 0 ;
@@ -739,6 +745,16 @@ static int vmd_suspend(struct device *dev)static int vmd_resume (struct device *dev) {struct pci_dev *pdev =to_pci_dev (dev); +struct vmd_dev *vmd =pci_get_drvdata (pdev); +int err, i; + +for (i =0 ; i < vmd->msix_count; i++) { + err =devm_request_irq (dev,pci_irq_vector (pdev, i), + vmd_irq,IRQF_NO_THREAD , +"vmd" , &vmd->irqs[i]); +if (err) +return err; + }pci_restore_state (pdev);return 0 ;
Signature · 1 line
2.17.1
Greg KH
maintainerQuoted 15 lines · Sushma Kalakota
commit
e2b1820bd5d09upstreamFree up the IRQs we request on the suspend path and reallocate them on the resume path.
Fixes this error:
CPU 111 disable failed: CPU has 9 vectors assigned and there are only 0 available. Error taking CPU111 down: -34
Non-boot CPUs are not disabled
Enabling non-boot CPUs ...For consistency, this patch also includes the VMD portion of:
3eefa790c9681: PCI: host: Mark PCIe/PCI (MSI) cascade ISR asIRQF_NO_THREAD
Quoted 9 lines
CC Scott Bauer <[email protected]>CC Bjorn Helgaas <[email protected]>CC Keith Busch <[email protected]>Reviewed-by Jon Derrick <[email protected]>Signed-off-by Sushma Kalakota <[email protected]>--- drivers/pci/host/vmd.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-)
What stable kernel tree(s) do you want this patch applied to? And why?
thanks,
greg k-h
Quoted 29 lines · Greg KH
Quoted 18 lines · Sushma Kalakota
commit
e2b1820bd5d09upstreamFree up the IRQs we request on the suspend path and reallocate them on the
resume path.Fixes this error:
CPU 111 disable failed: CPU has 9 vectors assigned and there are
only 0 available.
Error taking CPU111 down: -34
Non-boot CPUs are not disabled
Enabling non-boot CPUs ...For consistency, this patch also includes the VMD portion of:
3eefa790c9681: PCI: host: Mark PCIe/PCI (MSI) cascade ISR asIRQF_NO_THREADQuoted 9 lines
CC Scott Bauer <[email protected]>CC Bjorn Helgaas <[email protected]>CC Keith Busch <[email protected]>Reviewed-by Jon Derrick <[email protected]>Signed-off-by Sushma Kalakota <[email protected]>--- drivers/pci/host/vmd.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-)
Quoted 6 lines
What stable kernel tree(s) do you want this patch applied to? And why?
thanks,
greg k-h
Hi Greg,
This is for 4.9.y and intended to increase reliability of suspend/resume not leading to a failure to suspend or failure to resume, either of which would be undesireable to users of the feature, and potentially make the overall feature unusable if suspend/resume were user requirement.
[email protected]
maintainerQuoted 37 lines · Jonathan
Quoted 29 lines · Greg KH
Quoted 18 lines · Sushma Kalakota
commit
e2b1820bd5d09upstreamFree up the IRQs we request on the suspend path and reallocate them on the
resume path.Fixes this error:
CPU 111 disable failed: CPU has 9 vectors assigned and there are
only 0 available.
Error taking CPU111 down: -34
Non-boot CPUs are not disabled
Enabling non-boot CPUs ...For consistency, this patch also includes the VMD portion of:
3eefa790c9681: PCI: host: Mark PCIe/PCI (MSI) cascade ISR asIRQF_NO_THREADQuoted 9 lines
CC Scott Bauer <[email protected]>CC Bjorn Helgaas <[email protected]>CC Keith Busch <[email protected]>Reviewed-by Jon Derrick <[email protected]>Signed-off-by Sushma Kalakota <[email protected]>--- drivers/pci/host/vmd.c | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-)Quoted 6 lines
What stable kernel tree(s) do you want this patch applied to? And why?
thanks,
greg k-h
Quoted 7 lines
Hi Greg,
This is for 4.9.y and intended to increase reliability of suspend/resume not leading to a failure to suspend or failure to resume, either of which would be undesireable to users of the feature, and potentially make the overall feature unusable if suspend/resume were user requirement.
Ok, but who is still using this old kernel on these types of machines? Why haven't they moved to 4.14 or newer by now? The normal systems that use 4.9 or older should not need this, as they are the horrid SoC trees.
Who has reported this problem in their systems?
thanks,
greg k-h
Quoted 12 lines · Sushma Kalakota
commit
e2b1820bd5d09upstreamFree up the IRQs we request on the suspend path and reallocate them on the resume path.
Fixes this error:
CPU 111 disable failed: CPU has 9 vectors assigned and there are only 0 available. Error taking CPU111 down: -34
Non-boot CPUs are not disabled
Enabling non-boot CPUs ...
Quoted 8 lines
For consistency, this patch also includes the VMD portion of:
3eefa790c9681: PCI: host: Mark PCIe/PCI (MSI) cascade ISR asIRQF_NO_THREADCC Scott Bauer <[email protected]>CC Bjorn Helgaas <[email protected]>CC Keith Busch <[email protected]>Reviewed-by Jon Derrick <[email protected]>Signed-off-by Sushma Kalakota <[email protected]>
Now queued up, thanks.
greg k-h