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]
Message-ID: <770e66e5f2d7efcea61fc9d57e1053f0@linux.vnet.ibm.com>
Date:   Tue, 30 Jun 2020 10:03:31 +0200
From:   haver <haver@...ux.vnet.ibm.com>
To:     Lee Jones <lee.jones@...aro.org>
Cc:     arnd@...db.de, gregkh@...uxfoundation.org,
        linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
        Michael Jung <mijung@....net>,
        Michael Ruettger <michael@...ra.de>,
        Frank Haverkamp <haver@...ux.ibm.com>,
        Joerg-Stephan Vogt <jsvogt@...ibm.com>
Subject: Re: [PATCH 16/20] misc: genwqe: card_base: Remove set but unused
 variable 'rc'

On 2020-06-30 09:42, Lee Jones wrote:
> On Tue, 30 Jun 2020, haver wrote:
> 
>> On 2020-06-29 16:04, Lee Jones wrote:
>> > Variable 'rc' hasn't been checked since the driver's inception
>> > in 2013.  If it hasn't caused any issues since then, it's unlikely
>> > to in the future.  Let's take it out for now.
>> >
>> > Fixes the following W=1 kernel build warning(s):
>> >
>> >  drivers/misc/genwqe/card_base.c: In function
>> > ‘genwqe_health_check_stop’:
>> >
>> > /home/lee/projects/linux/kernel/drivers/misc/genwqe/card_base.c:1046:6:
>> > warning: variable ‘rc’ set but not used
>> > [-Wunused-but-set-variable]
>> >  1046 | int rc;
>> >  | ^~
>> >
>> > Cc: Michael Jung <mijung@....net>
>> > Cc: Michael Ruettger <michael@...ra.de>
>> > Cc: Frank Haverkamp <haver@...ux.ibm.com>
>> > Cc: Joerg-Stephan Vogt <jsvogt@...ibm.com>
>> > Signed-off-by: Lee Jones <lee.jones@...aro.org>
>> > ---
>> >  drivers/misc/genwqe/card_base.c | 4 +---
>> >  1 file changed, 1 insertion(+), 3 deletions(-)
>> >
>> > diff --git a/drivers/misc/genwqe/card_base.c
>> > b/drivers/misc/genwqe/card_base.c
>> > index 1dc6c7c5cbce9..bceebf49de2d5 100644
>> > --- a/drivers/misc/genwqe/card_base.c
>> > +++ b/drivers/misc/genwqe/card_base.c
>> > @@ -1043,12 +1043,10 @@ static int genwqe_health_thread_running(struct
>> > genwqe_dev *cd)
>> >
>> >  static int genwqe_health_check_stop(struct genwqe_dev *cd)
>> >  {
>> > -	int rc;
>> > -
>> >  	if (!genwqe_health_thread_running(cd))
>> >  		return -EIO;
>> >
>> > -	rc = kthread_stop(cd->health_thread);
>> > +	kthread_stop(cd->health_thread);
>> >  	cd->health_thread = NULL;
>> >  	return 0;
>> >  }
>> 
>> Good idea. Let's remove it Thanks for the contribution.
> 
> No problem, and you are welcome.
> 
>> Signed-off-by: Frank Haverkamp <haver@...ux.ibm.com>
> 
> Just as an aside, this should be Acked-by, unless you either
> contributed to the patch directly or are in the delivery path i.e. you
> plan to pick the patch and send it to, say Linus, via a pull-request.

Right. Thanks for reminding me. Feel free to send it yourself.
When was the documentation checking introduced? At the time we
contributed the code there was no such checking.

Acked-by: Frank Haverkamp <haver@...ux.ibm.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ