2.6 4xx GPIO OCP driver?

Matt Porter mporter at kernel.crashing.org
Sat Feb 26 11:29:41 EST 2005


On Fri, Feb 25, 2005 at 04:19:41PM -0500, Ralph Siemsen wrote:
> Matt Porter wrote:
> 
> > I didn't bother merging it upstream at one time. It wasn't clear
> > if the driver had any value over just mmaping /dev/mem to bang
> > on the couple gpio registers directly. [...]
> 
> Will that work on the 440 where the devices sit above 4GB mark?  Or must 
> one rely on there being an existing TLB mapping to bring them into 
> 32-bit space?

Ack...that's the one thing we are missing. :-/ I had forgotten
that driver/char/mem.c  calls remap_pfn_range() directly rather
than io_remap_page_range(). Had it called the latter, we'd be OK
since the "bigphys" fixup could take place.  We can fix /dev/mem to
call io_remap_page_range() when on ppc32 && 36-bit phys...other arches
do similar tricks in that driver.

If everybody is happy with mmaping /dev/mem then we can go try that
route.

-Matt



More information about the Linuxppc-embedded mailing list