[Top] [All Lists]

Re: MIPS ioport_map and Au1xxx PCMCIA

To: Manuel Lauss <>
Subject: Re: MIPS ioport_map and Au1xxx PCMCIA
From: Alan Cox <>
Date: Thu, 26 Apr 2007 16:55:25 +0100
In-reply-to: <>
Original-recipient: rfc822;
References: <>
On Thu, 26 Apr 2007 11:35:15 +0200
Manuel Lauss <> wrote:

> Hello,
> the file arch/mips/lib/iomap.c contains this define
> #define PIO_MASK 0x0ffffUL
> which prevents pata_pcmcia with the new devres stuff
> from attaching to a CF card. (on my Au1200).
> The ports-to-be-iomap()'ed are in the 0xc0000000 range
> and the ioport_map() function rejects all attempts
> of pata_pcmcia to devm_ioport_map() them.
> What is this mask used for and can it be removed?

iomap uses PIO_MASK to idenfiy ports within the I/O space range. The mips
code looks somewhat incomplete in the base kernel which is probably much
of the problem.

The basic idea is that ioread/iowrite and friends work generically
regardless of MMIO v PIO so you can just do

        pci_iomap(some bar);

and not worry about anything.

Now if your platform doesn't have seperate IO space you could probably
implement iowrite/ioremap/ioport_map to be pretty much no-ops depending
upon how your PCI bars are encoded.


<Prev in Thread] Current Thread [Next in Thread>