Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:arch\x86\kernel\cpu\microcode\intel.c Create Date:2022-07-28 08:08:17
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:save_microcode_patch

Proto:static void save_microcode_patch(void *data, unsigned int size)

Type:void

Parameter:

TypeParameterName
void *data
unsigned intsize
170  struct ucode_patch * iter, * tmp, * p = NULL
171  bool prev_found = false
174  mc_hdr = data
177  mc_saved_hdr = Intel uses only this one
178  sig = sig
179  pf = pf
181  If Returns 1 if update has been found, 0 otherwise. Then
182  prev_found = true
184  If rev <= rev Then Continue
187  p = memdup_patch(data, size)
188  If Not p Then pr_err("Error allocating buffer %p\n", data)
190  Else
202  If Not prev_found Then
203  p = memdup_patch(data, size)
204  If Not p Then pr_err("Error allocating buffer for %p\n", data)
206  Else list_add_tail - add a new entry*@new: new entry to be added*@head: list head to add it before* Insert a new entry before the specified head.* This is useful for implementing queues.
210  If Not p Then Return
218  If IS_ENABLED(CONFIG_FOO) evaluates to 1 if CONFIG_FOO is set to 'y' or 'm',* 0 otherwise.(CONFIG_X86_32) Then Current microcode patch used in early patching on the APs. = __pa_nodebug( Intel uses only this one )
220  Else Current microcode patch used in early patching on the APs. = Intel uses only this one
Caller
NameDescribe
scan_microcodeGet microcode matching with BSP's model. Only CPUs with the same model as* BSP can stay in the platform.
save_mc_for_earlySave this microcode patch. It will be loaded early when a CPU is* hot-added or resumes.