Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

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

Name:mkdir_mondata_subdir

Proto:static int mkdir_mondata_subdir(struct kernfs_node *parent_kn, struct rdt_domain *d, struct rdt_resource *r, struct rdtgroup *prgrp)

Type:int

Parameter:

TypeParameterName
struct kernfs_node *parent_kn
struct rdt_domain *d
struct rdt_resource *r
struct rdtgroup *prgrp
2348  sprintf(name, "mon_%s_%02d", name, id)
2350  kn = kernfs_create_dir(parent_kn, name, mode, prgrp)
2351  If IS_ERR(kn) Then Return PTR_ERR(kn)
2358  kernfs_get(kn)
2359  ret = set uid and gid of rdtgroup dirs and files to that of the creator
2360  If ret Then Go to out_destroy
2363  If WARN_ON(list_empty - tests whether a list is empty*@head: the list to test.) Then
2364  ret = -EPERM
2365  Go to out_destroy
2368  rid = rid
2369  domid = id
2371  evtid = evtid
2372  ret = mon_addfile(kn, name, priv)
2373  If ret Then Go to out_destroy
2376  If is_mbm_event(evtid) Then mon_event_read( & rr, d, prgrp, evtid, true)
2379  kernfs_activate(kn)
2380  Return 0
2382  out_destroy :
2383  kernfs_remove(kn)
2384  Return ret
Caller
NameDescribe
mkdir_mondata_subdir_allrdtgrpAdd all subdirectories of mon_data for "ctrl_mon" groups* and "monitor" groups with given domain id.
mkdir_mondata_subdir_alldom