lkml.org 
[lkml]   [2016]   [Oct]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v4 12/18] x86/intel_rdt: Add "info" files to resctrl file system
On Fri, 14 Oct 2016, Fenghua Yu wrote:
> static int __init rdtgroup_setup_root(void)
> {
> + int ret;
> +
> rdt_root = kernfs_create_root(&rdtgroup_kf_syscall_ops,
> KERNFS_ROOT_CREATE_DEACTIVATED,
> &rdtgroup_default);
> @@ -193,7 +364,9 @@ static int __init rdtgroup_setup_root(void)
> list_add(&rdtgroup_default.rdtgroup_list, &rdt_all_groups);
>
> rdtgroup_default.kn = rdt_root->kn;
> - kernfs_activate(rdtgroup_default.kn);
> + ret = rdtgroup_create_info_dir(rdtgroup_default.kn);
> + if (!ret)
> + kernfs_activate(rdtgroup_default.kn);
>
> mutex_unlock(&rdtgroup_mutex);

So this is followed by:

return 0;

which means that an error in rdtgroup_create_info_dir() is ignored. As a
consequence the mount point is created and the file system is registered
w/o the info directory....

Thanks,

tglx

\
 
 \ /
  Last update: 2016-10-17 21:49    [W:0.199 / U:21.308 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site