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] [day] [month] [year] [list]
Message-ID: <nycvar.YFH.7.76.2211021411290.29912@cbobk.fhfr.pm>
Date:   Wed, 2 Nov 2022 14:11:34 +0100 (CET)
From:   Jiri Kosina <jikos@...nel.org>
To:     Colin Ian King <colin.i.king@...il.com>
cc:     Benjamin Tissoires <benjamin.tissoires@...hat.com>,
        linux-input@...r.kernel.org, kernel-janitors@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] HID: asus: Remove variable count

On Mon, 24 Oct 2022, Colin Ian King wrote:

> Variable count is just being incremented and it's never used
> anywhere else. The variable and the increment are redundant so
> remove it.
> 
> Signed-off-by: Colin Ian King <colin.i.king@...il.com>
> ---
>  drivers/hid/hid-asus.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/hid/hid-asus.c b/drivers/hid/hid-asus.c
> index b59c3dafa6a4..f99752b998f3 100644
> --- a/drivers/hid/hid-asus.c
> +++ b/drivers/hid/hid-asus.c
> @@ -219,14 +219,13 @@ static void asus_report_tool_width(struct asus_drvdata *drvdat)
>  {
>  	struct input_mt *mt = drvdat->input->mt;
>  	struct input_mt_slot *oldest;
> -	int oldid, count, i;
> +	int oldid, i;
>  
>  	if (drvdat->tp->contact_size < 5)
>  		return;
>  
>  	oldest = NULL;
>  	oldid = mt->trkid;
> -	count = 0;
>  
>  	for (i = 0; i < mt->num_slots; ++i) {
>  		struct input_mt_slot *ps = &mt->slots[i];
> @@ -238,7 +237,6 @@ static void asus_report_tool_width(struct asus_drvdata *drvdat)
>  			oldest = ps;
>  			oldid = id;
>  		}
> -		count++;
>  	}

Applied, thanks.

-- 
Jiri Kosina
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ