函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\smpboot.c Create Date:2022-07-27 10:34:26
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:__smpboot_create_thread

函数原型:static int __smpboot_create_thread(struct smp_hotplug_thread *ht, unsigned int cpu)

返回类型:int

参数:

类型参数名称
struct smp_hotplug_thread *ht
unsigned intcpu
173  tsk等于per_cpu_ptr(store, cpu)
176  如果tsk则返回:0
179  td等于根据内存节点分配内存
180  如果非td则返回:负ENOMEM
182  cpu等于cpu
183  ht等于ht
185  tsk等于kthread_create_on_cpu - Create a cpu bound kthread*@threadfn: the function to run until signal_pending(current).*@data: data ptr for @threadfn.*@cpu: The cpu on which the thread should be bound,*@namefmt: printf-style name for the thread
187  如果是错误
188  释放内存
189  返回:错误
195  kthread_park - park a thread created by kthread_create()
196  get_task_struct(tsk)
197  per_cpu_ptr(store, cpu)等于tsk
198  如果create
205  如果非wait_task_inactive(tsk, Used in tsk->state again: )则WARN_ON(1)
207  否则create(cpu)
210  返回:0
调用者
名称描述
smpboot_create_threads
smpboot_register_percpu_threadsmpboot_register_percpu_thread - Register a per_cpu thread related* to hotplug*@plug_thread: Hotplug thread descriptor* Creates and starts the threads on all online cpus.