<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/arch/s390/mm, branch linux-3.7.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.7.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.7.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2012-11-13T10:02:28Z</updated>
<entry>
<title>s390/gup: fix access_ok() usage in __get_user_pages_fast()</title>
<updated>2012-11-13T10:02:28Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-22T13:58:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=516bad44b9f3bdcb0be6be0252b7557bf7a149e4'/>
<id>urn:sha1:516bad44b9f3bdcb0be6be0252b7557bf7a149e4</id>
<content type='text'>
access_ok() returns always "true" on s390. Therefore all access_ok()
invocations are rather pointless.
However when walking page tables we need to make sure that everything
is within bounds of the ASCE limit of the task's address space.
So remove the access_ok() call and add the same check we have in
get_user_pages_fast().

Reviewed-by: Gerald Schaefer &lt;gerald.schaefer@de.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/gup: add missing TASK_SIZE check to get_user_pages_fast()</title>
<updated>2012-11-13T10:02:26Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-22T13:49:02Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d55c4c613fc4d4ad2ba0fc6fa2b57176d420f7e4'/>
<id>urn:sha1:d55c4c613fc4d4ad2ba0fc6fa2b57176d420f7e4</id>
<content type='text'>
When walking page tables we need to make sure that everything
is within bounds of the ASCE limit of the task's address space.
Otherwise we might calculate e.g. a pud pointer which is not
within a pud and dereference it.
So check against TASK_SIZE (which is the ASCE limit) before
walking page tables.

Reviewed-by: Gerald Schaefer &lt;gerald.schaefer@de.ibm.com&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm: use pmd_large() instead of pmd_huge()</title>
<updated>2012-10-26T14:44:23Z</updated>
<author>
<name>Gerald Schaefer</name>
</author>
<published>2012-10-25T15:24:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=156152f84e57bff4d9b5d70be6f3f16116bf6fb1'/>
<id>urn:sha1:156152f84e57bff4d9b5d70be6f3f16116bf6fb1</id>
<content type='text'>
Without CONFIG_HUGETLB_PAGE, pmd_huge() will always return 0. So
pmd_large() should be used instead in places where both transparent
huge pages and hugetlbfs pages can occur.

Signed-off-by: Gerald Schaefer &lt;gerald.schaefer@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm,vmem: fix vmem_add_mem()/vmem_remove_range()</title>
<updated>2012-10-09T12:17:01Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-08T05:54:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=fc7e48aad35bf98c84cf21aed5c2f100c5ce009b'/>
<id>urn:sha1:fc7e48aad35bf98c84cf21aed5c2f100c5ce009b</id>
<content type='text'>
vmem_add_mem() should only then insert a large page if pmd_none() is true
for the specific entry. We might have a leftover from a previous mapping.
In addition make vmem_remove_range()'s page table walk code more complete
and fix a couple of potential endless loops (which can never happen :).

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/vmalloc: have separate modules area</title>
<updated>2012-10-09T12:17:01Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-05T14:52:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c972cc60c23f5a6309292bfcc91a441743ba027e'/>
<id>urn:sha1:c972cc60c23f5a6309292bfcc91a441743ba027e</id>
<content type='text'>
Add a special module area on top of the vmalloc area, which may be only
used for modules and bpf jit generated code.
This makes sure that inter module branches will always happen without a
trampoline and in addition having all the code within a 2GB frame is
branch prediction unit friendly.

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm: fix mapping of read-only kernel text section</title>
<updated>2012-10-09T12:16:59Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-04T15:02:02Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8fe234d3c8d66771b327accb8eef26f70a8a8db8'/>
<id>urn:sha1:8fe234d3c8d66771b327accb8eef26f70a8a8db8</id>
<content type='text'>
Within the identity mapping the kernel text section is mapped read-only.
However when mapping the first and last page of the text section we must
round upwards and downwards respectively, if only parts of a page belong
to the section.
Otherwise potential rw data can be mapped read-only. So the rounding must
be done just the other way we have it right now.

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm: add page table dumper</title>
<updated>2012-10-09T12:16:58Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-04T12:46:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e76e82d772522b05ed93228478d2a4460754b6a4'/>
<id>urn:sha1:e76e82d772522b05ed93228478d2a4460754b6a4</id>
<content type='text'>
This is more or less the same as the x86 page table dumper which was
merged four years ago: 926e5392 "x86: add code to dump the (kernel)
page tables for visual inspection by kernel developers".

We add a file at /sys/kernel/debug/kernel_page_tables for debugging
purposes so it's quite easy to see the kernel page table layout and
possible odd mappings:

---[ Identity Mapping ]---
0x0000000000000000-0x0000000000100000        1M PTE RW
---[ Kernel Image Start ]---
0x0000000000100000-0x0000000000800000        7M PMD RO
0x0000000000800000-0x00000000008a9000      676K PTE RO
0x00000000008a9000-0x0000000000900000      348K PTE RW
0x0000000000900000-0x0000000001500000       12M PMD RW
---[ Kernel Image End ]---
0x0000000001500000-0x0000000280000000    10219M PMD RW
0x0000000280000000-0x000003d280000000     3904G PUD I
---[ vmemmap Area ]---
0x000003d280000000-0x000003d288c00000      140M PTE RW
0x000003d288c00000-0x000003d300000000     1908M PMD I
0x000003d300000000-0x000003e000000000       52G PUD I
---[ vmalloc Area ]---
0x000003e000000000-0x000003e000009000       36K PTE RW
0x000003e000009000-0x000003e0000ee000      916K PTE I
0x000003e0000ee000-0x000003e000146000      352K PTE RW
0x000003e000146000-0x000003e000200000      744K PTE I
0x000003e000200000-0x000003e080000000     2046M PMD I
0x000003e080000000-0x0000040000000000      126G PUD I

This usually makes only sense for kernel developers. The output
with CONFIG_DEBUG_PAGEALLOC is not very helpful, because of the
huge number of mapped out pages, however I decided for the time
being to not add a !DEBUG_PAGEALLOC dependency.
Maybe it's helpful for somebody even with that option.

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm,pageattr: remove superfluous EXPORT_SYMBOLs</title>
<updated>2012-10-09T12:16:57Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-01T14:46:12Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=cc5b9a45184e90037e6d5353279ec358e57965fd'/>
<id>urn:sha1:cc5b9a45184e90037e6d5353279ec358e57965fd</id>
<content type='text'>
Remove some EXPORT_SYMBOLs. There is no module code anywhere
which calls these pageattr functions.

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm,pageattr: add more page table walk sanity checks</title>
<updated>2012-10-09T12:16:57Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-01T14:18:46Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5b1ba9e30cf0e259450da19189811eb140733f83'/>
<id>urn:sha1:5b1ba9e30cf0e259450da19189811eb140733f83</id>
<content type='text'>
The current page table walk code in pageattr.c only checks for large pages
while walking the kernel page table, but happily assumes that everything
else is just fine.
Add more checks so we never access invalid memory regions.

Reviewed-by: Gerald Schaefer &lt;gerald.schaefer@de.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm: fix pmd_huge() usage for kernel mapping</title>
<updated>2012-10-09T12:16:56Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2012-10-01T10:58:34Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=378b1e7a80a59325ca1036e892462db728126f84'/>
<id>urn:sha1:378b1e7a80a59325ca1036e892462db728126f84</id>
<content type='text'>
pmd_huge() will always return 0 on !HUGETLBFS, however we use that helper
function when walking the kernel page tables to decide if we have a
1MB page frame or not.
Since we create 1MB frames for the kernel 1:1 mapping independently of
HUGETLBFS this can lead to incorrect storage accesses since the code
can assume that we have a pointer to a page table instead of a pointer
to a 1MB frame.

Fix this by adding a pmd_large() primitive like other architectures have
it already and remove all references to HUGETLBFS/HUGETLBPAGE from the
code that walks kernel page tables.

Reviewed-by: Gerald Schaefer &lt;gerald.schaefer@de.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
</feed>
