<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/arch/x86/kernel/cpu/mtrr/generic.c, branch master</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=master</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2026-02-22T01:09:51Z</updated>
<entry>
<title>Convert 'alloc_obj' family to use the new default GFP_KERNEL argument</title>
<updated>2026-02-22T01:09:51Z</updated>
<author>
<name>Linus Torvalds</name>
</author>
<published>2026-02-22T00:37:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bf4afc53b77aeaa48b5409da5c8da6bb4eff7f43'/>
<id>urn:sha1:bf4afc53b77aeaa48b5409da5c8da6bb4eff7f43</id>
<content type='text'>
This was done entirely with mindless brute force, using

    git grep -l '\&lt;k[vmz]*alloc_objs*(.*, GFP_KERNEL)' |
        xargs sed -i 's/\(alloc_objs*(.*\), GFP_KERNEL)/\1)/'

to convert the new alloc_obj() users that had a simple GFP_KERNEL
argument to just drop that argument.

Note that due to the extreme simplicity of the scripting, any slightly
more complex cases spread over multiple lines would not be triggered:
they definitely exist, but this covers the vast bulk of the cases, and
the resulting diff is also then easier to check automatically.

For the same reason the 'flex' versions will be done as a separate
conversion.

Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>treewide: Replace kmalloc with kmalloc_obj for non-scalar types</title>
<updated>2026-02-21T09:02:28Z</updated>
<author>
<name>Kees Cook</name>
</author>
<published>2026-02-21T07:49:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=69050f8d6d075dc01af7a5f2f550a8067510366f'/>
<id>urn:sha1:69050f8d6d075dc01af7a5f2f550a8067510366f</id>
<content type='text'>
This is the result of running the Coccinelle script from
scripts/coccinelle/api/kmalloc_objs.cocci. The script is designed to
avoid scalar types (which need careful case-by-case checking), and
instead replace kmalloc-family calls that allocate struct or union
object instances:

Single allocations:	kmalloc(sizeof(TYPE), ...)
are replaced with:	kmalloc_obj(TYPE, ...)

Array allocations:	kmalloc_array(COUNT, sizeof(TYPE), ...)
are replaced with:	kmalloc_objs(TYPE, COUNT, ...)

Flex array allocations:	kmalloc(struct_size(PTR, FAM, COUNT), ...)
are replaced with:	kmalloc_flex(*PTR, FAM, COUNT, ...)

(where TYPE may also be *VAR)

The resulting allocations no longer return "void *", instead returning
"TYPE *".

Signed-off-by: Kees Cook &lt;kees@kernel.org&gt;
</content>
</entry>
<entry>
<title>x86/mtrr: Drop unnecessary export of "mtrr_state"</title>
<updated>2025-11-12T23:24:42Z</updated>
<author>
<name>Sean Christopherson</name>
</author>
<published>2025-11-12T17:39:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9c26c91e103b58ba4f75f77d3d7338620b132ac4'/>
<id>urn:sha1:9c26c91e103b58ba4f75f77d3d7338620b132ac4</id>
<content type='text'>
Don't export "mtrr_state" as usage is limited to arch/x86/kernel/cpu/mtrr
(and nothing outside of that directory even includes the local mtrr.h).

No functional change intended.

Signed-off-by: Sean Christopherson &lt;seanjc@google.com&gt;
Signed-off-by: Dave Hansen &lt;dave.hansen@linux.intel.com&gt;
Link: https://patch.msgid.link/20251112173944.1380633-3-seanjc%40google.com
</content>
</entry>
<entry>
<title>x86/mtrr: Check if fixed-range MTRRs exist in mtrr_save_fixed_ranges()</title>
<updated>2025-05-12T11:04:40Z</updated>
<author>
<name>Jiaqing Zhao</name>
</author>
<published>2025-05-09T17:06:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=824c6384e8d9275d4ec7204f3f79a4ac6bc10379'/>
<id>urn:sha1:824c6384e8d9275d4ec7204f3f79a4ac6bc10379</id>
<content type='text'>
When suspending, save_processor_state() calls mtrr_save_fixed_ranges()
to save fixed-range MTRRs.

On platforms without fixed-range MTRRs like the ACRN hypervisor which
has removed fixed-range MTRR emulation, accessing these MSRs will
trigger an unchecked MSR access error. Make sure fixed-range MTRRs are
supported before access to prevent such error.

Since mtrr_state.have_fixed is only set when MTRRs are present and
enabled, checking the CPU feature flag in mtrr_save_fixed_ranges() is
unnecessary.

Fixes: 3ebad5905609 ("[PATCH] x86: Save and restore the fixed-range MTRRs of the BSP when suspending")
Signed-off-by: Jiaqing Zhao &lt;jiaqing.zhao@linux.intel.com&gt;
Signed-off-by: Borislav Petkov (AMD) &lt;bp@alien8.de&gt;
Link: https://lore.kernel.org/20250509170633.3411169-2-jiaqing.zhao@linux.intel.com
</content>
</entry>
<entry>
<title>x86/mtrr: Modify a x86_model check to an Intel VFM check</title>
<updated>2025-03-19T10:19:40Z</updated>
<author>
<name>Sohil Mehta</name>
</author>
<published>2025-02-19T18:41:22Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a8cb451458057295fa251152a0297ece5519850f'/>
<id>urn:sha1:a8cb451458057295fa251152a0297ece5519850f</id>
<content type='text'>
Simplify one of the last few Intel x86_model checks in arch/x86 by
substituting it with a VFM one.

Signed-off-by: Sohil Mehta &lt;sohil.mehta@intel.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Acked-by: Dave Hansen &lt;dave.hansen@linux.intel.com&gt;
Link: https://lore.kernel.org/r/20250219184133.816753-5-sohil.mehta@intel.com
</content>
</entry>
<entry>
<title>x86/mtrr: Use str_enabled_disabled() helper in print_mtrr_state()</title>
<updated>2025-03-19T10:17:56Z</updated>
<author>
<name>Thorsten Blum</name>
</author>
<published>2025-01-17T14:48:59Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=ad5a3a8f41aaa511b2150859ef5b1d76fff34fc9'/>
<id>urn:sha1:ad5a3a8f41aaa511b2150859ef5b1d76fff34fc9</id>
<content type='text'>
Remove hard-coded strings by using the str_enabled_disabled() helper
function.

Suggested-by: Christophe JAILLET &lt;christophe.jaillet@wanadoo.fr&gt;
Signed-off-by: Thorsten Blum &lt;thorsten.blum@linux.dev&gt;
Signed-off-by: Dave Hansen &lt;dave.hansen@linux.intel.com&gt;
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Link: https://lore.kernel.org/all/20250117144900.171684-2-thorsten.blum%40linux.dev
</content>
</entry>
<entry>
<title>x86/mtrr: Rename mtrr_overwrite_state() to guest_force_mtrr_state()</title>
<updated>2024-12-04T18:46:19Z</updated>
<author>
<name>Kirill A. Shutemov</name>
</author>
<published>2024-12-02T07:31:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6a5abeea9c72e1d2c538622b4cf66c80cc816fd3'/>
<id>urn:sha1:6a5abeea9c72e1d2c538622b4cf66c80cc816fd3</id>
<content type='text'>
Rename the helper to better reflect its function.

Suggested-by: Dave Hansen &lt;dave.hansen@intel.com&gt;
Signed-off-by: Kirill A. Shutemov &lt;kirill.shutemov@linux.intel.com&gt;
Signed-off-by: Dave Hansen &lt;dave.hansen@linux.intel.com&gt;
Acked-by: Dave Hansen &lt;dave.hansen@intel.com&gt;
Link: https://lore.kernel.org/all/20241202073139.448208-1-kirill.shutemov%40linux.intel.com
</content>
</entry>
<entry>
<title>x86/CPU/AMD: Track SNP host status with cc_platform_*()</title>
<updated>2024-04-04T08:40:30Z</updated>
<author>
<name>Borislav Petkov (AMD)</name>
</author>
<published>2024-03-27T15:43:17Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0ecaefb303de69929dc0036d5021d01cec7ea052'/>
<id>urn:sha1:0ecaefb303de69929dc0036d5021d01cec7ea052</id>
<content type='text'>
The host SNP worthiness can determined later, after alternatives have
been patched, in snp_rmptable_init() depending on cmdline options like
iommu=pt which is incompatible with SNP, for example.

Which means that one cannot use X86_FEATURE_SEV_SNP and will need to
have a special flag for that control.

Use that newly added CC_ATTR_HOST_SEV_SNP in the appropriate places.

Move kdump_sev_callback() to its rightful place, while at it.

Fixes: 216d106c7ff7 ("x86/sev: Add SEV-SNP host initialization support")
Signed-off-by: Borislav Petkov (AMD) &lt;bp@alien8.de&gt;
Reviewed-by: Tom Lendacky &lt;thomas.lendacky@amd.com&gt;
Tested-by: Srikanth Aithal &lt;sraithal@amd.com&gt;
Link: https://lore.kernel.org/r/20240327154317.29909-6-bp@alien8.de
</content>
</entry>
<entry>
<title>x86/mtrr: Don't print errors if MtrrFixDramModEn is set when SNP enabled</title>
<updated>2024-01-29T16:24:27Z</updated>
<author>
<name>Ashish Kalra</name>
</author>
<published>2024-01-26T04:11:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e3fd08afb7c350d5612f113eadfb4ebb6ed08deb'/>
<id>urn:sha1:e3fd08afb7c350d5612f113eadfb4ebb6ed08deb</id>
<content type='text'>
SNP enabled platforms require the MtrrFixDramModeEn bit to be set across
all CPUs when SNP is enabled. Therefore, don't print error messages when
MtrrFixDramModeEn is set when bringing CPUs online.

Closes: https://lore.kernel.org/kvm/68b2d6bf-bce7-47f9-bebb-2652cc923ff9@linux.microsoft.com/
Reported-by: Jeremi Piotrowski &lt;jpiotrowski@linux.microsoft.com&gt;
Signed-off-by: Ashish Kalra &lt;ashish.kalra@amd.com&gt;
Signed-off-by: Michael Roth &lt;michael.roth@amd.com&gt;
Signed-off-by: Borislav Petkov (AMD) &lt;bp@alien8.de&gt;
Link: https://lore.kernel.org/r/20240126041126.1927228-6-michael.roth@amd.com
</content>
</entry>
<entry>
<title>x86/mtrr: Document missing function parameters in kernel-doc</title>
<updated>2023-11-20T09:19:27Z</updated>
<author>
<name>Borislav Petkov (AMD)</name>
</author>
<published>2023-11-13T13:52:52Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=4e15b91c5b7919c530c27f39c7f2d392bf0a95e3'/>
<id>urn:sha1:4e15b91c5b7919c530c27f39c7f2d392bf0a95e3</id>
<content type='text'>
Add text explaining what they do.

No functional changes.

Closes: https://lore.kernel.org/oe-kbuild-all/202311130104.9xKAKzke-lkp@intel.com/
Reported-by: kernel test robot &lt;lkp@intel.com&gt;
Signed-off-by: Borislav Petkov (AMD) &lt;bp@alien8.de&gt;
Link: https://lore.kernel.org/r/202311130104.9xKAKzke-lkp@intel.com
</content>
</entry>
</feed>
