Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:security\integrity\ima\ima_template.c Create Date:2022-07-28 19:59:10
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:restore_template_fmt

Proto:static struct ima_template_desc *restore_template_fmt(char *template_name)

Type:struct ima_template_desc

Parameter:

TypeParameterName
char *template_name
275  struct ima_template_desc * template_desc = NULL
278  ret = template_desc_init_fields(template_name, NULL, NULL)
279  If ret < 0 Then
280  pr_err("attempting to initialize the template \"%s\" failed\n", template_name)
282  Go to out
285  template_desc = kzalloc - allocate memory. The memory is set to zero.*@size: how many bytes of memory are required.*@flags: the type of memory to allocate (see kmalloc).
286  If Not template_desc Then Go to out
289  name = ""
290  fmt = kstrdup - allocate space for and copy an existing string*@s: the string to duplicate*@gfp: the GFP mask used in the kmalloc() call when allocating memory* Return: newly allocated copy of @s or %NULL in case of error
291  If Not fmt Then Go to out
294  spin_lock( & template_list)
295  list_add_tail_rcu - add a new entry to rcu-protected list*@new: new entry to be added*@head: list head to add it before* Insert a new entry before the specified head
296  spin_unlock( & template_list)
297  out :
298  Return template_desc
Caller
NameDescribe
ima_restore_measurement_listRestore the serialized binary measurement list without extending PCRs.