Re: about kmap_high function

Stephen C. Tweedie (sct@redhat.com)
Tue, 3 Jul 2001 16:34:18 +0100


Hi,

On Tue, Jul 03, 2001 at 10:47:20PM +1000, Paul Mackerras wrote:
> Stephen C. Tweedie writes:
>
> On PPC it is a bit different. Flushing a single TLB entry is
> relatively cheap - the hardware broadcasts the TLB invalidation on the
> bus (in most implementations) so there are no cross-calls required. But
> flushing the whole TLB is expensive because we (strictly speaking)
> have to flush the whole of the MMU hash table as well.

How much difference is there? We only flush once per kmap sweep, and
we have 1024 entries in the global kmap pool, so the single tlb flush
would have to be more than a thousand times less expensive overall
than the global flush for that change to be worthwhile.

If the page flush really is _that_ much faster, then sure, this
decision can easily be made per-architecture: the kmap_high code
already has all of the locking and refcounting to know when a per-page
tlb flush would be safe.

Cheers,
Stephen
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/