[PATCH] powerpc/papr_scm: Make access mode of 'perf_stats' attribute file to '0400'
Michael Ellerman
mpe at ellerman.id.au
Mon Aug 10 23:12:08 AEST 2020
Vaibhav Jain <vaibhav at linux.ibm.com> writes:
> The newly introduced 'perf_stats' attribute uses the default access
> mode of 0444 letting non-root users access performance stats of an
> nvdimm and potentially force the kernel into issuing large number of
> expensive HCALLs. Since the information exposed by this attribute
> cannot be cached hence its better to ward of access to this attribute
> from non-root users.
>
> Hence this patch updates the access-mode of 'perf_stats' sysfs
> attribute file to 0400 to make it only readable to root-users.
Or should we ratelimit it?
Fixes: ??
> Reported-by: Aneesh Kumar K.V <aneesh.kumar at linux.ibm.com>
> Signed-off-by: Vaibhav Jain <vaibhav at linux.ibm.com>
cheers
More information about the Linuxppc-dev
mailing list