lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Fri, 17 Aug 2018 02:07:17 +0900
From:   Masami Hiramatsu <mhiramat@...nel.org>
To:     Steven Rostedt <rostedt@...dmis.org>
Cc:     Ingo Molnar <mingo@...hat.com>, linux-kernel@...r.kernel.org,
        Jens Axboe <axboe@...nel.dk>, linux-block@...r.kernel.org
Subject: Re: [PATCH 2/2] tracing/blktrace: Fix to allow setting same value

On Thu, 16 Aug 2018 12:49:17 -0400
Steven Rostedt <rostedt@...dmis.org> wrote:

> > > 
> > > Hmm, why not just do this? Does this fix it too?  
> > 
> > Ah, yes, but we need to clear "ret" in that case.
> 
> Sure.
> 
> > 
> > Thanks!
> > 
> > > 
> > > diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c
> > > index 987d9a9ae283..10b2b9c5fd25 100644
> > > --- a/kernel/trace/blktrace.c
> > > +++ b/kernel/trace/blktrace.c
> > > @@ -1841,6 +1841,8 @@ static ssize_t sysfs_blk_trace_attr_store(struct device *dev,
> > >  	mutex_lock(&q->blk_trace_mutex);
> > >  
> 
> > >  	if (attr == &dev_attr_enable) {
> > > +		if (!!value == !!q->blk_trace) {
>     +                   ret = 0;
> > > +			goto out_unlock_bdev;
>     +		}
> 

OK, I tested and ensured that this works.

Tested-by: Masami Hiramatsu <mhiramat@...nel.org>

Thanks!


-- 
Masami Hiramatsu <mhiramat@...nel.org>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ