Subject: Re: [RFC/PATCH 1/3] powerpc: add ioremap_bat() function for setting up BAT translated IO regions.

From: Scott Wood <[email-masked]>
Date: Wed, 06 Aug 2008 17:31:41 -0500

Kumar Gala wrote:
> On Aug 6, 2008, at 4:54 PM, Grant Likely wrote:
>> I suppose we could; but the usecase is somewhat different and I
>> wanted to keep it simple.  Using a separate API also helps
>> reenforce that the caller really needs to know what they are doing
>> because BATs are a limited resource.
> 
> there is a bunch of error checking and difference in semantics that
> you need to fix.  I think introduce a new API for this is silly,

Why is it silly?  It seems silly to me to complicate ioremap() with 
knowing when to use BATs and when not to use them.

> especially since we expect there to only be one actual invocation of
> the API for serial console access.

I could also see a BAT (or equivalent) being used for IMMR-space, or
other frequently accessed registers, to save TLB entries.

-Scott