为什么检查机制要改变?因为MTRR代码升级?还是之前检查的时候出了问题?
x86/mm: Only check uniform after calling mtrr_type_lookup()
Today pud_set_huge() and pmd_set_huge() test for the MTRR type to be
WB or INVALID after calling mtrr_type_lookup().
Those tests can be dropped as the only reason not to use a large mapping
would be uniform being 0.
Any MTRR type can be accepted as long as it applies to the whole memory
range covered by the mapping, as the alternative would only be to map
the same region with smaller pages instead, using the same PAT type as
for the large mapping.
代码已更改,因为 的语义
uniform
不正确。这是在补丁集的早期迭代中发现的;尤尔根·格罗斯问道莱纳斯·托瓦兹 (Linus Torvalds) 回复道
这导致了您所询问的补丁,该补丁被标记为 Linus 建议的。
(在这种情况下,要查找算作建议的电子邮件,请查找建议者发送给补丁作者的电子邮件。)