Skip to contentSkip to conversation

2.4 kernels broken on Takara?

DISCUSSION Jay Maynard 3 participants 7 messages Feb 8, 2004 – Feb 10, 2004 Alpha port

lore
Share & tools
lore
#0 lore raw

I'm trying to install Gentoo on a Takara (PICMG 21164A/500). The only installer I've found that will run is the Debian 3.0r2 CD, which has a 2.2.20 kernel on it. That's not new enough for Gentoo, which needs a 2.4 to install. I've tried installing a Debian system, then a 2.4 kernel on top of that - but 2.4.18 and 2.4.24 prebuilt generic kernels, as well as a 2.4.24 custom kernel built specifically for the Takara, all blow up with a kernel paging error during startup, right after the PCI bridges are detected. The 2.2.20 kernel iinstalled by Debian runs fine.

What do I need to do to find this problem and fix it?

#1 lore raw

On Sun, 2004-02-08 10:39:09 -0600, Jay Maynard <[email protected]> wrote in message <[email protected]>:

Quoted 5 lines

install. I've tried installing a Debian system, then a 2.4 kernel on top of that - but 2.4.18 and 2.4.24 prebuilt generic kernels, as well as a 2.4.24 custom kernel built specifically for the Takara, all blow up with a kernel paging error during startup, right after the PCI bridges are detected. The 2.2.20 kernel iinstalled by Debian runs fine.

I remember there were problems with the PCI bridging code. Maybe you'd try to give 2.6.x a shot...

MfG, JBG

Signature · 4 lines
   Jan-Benedict Glaw       [email protected]    . +49-172-7608481
   "Eine Freie Meinung in  einem Freien Kopf    | Gegen Zensur | Gegen Krieg
    fuer einen Freien Staat voll Freier Bürger" | im Internet! |   im Irak!
   ret = do_actions((curr | FREE_SPEECH) & ~(NEW_COPYRIGHT_LAW | DRM | TCPA));
#2 lore raw
Quoted 9 lines · Jan-Benedict Glaw

On Sun, 2004-02-08 10:39:09 -0600, Jay Maynard <[email protected]> wrote in message <[email protected]>:

Quoted 5 lines

install. I've tried installing a Debian system, then a 2.4 kernel on top of that - but 2.4.18 and 2.4.24 prebuilt generic kernels, as well as a 2.4.24 custom kernel built specifically for the Takara, all blow up with a kernel paging error during startup, right after the PCI bridges are detected. The 2.2.20 kernel iinstalled by Debian runs fine.

I remember there were problems with the PCI bridging code. Maybe you'd try to give 2.6.x a shot...

No luck, although I got a little better look at the error messages. I've retyped them here:

PCI: Bus 2, bridge: 0000:00:14.0
IO window: 8000-8fff
MEM window: 02400000-037fffff
PREFETCH window: 02200000-022fffff
PCI: Setting latency timer of device 0000:00:13.0 to 64

Unable to handle kernel paging request at virtual address 0000000000000040

swapper(1): Oops 0
pc = [<fffffc00004eecf0>] ra = [<fffffc00004eecc8>] ps = 0000 Not tainted
[register dump here]
Trace:fffffc0000310124 fffffc00003151e8

Code: 261dfff1 401f0000 a4410038 2c810078 20210078 22107a7c <a0420040>
488100c4
Kernel panic: Attempted to kill init!

This is with the generic Debian 2.6.0 kernel. Now what?

#3 lore raw

On Sun, 2004-02-08 17:53:12 -0600, Jay Maynard <[email protected]> wrote in message <[email protected]>:

Quoted 14 lines · Jan-Benedict Glaw
Quoted 9 lines

On Sun, 2004-02-08 10:39:09 -0600, Jay Maynard <[email protected]> wrote in message <[email protected]>:

Quoted 5 lines

install. I've tried installing a Debian system, then a 2.4 kernel on top of that - but 2.4.18 and 2.4.24 prebuilt generic kernels, as well as a 2.4.24 custom kernel built specifically for the Takara, all blow up with a kernel paging error during startup, right after the PCI bridges are detected. The 2.2.20 kernel iinstalled by Debian runs fine.

I remember there were problems with the PCI bridging code. Maybe you'd try to give 2.6.x a shot...

No luck, although I got a little better look at the error messages. I've retyped them here:

Quoted 6 lines

PCI: Bus 2, bridge: 0000:00:14.0
IO window: 8000-8fff
MEM window: 02400000-037fffff
PREFETCH window: 02200000-022fffff
PCI: Setting latency timer of device 0000:00:13.0 to 64

Unable to handle kernel paging request at virtual address 0000000000000040

0x40 means that there (most probably) was an access to some struct by a pointer. If this is a "normal" struct containing ints and pointers, it's most probably access to the 9th structure element.

Quoted 3 lines

swapper(1): Oops 0
pc = [<fffffc00004eecf0>] ra = [<fffffc00004eecc8>] ps = 0000 Not tainted
[register dump here]

This is the interesting part. Get the value of "pc" and those from the stack printout which start with "fffffc" and decode them with the matching System.map file (you'll find that in /boot). The values printed on screen are typically a bit larger than those in the System.map file, so search for the largest address line in that file which is still smaller than what you've found on screen.

Quoted 6 lines

Trace:fffffc0000310124 fffffc00003151e8

Code: 261dfff1 401f0000 a4410038 2c810078 20210078 22107a7c <a0420040>
488100c4
Kernel panic: Attempted to kill init!

This is with the generic Debian 2.6.0 kernel. Now what?

Decode the oops. That'll exactly tell where it happened.

MfG, JBG

Signature · 4 lines
   Jan-Benedict Glaw       [email protected]    . +49-172-7608481
   "Eine Freie Meinung in  einem Freien Kopf    | Gegen Zensur | Gegen Krieg
    fuer einen Freien Staat voll Freier Bürger" | im Internet! |   im Irak!
   ret = do_actions((curr | FREE_SPEECH) & ~(NEW_COPYRIGHT_LAW | DRM | TCPA));
#4 lore raw
Quoted 1 line · Jan-Benedict Glaw
Quoted 1 line

pc = [<fffffc00004eecf0>] ra = [<fffffc00004eecc8>] ps = 0000 Not tainted

           ^-- takara_swizzle + 0x74
Quoted 1 line
Quoted 1 line

Trace:fffffc0000310124 fffffc00003151e8

          ^-- init + 0x24  ^-- kernel_thread + 0x28
Quoted 1 line

Decode the oops. That'll exactly tell where it happened.

Okkay, so takara_swizzle looks like it's hiccuping. Based on this, I suspect it's the same failure in the 2.4.x kernels I've tried...I'll verify that a little later.

Now, for a little source code digging...

#5 lore raw
Quoted 3 lines · Jay Maynard

Okkay, so takara_swizzle looks like it's hiccuping. Based on this, I suspect it's the same failure in the 2.4.x kernels I've tried...I'll verify that a little later.

Yes, it's the same failure in the 2.4 kernels.

Quoted 1 line

Now, for a little source code digging...

It appears that the problem is in this line of code:

        unsigned int busslot = PCI_SLOT(dev->bus->self->devfn);

The pointer dev->bus->self is zero. I added the following line to the beginning of takara_swizzle:

        if (!dev->bus->self)
                printk(KERN_CRIT "takara_swizzle: null dev->bus->self "
                                        "pointer, bus number %d!\n",
                                        dev->bus->number);

and got the following at boot time:

Linux version 2.6.0 (root@romy) (gcc version 3.3.2 (Debian)) #1 Fri Feb 9 17:40:17 CST 2024
Booting on Takara using machine vector Takara from SRM
Major Options: EV56 LEGACY_START VERBOSE_MCHECK MAGIC_SYSRQ
Command line: ro root=/dev/sdb2 console=ttyS0
memcluster 0, usage 1, start 0, end 159
memcluster 1, usage 0, start 159, end 32651
memcluster 2, usage 1, start 32651, end 32768
freeing pages 159:384
freeing pages 849:32651
reserving pages 849:850
pci: cia revision 2
On node 0 totalpages: 32651
DMA zone: 32651 pages, LIFO batch:7
Normal zone: 0 pages, LIFO batch:1
HighMem zone: 0 pages, LIFO batch:1
Building zonelist for node : 0
Kernel command line: ro root=/dev/sdb2 console=ttyS0
PID hash table entries: 1024 (order 10: 16384 bytes)
Using epoch = 1980
Console: colour VGA+ 80x25
Memory: 253232k/261208k available (2115k kernel code, 6392k reserved, 374k data, 376k init) Calibrating delay loop... 994.44 BogoMIPS
Dentry cache hash table entries: 32768 (order: 5, 262144 bytes)
Inode-cache hash table entries: 16384 (order: 4, 131072 bytes)
Mount-cache hash table entries: 512 (order: 0, 8192 bytes)
POSIX conformance testing by UNIFIX
NET: Registered protocol family 16
pci: passed tb register update test
pci: passed sg loopback i/o read test
pci: passed tbia test
pci: passed pte write cache snoop test
pci: failed valid tag invalid pte reload test (mcheck; workaround available)
pci: passed pci machine check test
pci: enabling save/restore of SRM state
PCI: Bus 1, bridge: 0000:00:13.0
IO window: disabled.
MEM window: disabled.
PREFETCH window: disabled.
PCI: Bus 2, bridge: 0000:00:14.0
IO window: 8000-8fff
MEM window: 02200000-022fffff
PREFETCH window: 02300000-023fffff
PCI: Setting latency timer of device 0000:00:13.0 to 64
takara_swizzle: null dev->bus->self pointer, bus number 0!

Unable to handle kernel paging request at virtual address 0000000000000040
swapper(1): Oops 0
pc = [<fffffc000059bf50>]  ra = [<fffffc000059bf34>]  ps = 0000    Not tainted
v0 = 000000000513b280  t0 = 0000000000000010  t1 = fffffc00005f8680
t2 = 0000000000000000  t3 = 0000000000000000  t4 = ffffffff00000000
t5 = 0000000000000001  t6 = fffffffffffe07f2  t7 = fffffc000015c000
s0 = fffffc000fef9000  s1 = 0000000000000001  s2 = fffffc000015fe18
s3 = 0000000000000007  s4 = fffffc0000538680  s5 = fffffc0000538680
s6 = 0000000000000008
a0 = fffffc858000a000  a1 = 00000000000007f2  a2 = ffffffffffffffff
a3 = 000000000000000a  a4 = fffffffffffffffb  a5 = 0000000000000000
t8 = 0000000000000000  t9 = fffffc000060a060  t10= 0000000000000000
t11= 000000000000000a  pv = fffffc00003f95e0  at = 0000000000000000
gp = fffffc0000658680  sp = fffffc000015fdc8
Trace:fffffc0000310144 fffffc0000313268
Code: a4290020  23bdc74c  43e00000  a4810038  28610078  203f0010 <a0440040> 43e303a3
Kernel panic: Attempted to kill init!

The addresses map to:
fffffc0000310144 = init+0x24
fffffc0000313268 = kernel_thread+0x28
fffffc000059bf50 = takara_swizzle+0x80

Any guesses as to why that pointer's null when it shouldn't be?

#6 lore raw
In reply to Jay Maynard

Hi

Which compiler (gcc) do you use? Try gcc 3.3.2. But i think this is a problem in the bridging code for the takara. You should check the program counter (PC/ IP) against your System.map to find the function in which the trap occurs.
However some older kernel from debian, rh or suse should work at least - i hope.

Quoted 26 lines · Jay Maynard
Quoted 8 lines
Quoted 5 lines

install. I've tried installing a Debian system, then a 2.4 kernel on top of that - but 2.4.18 and 2.4.24 prebuilt generic kernels, as well as a 2.4.24 custom kernel built specifically for the Takara, all blow up with a kernel paging error during startup, right after the PCI bridges are detected. The 2.2.20 kernel iinstalled by Debian runs fine.

I remember there were problems with the PCI bridging code. Maybe you'd try to give 2.6.x a shot...

No luck, although I got a little better look at the error messages. I've retyped them here:

PCI: Bus 2, bridge: 0000:00:14.0
IO window: 8000-8fff
MEM window: 02400000-037fffff
PREFETCH window: 02200000-022fffff
PCI: Setting latency timer of device 0000:00:13.0 to 64

Unable to handle kernel paging request at virtual address 0000000000000040

swapper(1): Oops 0
pc = [<fffffc00004eecf0>] ra = [<fffffc00004eecc8>] ps = 0000 Not tainted
[register dump here]
Trace:fffffc0000310124 fffffc00003151e8

Code: 261dfff1 401f0000 a4410038 2c810078 20210078 22107a7c <a0420040>
488100c4
Kernel panic: Attempted to kill init!
Signature · 5 lines
Tom

LINUX user since kernel 0.99.x 1994.
RPM Alpha packages at http://alpha.steudten.com/packages
Want to know what S.u.S.E 1995 cdrom-set contains?