Skip to contentSkip to conversation

linuxppc-2.5 / Sandpoint X2

DISCUSSION John Traill 4 participants 5 messages Nov 15, 2002 – Nov 18, 2002

lore
Share & tools
lore
#0 lore raw

I'm having problems getting linuxppc-2.5 running on an X2 Sandpoint system. Firstly there are a couple of failures during the build relating to changes in the interrupt handling. I've made the obvious changes in sandpoint_setup.c

openpic_init(1,0,NULL,-1) -> openpic_init(0)
i8259_poll() -> i8259_irq(regs)

The kernel boots, mounts file system etc... but after "Freeing unused kernel memory: 96k init" no prompt - Initial debug shows that the kernel is executing some of the interrupt routines (sandpoint_get_irq(), openpic_irq() etc ). However I'm not sure if this is indicative of an error in the changes above or just the fact that the kernel isn't doing anything else but service irq's.

Any help/pointers would be gratefully received.

--

Regards, John

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#1 lore raw

Hi
Looks like there is some problem in mapping of serial port interrupt. Because after booting the kernel serial port will work in interrupt routine.Now u have to verify two things :

1. in openpic what is the interrupt vector for serial port.
2. Same interrupt vectupr u have to program in ur serial.h file.....

may be u will have a success if not send me ur sandpoint_setup.c & openpci_irq.c & kernel booting message.

Thanx

Bhupi

Linux +HyPERtransport --->Silicon
www.gdatech.com

Quoted 22 lines · --- John Traill

I'm having problems getting linuxppc-2.5 running on an X2 Sandpoint system. Firstly there are a couple of failures
during the build relating to changes in the interrupt handling. I've made the obvious changes in sandpoint_setup.c

openpic_init(1,0,NULL,-1) -> openpic_init(0) i8259_poll() -> i8259_irq(regs)

The kernel boots, mounts file system etc... but after "Freeing unused kernel memory: 96k init" no prompt - Initial
debug shows that the kernel is executing some of the interrupt routines (sandpoint_get_irq(), openpic_irq() etc ).
However I'm not sure if this is indicative of an error in the changes above or just the fact that the kernel isn't doing
anything else but service irq's.

Quoted 8 lines

Any help/pointers would be gratefully received.

--

Regards, John

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#2 lore raw
In reply to John Traill
Quoted 3 lines · John Traill

However I'm not sure if this is indicative of an error in the changes above or just the fact that the kernel isn't doing anything else but service irq's.

Check the switch S5, which changes the IRQ polarity. Maybe the interrupt line is always asserted.
On a 8240 CPU, it needs reversed polarity.

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#3 lore raw

The existing switch configuration works for a 2.4 kernel. Changing S5 makes no difference.

Quoted 12 lines · Michael Habermann
Quoted 3 lines · John Traill

However I'm not sure if this is indicative of an error in the changes above or just the fact that the kernel isn't doing anything else but service irq's.

Check the switch S5, which changes the IRQ polarity. Maybe the interrupt line is always asserted.
On a 8240 CPU, it needs reversed polarity.

--

Regards, John
___________________________________________________________________________

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/

#4 lore raw
In reply to John Traill
Quoted 17 lines · John Traill

I'm having problems getting linuxppc-2.5 running on an X2 Sandpoint system. Firstly there are a couple of failures
during the build relating to changes in the interrupt handling. I've made the obvious changes in sandpoint_setup.c

openpic_init(1,0,NULL,-1) -> openpic_init(0)
i8259_poll() -> i8259_irq(regs)

The kernel boots, mounts file system etc... but after "Freeing unused kernel memory: 96k init" no prompt - Initial
debug shows that the kernel is executing some of the interrupt routines (sandpoint_get_irq(), openpic_irq() etc ).
However I'm not sure if this is indicative of an error in the changes above or just the fact that the kernel isn't doing
anything else but service irq's.

Quoted 1 line

Any help/pointers would be gratefully received.

You need more changes, no doubt. :) The following patches made an X3 work, maybe a few months ago. I didn't check them in at the time as X2 support was not working, and I hadn't figured out a good, 2.5 type solution to the problem of the i8259 not being where expected (and Paul had mentioned he didn't like the workaround in 2.4 for this and would prefre something nicer for 2.5).

--
Tom Rini (TR1265)
http://gate.crashing.org/~trini/

===== arch/ppc/platforms/sandpoint.h 1.1 vs edited =====

arch/ppc/platforms/sandpoint.h +2 -0
@@ -21,6 +21,8 @@
 #ifndef __PPC_PLATFORMS_SANDPOINT_H
 #define __PPC_PLATFORMS_SANDPOINT_H
 
+#include <asm/ppcboot.h>
+
 #ifdef CONFIG_SANDPOINT_X3
 #define SANDPOINT_SIO_SLOT      0	/* Cascaded from EPIC IRQ 0 */
 #if 0

===== arch/ppc/platforms/sandpoint_pci.c 1.1 vs edited =====

arch/ppc/platforms/sandpoint_pci.c +7 -11
@@ -44,17 +44,10 @@
 		       0,  0,  0 },	/* IDSEL 11 - i8259 on Winbond */
 		{  0,  0,  0,  0 },	/* IDSEL 12 - unused */
 #ifdef CONFIG_SANDPOINT_X3
-#if 0	/* This is what it _should_ look like -- Dan */
-		{ 17, 20, 19, 18 },	/* IDSEL 13 - PCI slot 1 */
-		{ 18, 17, 20, 19 },	/* IDSEL 14 - PCI slot 2 */
-		{ 19, 18, 17, 20 },	/* IDSEL 15 - PCI slot 3 */
-		{ 20, 19, 18, 17 },	/* IDSEL 16 - PCI slot 4 */
-#else
 		{ 18, 21, 20, 19 },	/* IDSEL 13 - PCI slot 1 */
 		{ 19, 18, 21, 20 },	/* IDSEL 14 - PCI slot 2 */
 		{ 20, 19, 18, 21 },	/* IDSEL 15 - PCI slot 3 */
 		{ 21, 20, 19, 18 },	/* IDSEL 16 - PCI slot 4 */
-#endif
 #else
 		{ 16, 19, 18, 17 },	/* IDSEL 13 - PCI slot 1 */
 		{ 17, 16, 19, 18 },	/* IDSEL 14 - PCI slot 2 */
@@ -134,15 +127,18 @@
 	return;
 }
 
+/* On the sandpoint X2, we must avoid sending configuration cycles to
+ * device #12 (IDSEL addr = AD12).  This has been fixed in the X3.
+ */
 static int
 sandpoint_exclude_device(u_char bus, u_char devfn)
 {
-	if ((bus == 0) && (PCI_SLOT(devfn) == SANDPOINT_HOST_BRIDGE_IDSEL)) {
+#ifndef CONFIG_SANDPOINT_X3
+	if ((bus == 0) && (PCI_SLOT(devfn) == SANDPOINT_HOST_BRIDGE_IDSEL))
 		return PCIBIOS_DEVICE_NOT_FOUND;
-	}
-	else {
+	else
+#endif
 		return PCIBIOS_SUCCESSFUL;
-	}
 }
 
 void __init

===== arch/ppc/platforms/sandpoint_setup.c 1.8 vs edited =====

arch/ppc/platforms/sandpoint_setup.c +155 -148

457 lines not on this page · raw message

** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/