PXA2xx pcmcia to compact flash on 2.6.13

Russell King rmk+pcmcia at arm.linux.org.uk
Fri Dec 16 08:07:18 EST 2005


On Fri, Dec 16, 2005 at 04:58:13AM -0800, John Heil wrote:
> On Fri, 16 Dec 2005, Russell King wrote:
> > On Thu, Dec 15, 2005 at 10:30:16PM -0800, John Heil wrote:
> > > My concern is that the PXA270 hardware PCMCIA area, at 0x20000000,
> > > may not be correctly ioremapped by cs/ds to find where the CIS is being
> > > returned at.
> >
> > It strikes me that it would be far simpler if you were to use the PXA
> > support already present in the kernel, and maybe just hard-wire the
> > card detect support to say "Card Present".
> 
> I do want to use the existing PXA kernel support.
> My target driver is ide-cs. Getting PXA PCMCIA support to invoke it
> is what I'm trying to do...

> 
> The board I've got differs from the reference design in that they
> exchanged Intel's FPGA for a dumbed down CPLD w/o hotplug and w/o
> the controlling registers Intel had in their FPGA. Thus PCMCIA card
> variables such as voltage  etc are fixed.

Take a look at pxa2xx_mainstone.c.

1. Create a copy of it.
2. Rename the functions to have appropriate names for your platform.
3. Remove the code which configures the socket voltages.
4. Remove the code which claims interrupts for card detection and
   status change.
5. Remove the code in the socket_state method, and hard code
   state->detect to 1.  Read the remainder from the hardware, or
   hard code them to a sensible state if you can't.

-- 
Russell King
 Linux kernel    2.6 ARM Linux   - http://www.arm.linux.org.uk/
 maintainer of:  2.6 Serial core



More information about the linux-pcmcia mailing list