函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\cpu\bugs.c Create Date:2022-07-27 08:56:48
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:l1tf_select_mitigation

函数原型:static void __init l1tf_select_mitigation(void)

返回类型:void

参数:

1339  如果非boot_cpu_has_bug(CPU is affected by L1 Terminal Fault )则返回
1342  如果cpu_mitigations_off()则Default mitigation for L1TF-affected CPUs 等于L1TF_MITIGATION_OFF
1344  否则如果cpu_mitigations_auto_nosmt()则Default mitigation for L1TF-affected CPUs 等于L1TF_MITIGATION_FLUSH_NOSMT
1347  These CPUs all support 44bits physical address space internally in the* cache but CPUID can report a smaller number of physical address bits.* The L1TF mitigation uses the top most address bit for the inversion of* non present PTEs
1350  :Default mitigation for L1TF-affected CPUs 恒等于L1TF_MITIGATION_OFF
1351  :Default mitigation for L1TF-affected CPUs 恒等于L1TF_MITIGATION_FLUSH_NOWARN
1352  :Default mitigation for L1TF-affected CPUs 恒等于L1TF_MITIGATION_FLUSH
1353  退出
1354  :Default mitigation for L1TF-affected CPUs 恒等于L1TF_MITIGATION_FLUSH_NOSMT
1355  :Default mitigation for L1TF-affected CPUs 恒等于L1TF_MITIGATION_FULL
1356  cpu_smt_disable(false)
1357  退出
1358  :Default mitigation for L1TF-affected CPUs 恒等于L1TF_MITIGATION_FULL_FORCE
1359  cpu_smt_disable(true)
1360  退出
1368  half_pa等于l1tf_pfn_limit()左移PAGE_SHIFT determines the page size
1369  如果Default mitigation for L1TF-affected CPUs 不等于L1TF_MITIGATION_OFFe820__mapped_any(half_pa, ULLONG_MAX - half_pa, E820_TYPE_RAM)则
1371  打印警告信息("System has more than MAX_PA/2 memory. L1TF mitigation not effective.\n")
1372  打印信息("You may make it effective by booting the kernel with mem=%llu parameter.\n", half_pa)
1374  打印信息("However, doing so will make a part of your RAM unusable.\n")
1375  打印信息("Reading https://www.kernel.org/doc/html/latest/admin-guide/hw-vuln/l1tf.html might help you decide.\n")
1376  返回
1379  setup_force_cpu_cap("" L1TF workaround PTE inversion )
调用者
名称描述
check_bugs检查CPU配置是否非法使用不具备的功能