Skip to contentSkip to conversation

sparc32: added CONFIG_PCIC_PCI Kconfig setting

PATCH In review Daniel Hellstrom 3 participants 4 messages May 24, 2011 – Jun 3, 2011 SPARC + UltraSPARC (sparc/sparc64)

lore
Share & tools
lore
#0 lore raw

PATCH v3 1/3 sparc32: added CONFIG_PCIC_PCI Kconfig setting

---
 arch/sparc/Kconfig            |    5 +++++
 arch/sparc/include/asm/pcic.h |    2 +-
 arch/sparc/kernel/Makefile    |    2 +-
 arch/sparc/kernel/entry.S     |    4 ++--
 4 files changed, 9 insertions(+), 4 deletions(-)
arch/sparc/Kconfig +5 -0
index 63a027c..c06bd34 100644
@@ -536,6 +536,11 @@ config PCI_DOMAINS
 config PCI_SYSCALL
 	def_bool PCI
 
+config PCIC_PCI
+	bool
+	depends on PCI && !SPARC_LEON
+	default y
+
 source "drivers/pci/Kconfig"
 
 source "drivers/pcmcia/Kconfig"
arch/sparc/include/asm/pcic.h +1 -1
index 7eb5d78..6676cbc 100644
@@ -29,7 +29,7 @@ struct linux_pcic {
 	int			pcic_imdim;
 };
 
-#ifdef CONFIG_PCI
+#ifdef CONFIG_PCIC_PCI
 extern int pcic_present(void);
 extern int pcic_probe(void);
 extern void pci_time_init(void);
arch/sparc/kernel/Makefile +1 -1
index 9cff270..59a2256 100644
@@ -73,7 +73,7 @@ obj-$(CONFIG_SPARC64_SMP) += cpumap.o
 
 obj-y                     += dma.o
 
-obj-$(CONFIG_SPARC32_PCI) += pcic.o
+obj-$(CONFIG_PCIC_PCI)    += pcic.o
 
 obj-$(CONFIG_SMP)         += trampoline_$(BITS).o smp_$(BITS).o
 obj-$(CONFIG_SPARC32_SMP) += sun4m_smp.o sun4d_smp.o leon_smp.o
arch/sparc/kernel/entry.S +2 -2
index 8341963..6b9a321 100644
@@ -1604,7 +1604,7 @@ restore_current:
 	retl
 	 nop
 
-#ifdef CONFIG_PCI
+#ifdef CONFIG_PCIC_PCI
 #include <asm/pcic.h>
 
 	.align	4
@@ -1650,7 +1650,7 @@ pcic_nmi_trap_patch:
 	 rd	%psr, %l0
 	.word	0
 
-#endif /* CONFIG_PCI */
+#endif /* CONFIG_PCI_PCIC */
 
 	.globl	flushw_all
 flushw_all:
Signature · 1 line
1.6.3.3
#1 lore raw

Daniel,

Minor nit, only if you end up re-spinning this again.

Quoted 16 lines · Daniel Hellstrom

---
 arch/sparc/Kconfig            |    5 +++++
 arch/sparc/include/asm/pcic.h |    2 +-
 arch/sparc/kernel/Makefile    |    2 +-
 arch/sparc/kernel/entry.S     |    4 ++--

 4 files changed, 9 insertions(+), 4 deletions(-)
arch/sparc/kernel/entry.S +0 -0
index 8341963..6b9a321 100644
@@ -1650,7 +1650,7 @@ pcic_nmi_trap_patch:

        rd     %psr, %l0
       .word   0

arch/sparc/kernel/entry.S pcic_nmi_trap_patch: · line 1653

Quoted 2 lines
arch/sparc/kernel/entry.S +1 -1
-#endif /* CONFIG_PCI */
+#endif /* CONFIG_PCI_PCIC */

This should be CONFIG_PCIC_PCI

Otherwise it looks good to me.

Thanks,

Signature · 5 lines
Julian Calaby

Email: [email protected]
Profile: http://www.google.com/profiles/julian.calaby/
.Plan: http://sites.google.com/site/juliancalaby/
maintainer
#2 lore raw
In reply to Daniel Hellstrom

From: Julian Calaby <[email protected]>
Date: Wed, 25 May 2011 08:47:41 +1000

Quoted 9 lines · Daniel Hellstrom

arch/sparc/kernel/entry.S pcic_nmi_trap_patch: · line 1653

Quoted 6 lines
(quoted diff) +0 -0
@@ -1650,7 +1650,7 @@ pcic_nmi_trap_patch:

        rd     %psr, %l0
       .word   0

arch/sparc/kernel/entry.S +1 -1
-#endif /* CONFIG_PCI */
+#endif /* CONFIG_PCI_PCIC */

This should be CONFIG_PCIC_PCI

I fixed this up when applying the patches.

#3 lore raw
In reply to Daniel Hellstrom
Quoted 20 lines · David Miller

From: Julian Calaby <[email protected]>
Date: Wed, 25 May 2011 08:47:41 +1000

Quoted 7 lines · Daniel Hellstrom
Quoted 6 lines
arch/sparc/kernel/entry.S +0 -0
@@ -1650,7 +1650,7 @@ pcic_nmi_trap_patch:
       rd     %psr, %l0
      .word   0
 
Quoted 7 lines

arch/sparc/kernel/entry.S pcic_nmi_trap_patch:

Quoted 4 lines
arch/sparc/kernel/entry.S +1 -1
-#endif /* CONFIG_PCI */
+#endif /* CONFIG_PCI_PCIC */
 
 

This should be CONFIG_PCIC_PCI

Quoted 3 lines

I fixed this up when applying the patches.

Thanks all for the previous comments and for finding and fixing this particular problem. Thanks for applying the patches.

Best Regards,

Daniel