Re: [patch 09/10] Hugetlb common code update for System z.

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Gerald Schaefer
Date: Wednesday, March 12, 2008 - 4:18 pm

On Wed, 2008-03-12 at 10:51 -0700, Dave Hansen wrote:

There are already several ARCH_HAS_xxx defines which are being used in
inlude/linux/hugetlb.h. All of them are defined in
include/asm-<arch>/page.h for every architecture that needs them (with
the exception of powerpc, where it is include/asm-powerpc/page_64.h).
So there is already one place to look for them, and so we put our
defines into include/asm-s390/page.h.


Other architectures should not be affected at all. Because of the
#ifdef, the new ptep functions are either a nop for them or just the
same as they were before our patch.


Large ptes are not really ptes but segment table entries (pmd entries),
in our case. This is similar to other architectures with hardware large
page support, because there simply is no page table level (and thus no
ptes) anymore. Unfortunately, the hugetlbfs common code does not
consider that discrepancy and just uses a standard pte_t and standard
pte functions, probably because it did not really make a difference on
other architectures.

On s390, a segment table entry (pmd) type is different from a pte type
mainly in the location of its invalid bit. This means that we cannot
use pte_none(), pte_wrprotect() and similar functions for large ptes,
which was the reason for the new huge_pte functions that we introduced.

--
Gerald Schaefer

--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[patch 09/10] Hugetlb common code update for System z., Martin Schwidefsky, (Wed Mar 12, 10:32 am)
Re: [patch 09/10] Hugetlb common code update for System z., Gerald Schaefer, (Wed Mar 12, 4:18 pm)
Re: [patch 09/10] Hugetlb common code update for System z., Gerald Schaefer, (Thu Mar 13, 10:49 am)
Re: [patch 09/10] Hugetlb common code update for System z., Gerald Schaefer, (Fri Mar 28, 7:05 am)
Re: [patch 09/10] Hugetlb common code update for System z., Gerald Schaefer, (Fri Mar 28, 7:33 am)
Re: [patch 09/10] Hugetlb common code update for System z., Martin Schwidefsky, (Fri Mar 28, 8:53 am)