[OpenBIOS] sun4u interrupt-map

Tarl Neustaedter tarl-b2 at tarl.net
Thu Apr 5 23:54:50 CEST 2012


On 2012-Apr-5 17:37 , Artyom Tarasenko wrote:
> I gave the following shot:
>
> 0>  show-devs
> ffe1a2b0 /
> ( ... )
> ffe29140 /pci at 1fe,0 (pci)
> ffe299a8 /pci at 1fe,0/pci at 1 (pci)
> ffe2a060 /pci at 1fe,0/pci at 1,1 (pci)
> ffe2aeb8 /pci at 1fe,0/ebus at 3
> ffe2bb00 /pci at 1fe,0/ebus at 3/su at 0,1 (serial)
> ( ... )
>
> ok
> cd /pci at 1fe,0/ebus
> 000001fe encode-int 020003f8 encode-int encode+ 1 encode-int encode+
> ffe29140 encode-int encode+ 2b encode-int encode+ " interrupt-map" property
>
> 0000001f encode-int 00ffffff encode-int encode+ 00000003 encode-int encode+
> " interrupt-map-mask" property
>
> cd /pci at 1fe,0/ebus at 3/su
> 1 encode-int " interrupts" property
> device-end
>
> And Linux's of_device_64 interprets it the following way:
>
> /pci at 1f,0: direct translate 7f0 -->  1
> /pci at 1f,0: direct translate 7ee -->  1
> /pci at 1f,0: direct translate 7ef -->  1
> /pci at 1f,0: direct translate 7e5 -->  1
>
> ^^^^^ This is strange but is the same regardless my interrupt-map try above.
>
> /pci at 1f,0/ebus at 3/su at 1fe,20003f8: Apply [/pci at 1f,0/ebus at 3:1] imap -->  [NULL:1]
>
> ^^^^^ Have I done something wrong, or more interrupt mappings  is needed?

Well, it looks like Linux is correctly identifying that you want to 
translate interrupt 1 from ebus to something else. That something else 
is where it's getting hung up - what are your #address-cells and 
#interrupt-cells?

Although I don't think you're using the right numbers.... It looks like 
you set up a property containing:

1fe, 200.03f8, 1, ffe2.9140, 2b

The two cells at the front look wrong. I think you want the contents of 
the reg property of the su node, and I'm pretty sure that doesn't have 
"1fe". I recall ebus only has a one-cell address property, in which case 
that should be:

20003f8, 1, ffe2.9140, 2b

The interrupt mask property should probably be 00ff.ffff, ff .




More information about the OpenBIOS mailing list