Audigy SE / ca0106 driver for PowerPC?

Kumar Gala galak at kernel.crashing.org
Thu Feb 1 08:55:04 EST 2007


On Jan 31, 2007, at 3:00 PM, Russell McGuire wrote:

> I am using the Freescale MPC8360E, with U-boot 1.2.0.
> When I compile the kernel <2.6.20-rc6> I select the MPC8360E-MDS  
> board.
> ARCH = PowerPC.
>
> Well I might be all confused on the IO Remap, but if I look through  
> the
> nvidafb driver and the ati frame buffer driver I can see the
> resource_start() and pci_resource_len() function being called,  
> followed by
> the ioremap() before any configuration is done with the PCI boards.

The difference is the nvidafb driver isn't doing PCI IO but PCI mem  
accesses (note, I didn't see any inl/outl references in the nvida  
driver).

> The ca0106 driver seems to miss this <ioremap> function, and it is  
> the only
> one that 100% locks the system up during the PCI probing <that I have
> tried>, and it happens after/during the very first inl() or outl()  
> command.

This may be because IO space is setup properly.

When you say locks the system, what exactly happens?

> I read a thread someplace that says that pci_resource_start() is not
> intended to return an actual address, but rather a token that is to  
> be used
> by the ioremap() function? It just happens that on some systems  
> this value
> is the same and so for some it will not fail with a missing ioremap 
> (), but
> others it will not be. To be safe it must be passed through ioremap 
> ()? This
> is the deprecated part, <right term? Perhaps just bad assumption is  
> a better
> one> that this driver makes.
>
> After looking through more drivers, this ioremap seems 100% in  
> place on my
> drivers. Maybe nobody has tested this with PowerPC in the past?

ioremap() is intended for use with PCI MEM accesses not PCI IO.  If  
you think about the fact that PCI IO is based on the x86 port IO  
concept this makes sense.

> See this thread as an example:
> http://linux.derkeiler.com/Mailing-Lists/Kernel/2003-09/1187.html
>
> Or see:
> /drivers/video/nvidia/nvidia.c lines 1239->1243
>
> Verses
>
> /sound/pci/ca0106/ca0106_main.c
> lines 1279 till the interrupt request
> then lines 1069->1089 at which it locks on inl()
>
> I don't mean to argue, I am just confused at this point.

Its ok.  I don't thinking you're arguing, just trying to figure out  
what's going on.

- k



More information about the Linuxppc-embedded mailing list