Originally posted by andyhhp
View Post
Announcement
Collapse
No announcement yet.
Linux Adjusts "Meltdown Lite" Mitigation Handling On Newer Zen 5 CPUs
Collapse
X
-
Originally posted by ATLief View Post
So will fixing this vulnerability hurt Linux performance on Zen5 / make it more similar to Zen4? Will it be enough to invalidate previous benchmarks?
There was previously an optimisation which should be a win across the board. In fact, Intel's kernel test robot measured it at +6.8% improvement on stress-ng. (https://lore.kernel.org/all/[email protected]/)
However, the optimisation made Linux vulnerable to CVE-2020-12965 on AMD systems. This is is an adjustment to that optimisation, to keep it fast but without the problem on AMD.
~Andrew
- Likes 4
Comment
-
Maybe someone who understands deeper could explain why the conditional sizing of the pointer limit is commented out:
+ /*
+ * Enable this when LAM is gated on LASS support
+ if (cpu_feature_enabled(X86_FEATURE_LAM))
+ USER_PTR_MAX = (1ul << 63) - PAGE_SIZE - 1;
+ */
+ runtime_const_init(ptr, USER_PTR_MAX);
Comment
-
Originally posted by hinicogi View PostMaybe someone who understands deeper could explain why the conditional sizing of the pointer limit is commented out:
+ /*
+ * Enable this when LAM is gated on LASS support
+ if (cpu_feature_enabled(X86_FEATURE_LAM))
+ USER_PTR_MAX = (1ul << 63) - PAGE_SIZE - 1;
+ */
+ runtime_const_init(ptr, USER_PTR_MAX);
However enabling LAM allows speculative sidechannels to leak data it previously couldn't leak (i.e. previously blocked by the sign extension requirement). This is the subject of a research paper called SLAM. https://lwn.net/Articles/953880/
There's a separate feature, LASS (Linear Address Space Separation) which is a far more comprehensive prevention of sidechannels (speculative and otherwise). However, it's not available in all CPUs which support LAM, and Linux has decided to veto the use of LAM in those systems.
The reason the logic is commented out is that it is logic that needs to be turned on by LAM support, but only after a) LASS is enabled too, or b) LAM is hard-vetoed on non-LASS systems.
~Andrew
- Likes 2
Comment
-
Originally posted by milkylainen View Post
Why is that interesting? Like he wouldn't be capable?
I know lots of 50+ that would code circles around their younger peers.
Beside. I credit the man for working his brain, instead of letting it turn to mush.
Comment
Comment