[kernel/f19] Fix build issue with PowerPC MSI patches (rhbz 962496)
Josh Boyer
jwboyer at fedoraproject.org
Tue Jun 4 17:37:12 UTC 2013
commit f9b60448ad77032ae3a3f357a28280bbce1004dd
Author: Josh Boyer <jwboyer at redhat.com>
Date: Tue Jun 4 13:37:01 2013 -0400
Fix build issue with PowerPC MSI patches (rhbz 962496)
kernel.spec | 5 +++-
...ries-Make-32-bit-MSI-quirk-work-on-system.patch | 22 ++++++++++---------
2 files changed, 16 insertions(+), 11 deletions(-)
---
diff --git a/kernel.spec b/kernel.spec
index d9a7be5..aaceefd 100644
--- a/kernel.spec
+++ b/kernel.spec
@@ -2321,7 +2321,10 @@ fi
# and build.
%changelog
-* Mon Jun 03 2013 Josh Boyer <jwboyer at redhat.com>
+* Tue Jun 04 2013 Josh Boyer <jwboyer at redhat.com>
+- Fix build issue with PowerPC MSI patches (rhbz 962496)
+
+* Mon Jun 03 2013 Josh Boyer <jwboyer at redhat.com> - 3.9.4-301
- Fix UEFI anti-bricking code (rhbz 964335)
- Add patches to fix PowerPC MSI handling (rhbz 962496)
diff --git a/powerpc-pseries-Make-32-bit-MSI-quirk-work-on-system.patch b/powerpc-pseries-Make-32-bit-MSI-quirk-work-on-system.patch
index 6edd14b..8add1a4 100644
--- a/powerpc-pseries-Make-32-bit-MSI-quirk-work-on-system.patch
+++ b/powerpc-pseries-Make-32-bit-MSI-quirk-work-on-system.patch
@@ -1,4 +1,4 @@
-From ad735c038a1c3273b605c398a765fdd525527ef7 Mon Sep 17 00:00:00 2001
+From ffbc2a5d4bb9c758867332d2f4d521a02375e43a Mon Sep 17 00:00:00 2001
From: Brian King <brking at linux.vnet.ibm.com>
Date: Wed, 22 May 2013 11:07:46 +0000
Subject: [PATCH] powerpc/pseries: Make 32-bit MSI quirk work on systems
@@ -16,19 +16,20 @@ this to configurations where this hack is needed and tested to work.
Signed-off-by: Brian King <brking at linux.vnet.ibm.com>
Signed-off-by: Benjamin Herrenschmidt <benh at kernel.crashing.org>
---
- arch/powerpc/platforms/pseries/msi.c | 40 +++++++++++++++++++++++++++++++++---
- 1 file changed, 37 insertions(+), 3 deletions(-)
+ arch/powerpc/platforms/pseries/msi.c | 42 +++++++++++++++++++++++++++++++++---
+ 1 file changed, 39 insertions(+), 3 deletions(-)
diff --git a/arch/powerpc/platforms/pseries/msi.c b/arch/powerpc/platforms/pseries/msi.c
-index 420524e..cd7d23d 100644
+index 420524e..5a75b02 100644
--- a/arch/powerpc/platforms/pseries/msi.c
+++ b/arch/powerpc/platforms/pseries/msi.c
-@@ -394,6 +394,23 @@ static int check_msix_entries(struct pci_dev *pdev)
+@@ -394,6 +394,25 @@ static int check_msix_entries(struct pci_dev *pdev)
return 0;
}
+static void rtas_hack_32bit_msi_gen2(struct pci_dev *pdev)
+{
++ int pos;
+ u32 addr_hi, addr_lo;
+
+ /*
@@ -38,16 +39,17 @@ index 420524e..cd7d23d 100644
+ */
+ dev_info(&pdev->dev,
+ "rtas_msi: No 32 bit MSI firmware support, forcing 32 bit MSI\n");
-+ pci_read_config_dword(pdev, pdev->msi_cap + PCI_MSI_ADDRESS_HI, &addr_hi);
++ pos = pci_find_capability(pdev, PCI_CAP_ID_MSI);
++ pci_read_config_dword(pdev, pos + PCI_MSI_ADDRESS_HI, &addr_hi);
+ addr_lo = 0xffff0000 | ((addr_hi >> (48 - 32)) << 4);
-+ pci_write_config_dword(pdev, pdev->msi_cap + PCI_MSI_ADDRESS_LO, addr_lo);
-+ pci_write_config_dword(pdev, pdev->msi_cap + PCI_MSI_ADDRESS_HI, 0);
++ pci_write_config_dword(pdev, pos + PCI_MSI_ADDRESS_LO, addr_lo);
++ pci_write_config_dword(pdev, pos + PCI_MSI_ADDRESS_HI, 0);
+}
+
static int rtas_setup_msi_irqs(struct pci_dev *pdev, int nvec_in, int type)
{
struct pci_dn *pdn;
-@@ -401,6 +418,7 @@ static int rtas_setup_msi_irqs(struct pci_dev *pdev, int nvec_in, int type)
+@@ -401,6 +420,7 @@ static int rtas_setup_msi_irqs(struct pci_dev *pdev, int nvec_in, int type)
struct msi_desc *entry;
struct msi_msg msg;
int nvec = nvec_in;
@@ -55,7 +57,7 @@ index 420524e..cd7d23d 100644
pdn = get_pdn(pdev);
if (!pdn)
-@@ -428,15 +446,31 @@ static int rtas_setup_msi_irqs(struct pci_dev *pdev, int nvec_in, int type)
+@@ -428,15 +448,31 @@ static int rtas_setup_msi_irqs(struct pci_dev *pdev, int nvec_in, int type)
*/
again:
if (type == PCI_CAP_ID_MSI) {
More information about the scm-commits
mailing list