函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\cpu\cacheinfo.c Create Date:2022-07-27 08:54:22
Last Modify:2020-03-16 20:07:28 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:__cache_cpumap_setup

函数原型:static void __cache_cpumap_setup(unsigned int cpu, int index, struct _cpuid4_info_regs *base)

返回类型:void

参数:

类型参数名称
unsigned intcpu
intindex
struct _cpuid4_info_regs *base
937  this_cpu_ci等于get_cpu_cacheinfo(cpu)
941  c等于cpu_data(cpu)
943  如果CPU vendor 恒等于X86_VENDOR_AMDCPU vendor 恒等于X86_VENDOR_HYGON
945  如果__cache_amd_cpumap_setup(cpu, index, base)则返回
949  this_leaf等于info_listindex
950  num_threads_sharing等于1加num_threads_sharing
952  设置CPU信息
953  如果num_threads_sharing恒等于1则返回
956  index_msb等于get_count_order(num_threads_sharing)
958  遍历在线CPU(i)
959  如果apicid右移index_msb位恒等于apicid右移index_msb位则
960  sib_cpu_ci等于get_cpu_cacheinfo(i)
962  如果i恒等于cpu或非info_list则继续下一循环
964  sibling_leaf等于info_listindex
965  设置CPU信息
966  设置CPU信息
调用者
名称描述
__populate_cache_leaves