<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/arch/s390/include/asm/pgtable.h, branch linux-6.15.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.15.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-6.15.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2025-03-18T16:13:05Z</updated>
<entry>
<title>s390: Remove 2k vs 4k page table leftovers</title>
<updated>2025-03-18T16:13:05Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2025-03-10T11:43:00Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=174cb82a5761f15f2c469672452b720d9f51cbd7'/>
<id>urn:sha1:174cb82a5761f15f2c469672452b720d9f51cbd7</id>
<content type='text'>
Since commit d08d4e7cd6bf ("s390/mm: use full 4KB page for 2KB PTE") always
4k page tables are allocated, however there is still some (now) obsolete
code left which deals with switching from 2k to 4k page tables for qemu/kvm
processes.

Reviewed-by: Alexander Gordeev &lt;agordeev@linux.ibm.com&gt;
Remove the not needed code.

Signed-off-by: Heiko Carstens &lt;hca@linux.ibm.com&gt;
Signed-off-by: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'strict-mm-typechecks-support' into features</title>
<updated>2025-03-11T14:29:44Z</updated>
<author>
<name>Vasily Gorbik</name>
</author>
<published>2025-03-11T14:29:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5983ab168475e609a92669b6d6ca5e145a9ce5db'/>
<id>urn:sha1:5983ab168475e609a92669b6d6ca5e145a9ce5db</id>
<content type='text'>
Heiko writes:

"The recent large kernel Rust thread where Linus commented about that
structures may be returned in registers [1] made me again aware that this
is not true for s390 where the ABI defines that structures are returned in
a return value buffer allocated by the caller. This was also mentioned by
Alexander Gordeev a couple of weeks ago.

In theory the -freg-struct-return compiler flag would allow to return small
structures in registers, however that has not been implemented for
s390. Juergen Christ did an experimental gcc implementation which shows the
benefit of such a change (bloat-o-meter):

add/remove: 3/2 grow/shrink: 12/441 up/down: 740/-7182 (-6442)

This result is not very impressive, and doesn't seem to justify a new ABI
for the kernel.

However there is still the existing STRICT_MM_TYPECHECKS which can be used
to change some mm types from structures to simple scalar types. Changing
the mm types results in:

add/remove: 2/8 grow/shrink: 25/116 up/down: 3902/-6204 (-2302)

Which is already a third of the possible savings which would be the result
of the described ABI change.

Therefore add support for a configurable STRICT_MM_TYPECHECKS which allows
to generate better code, but also allows to have type checking for debug
builds."

[1] https://lore.kernel.org/all/CAHk-=wgb1g9VVHRaAnJjrfRFWAOVT2ouNOMqt0js8h3D6zvHDw@mail.gmail.com/

* strict-mm-typechecks-support:
  s390/mm: Add configurable STRICT_MM_TYPECHECKS
  s390/mm: Convert pgste_val() into function
  s390/mm: Convert pgprot_val() into function
  s390/mm: Use pgprot_val() instead of open coding

Signed-off-by: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390: Remove ioremap_wt() and pgprot_writethrough()</title>
<updated>2025-03-11T14:28:58Z</updated>
<author>
<name>Niklas Schnelle</name>
</author>
<published>2025-02-21T11:51:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c94bff63e49302d4ce36502a85a2710a67332a4f'/>
<id>urn:sha1:c94bff63e49302d4ce36502a85a2710a67332a4f</id>
<content type='text'>
It turns out that while s390 architecture calls its memory-I/O mapping
variants write-through and write-back the implementation of ioremap_wt()
and pgprot_writethrough() does not match Linux notion of ioremap_wt().

In particular Linux expects ioremap_wt() to be weaker still than
ioremap_wc(), allowing not just gathering and re-ordering but also reads
to be served from cache. Instead s390's implementation is equivalent to
normal ioremap() while its ioremap_wc() allows re-ordering.

Note that there are no known users of ioremap_wt() on s390 and the
resulting behavior is in line with asm-generic defining ioremap_wt() as
ioremap(), if undefined, so no breakage is expected.

As s390 does not have a mapping type matching the Linux notion of
ioremap_wt() and pgprot_writethrough(), simply drop them and rely on the
asm-generic fallbacks instead.

Fixes: b02002cc4c0f ("s390/pci: Implement ioremap_wc/prot() with MIO")
Fixes: b43b3fff042d ("s390: mm: convert to GENERIC_IOREMAP")
Acked-by: Heiko Carstens &lt;hca@linux.ibm.com&gt;
Signed-off-by: Niklas Schnelle &lt;schnelle@linux.ibm.com&gt;
Signed-off-by: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm: Convert pgste_val() into function</title>
<updated>2025-03-11T14:27:34Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2025-03-04T08:14:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=94d553ce576acc5f01f4368bc5188f45b56b6168'/>
<id>urn:sha1:94d553ce576acc5f01f4368bc5188f45b56b6168</id>
<content type='text'>
Similar to all other *_val() functions convert the last remaining
architecture specific mm primitive pgste_val() into a function.

Add set_pgste_bit() and clear_pgste_bit() helper functions which allow to
clear and set pgste bits. This is also similar to e.g. set_pte_bit() and
other helper functions.

Acked-by: Alexander Gordeev &lt;agordeev@linux.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;hca@linux.ibm.com&gt;
Signed-off-by: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/cpufeature: Convert MACHINE_HAS_EDAT1 to cpu_has_edat1()</title>
<updated>2025-03-04T16:18:05Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2025-02-07T14:48:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2e2ff71febfe30963deff1897b7d1d1ceb8628dd'/>
<id>urn:sha1:2e2ff71febfe30963deff1897b7d1d1ceb8628dd</id>
<content type='text'>
Convert MACHINE_HAS_... to cpu_has_...() which uses test_facility() instead
of testing the machine_flags lowcore member if the feature is present.

test_facility() generates better code since it results in a static branch
without accessing memory. The branch is patched via alternatives by the
decompressor depending on the availability of the required facility.

Reviewed-by: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;hca@linux.ibm.com&gt;
Signed-off-by: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/cpufeature: Convert MACHINE_HAS_RDP to cpu_has_rdp()</title>
<updated>2025-03-04T16:18:04Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2025-02-07T14:48:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=15a36036e792f4eec0fc59833dde688024e036fc'/>
<id>urn:sha1:15a36036e792f4eec0fc59833dde688024e036fc</id>
<content type='text'>
Convert MACHINE_HAS_... to cpu_has_...() which uses test_facility() instead
of testing the machine_flags lowcore member if the feature is present.

test_facility() generates better code since it results in a static branch
without accessing memory. The branch is patched via alternatives by the
decompressor depending on the availability of the required facility.

Reviewed-by: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;hca@linux.ibm.com&gt;
Signed-off-by: Vasily Gorbik &lt;gor@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>KVM: s390: remove the last user of page-&gt;index</title>
<updated>2025-01-31T11:03:53Z</updated>
<author>
<name>Claudio Imbrenda</name>
</author>
<published>2025-01-23T14:46:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=84b7387692a8c849bd8bddd0f5c5474d4923aa6e'/>
<id>urn:sha1:84b7387692a8c849bd8bddd0f5c5474d4923aa6e</id>
<content type='text'>
Shadow page tables use page-&gt;index to keep the g2 address of the guest
page table being shadowed.

Instead of keeping the information in page-&gt;index, split the address
and smear it over the 16-bit softbits areas of 4 PGSTEs.

This removes the last s390 user of page-&gt;index.

Reviewed-by: Steffen Eiden &lt;seiden@linux.ibm.com&gt;
Reviewed-by: Christoph Schlameuss &lt;schlameuss@linux.ibm.com&gt;
Link: https://lore.kernel.org/r/20250123144627.312456-16-imbrenda@linux.ibm.com
Signed-off-by: Claudio Imbrenda &lt;imbrenda@linux.ibm.com&gt;
Message-ID: &lt;20250123144627.312456-16-imbrenda@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>KVM: s390: move PGSTE softbits</title>
<updated>2025-01-31T11:03:53Z</updated>
<author>
<name>Claudio Imbrenda</name>
</author>
<published>2025-01-23T14:46:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1f4389931e9fea7e8b3c1f189d505b040b25be8a'/>
<id>urn:sha1:1f4389931e9fea7e8b3c1f189d505b040b25be8a</id>
<content type='text'>
Move the softbits in the PGSTEs to the other usable area.

This leaves the 16-bit block of usable bits free, which will be used in the
next patch for something else.

Reviewed-by: Steffen Eiden &lt;seiden@linux.ibm.com&gt;
Reviewed-by: Christoph Schlameuss &lt;schlameuss@linux.ibm.com&gt;
Link: https://lore.kernel.org/r/20250123144627.312456-15-imbrenda@linux.ibm.com
Signed-off-by: Claudio Imbrenda &lt;imbrenda@linux.ibm.com&gt;
Message-ID: &lt;20250123144627.312456-15-imbrenda@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm: Simplify noexec page protection handling</title>
<updated>2024-12-17T11:46:13Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2024-12-09T09:45:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=f8107a8be0b2e92798ded4aff45e3a94b763ce61'/>
<id>urn:sha1:f8107a8be0b2e92798ded4aff45e3a94b763ce61</id>
<content type='text'>
By default page protection definitions like PAGE_RX have the _PAGE_NOEXEC
bit set. For older machines without the instruction execution protection
facility this bit is not allowed to be used in page table entries, and
therefore must be removed.

This is done at a couple of page table walkers, but also at some but not
all page table modification functions like ptep_modify_prot_commit(). Avoid
all of this and change the page, segment and region3 protection definitions
so that the noexec bit is masked out automatically if the instruction
execution-protection facility is not available. This is similar to what
also various other architectures do which had to solve the same problem.

Reviewed-by: Gerald Schaefer &lt;gerald.schaefer@linux.ibm.com&gt;
Acked-by: Alexander Gordeev &lt;agordeev@linux.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;hca@linux.ibm.com&gt;
Signed-off-by: Alexander Gordeev &lt;agordeev@linux.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/mm: Remove unused PAGE_KERNEL_EXEC and friends</title>
<updated>2024-12-17T11:46:13Z</updated>
<author>
<name>Heiko Carstens</name>
</author>
<published>2024-12-09T09:45:17Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=db449b147cef0a210c61dc8840424456fbe45cc8'/>
<id>urn:sha1:db449b147cef0a210c61dc8840424456fbe45cc8</id>
<content type='text'>
Remove unused PAGE_KERNEL_EXEC, SEGMENT_KERNEL_EXEC,
and REGION3_KERNEL_EXEC.

Reviewed-by: Gerald Schaefer &lt;gerald.schaefer@linux.ibm.com&gt;
Acked-by: Alexander Gordeev &lt;agordeev@linux.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;hca@linux.ibm.com&gt;
Signed-off-by: Alexander Gordeev &lt;agordeev@linux.ibm.com&gt;
</content>
</entry>
</feed>
