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-next>] [day] [month] [year] [list]
Message-Id: <20240307105135.1981060-1-colin.i.king@gmail.com>
Date: Thu,  7 Mar 2024 10:51:35 +0000
From: Colin Ian King <colin.i.king@...il.com>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	u.kleine-koenig@...gutronix.de,
	linux-usb@...r.kernel.org
Cc: kernel-janitors@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: [PATCH][next] usb: gadget: net2272: remove redundant variable irqflags

The variable irqflags is being initialized and being bit-or'd with
values but it is never read afterwards. The variable is redundant
and can be removed.

Cleans up clang scan build warning:
drivers/usb/gadget/udc/net2272.c:2610:15: warning: variable 'irqflags'
set but not used [-Wunused-but-set-variable]

Signed-off-by: Colin Ian King <colin.i.king@...il.com>
---
 drivers/usb/gadget/udc/net2272.c | 11 -----------
 1 file changed, 11 deletions(-)

diff --git a/drivers/usb/gadget/udc/net2272.c b/drivers/usb/gadget/udc/net2272.c
index 12e76bb62c20..afd2a836be6d 100644
--- a/drivers/usb/gadget/udc/net2272.c
+++ b/drivers/usb/gadget/udc/net2272.c
@@ -2607,7 +2607,6 @@ net2272_plat_probe(struct platform_device *pdev)
 {
 	struct net2272 *dev;
 	int ret;
-	unsigned int irqflags;
 	resource_size_t base, len;
 	struct resource *iomem, *iomem_bus, *irq_res;
 
@@ -2623,16 +2622,6 @@ net2272_plat_probe(struct platform_device *pdev)
 	if (IS_ERR(dev))
 		return PTR_ERR(dev);
 
-	irqflags = 0;
-	if (irq_res->flags & IORESOURCE_IRQ_HIGHEDGE)
-		irqflags |= IRQF_TRIGGER_RISING;
-	if (irq_res->flags & IORESOURCE_IRQ_LOWEDGE)
-		irqflags |= IRQF_TRIGGER_FALLING;
-	if (irq_res->flags & IORESOURCE_IRQ_HIGHLEVEL)
-		irqflags |= IRQF_TRIGGER_HIGH;
-	if (irq_res->flags & IORESOURCE_IRQ_LOWLEVEL)
-		irqflags |= IRQF_TRIGGER_LOW;
-
 	base = iomem->start;
 	len = resource_size(iomem);
 	if (iomem_bus)
-- 
2.39.2


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ