lkml.org 
[lkml]   [2021]   [Jun]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH v31 08/13] mm/damon/dbgfs: Export kdamond pid to the user space
Date
From: SeongJae Park <sjpark@amazon.de>

On Tue, 22 Jun 2021 11:23:12 -0700 Shakeel Butt <shakeelb@google.com> wrote:

> On Mon, Jun 21, 2021 at 1:31 AM SeongJae Park <sj38.park@gmail.com> wrote:
> >
> > From: SeongJae Park <sjpark@amazon.de>
> >
> > For CPU usage accounting, knowing pid of the monitoring thread could be
> > helpful. For example, users could use cpuaccount cgroups with the pid.
> >
> > This commit therefore exports the pid of currently running monitoring
> > thread to the user space via 'kdamond_pid' file in the debugfs
> > directory.
> >
> > Signed-off-by: SeongJae Park <sjpark@amazon.de>
> > Reviewed-by: Fernand Sieber <sieberf@amazon.com>
> > ---
>
> [...]
>
> >
> > +static const struct file_operations kdamond_pid_fops = {
> > + .owner = THIS_MODULE,
>
> I don't think you need to set the owner (and for other fops) as these
> files are built into modules. Otherwise it looks good.

Good point. Will remove those from the next spin.


Thanks,
SeongJae Park

\
 
 \ /
  Last update: 2021-06-24 12:27    [W:0.091 / U:0.160 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site