public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: <paulus@samba.org>, <linux-kernel@vger.kernel.org>
Subject: Re: isa_read/write not available on ppc - solution suggestions ??
Date: Wed, 2 May 2001 21:28:40 +0200	[thread overview]
Message-ID: <20010502192840.23233@smtp.wanadoo.fr> (raw)
In-Reply-To: <15087.23739.557487.505172@argo.ozlabs.ibm.com.au>
In-Reply-To: <15087.23739.557487.505172@argo.ozlabs.ibm.com.au>

>> I would suggest the opposite approach instead: make the PPC just support
>> isa_readx/isa_writex instead.
>
>We can certainly do that, no problem.
>
>BUT that won't get a token ring pcmcia card working in the newer
>powerbooks, such as the titanium G4 powerbook, because the PCI host
>bridge doesn't map any cpu addresses to the bottom 16MB of PCI memory
>space.  This is not a problem as far as pcmcia cards are concerned -
>the pcmcia stuff just picks an appropriate address (typically in the
>range 0x90000000 - 0x9fffffff) and sets the pcmcia/cardbus bridge to
>map that to the card.  But it means that the physical addresses for
>the card's memory space will be above the 16MB point, so it is
>essential to do the ioremap.

What about isa_ioremap ? Result from it is a token passed to
isa_readx/isa_writex and the arch side can be implemented with a
couple of #defines on x86. 

It's easy to change I beleive, and it paves the way for archs to
add a notion of "token" in the high bits (as we _know_ an ISA address
is small). Those token can be used by arch to route to proper PCI
bus when several host bridges exist, to route to PCMCIA when the
PCMCIA uses it's own "ISA" memory space like on PPC, etc...

Later on, we can see things like

ulong pci_get_bus_isa_base(int busno);

And the same for PCMCIA & whatever 16 bits busses that can exist on
embedded hardware.

That way, support for multiple busses (either real ISA, embedded custom
busses using legacy devices, several PCI hosts with ISA bridges, ...)
can be implemented very easily. In most case adjusting the drivers
probe code.

I'd like to see the same kind of things for IOs in fact but that's
another debate ;)

Regards,
Ben.


  reply	other threads:[~2001-05-02 19:30 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-05-01 15:27 isa_read/write not available on ppc - solution suggestions ?? mike_phillips
2001-05-01 17:22 ` Linus Torvalds
2001-05-01 19:45   ` Russell King
2001-05-01 21:19     ` Linus Torvalds
2001-05-01 21:31       ` Russell King
2001-05-01 22:46         ` Linus Torvalds
2001-05-02 15:10           ` Jonathan Lundell
2001-05-02  1:02   ` Paul Mackerras
2001-05-02 19:28     ` Benjamin Herrenschmidt [this message]
2001-05-02  7:26   ` Geert Uytterhoeven
  -- strict thread matches above, loose matches on Subject: below --
2001-05-02 13:12 mike_phillips
2001-05-03 11:08 ` Anton Blanchard
2001-05-01 17:41 mike_phillips
2001-05-01 13:52 mike_phillips
2001-05-01  4:32 ` Arnaldo Carvalho de Melo
2001-05-01 14:35 ` Alan Cox
2001-05-01 14:50   ` Brian Gerst
2001-05-01 15:14     ` Alan Cox
2001-05-01 14:36 ` Brian Gerst
2001-05-01 17:33 ` Geert Uytterhoeven

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20010502192840.23233@smtp.wanadoo.fr \
    --to=benh@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=paulus@samba.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox