Skip to contentSkip to conversation

Input: olpc_apsp - remove set but not used variable 'np'

PATCH Dmitry Torokhov 1 participant 1 message Dec 3, 2018 Kernel janitors

lore
Share & tools
lore

Dmitry Torokhov

author Applied
#0 lore raw
Quoted 10 lines · YueHaibing

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/input/serio/olpc_apsp.c: In function 'olpc_apsp_probe':
drivers/input/serio/olpc_apsp.c:192:22: warning:
variable 'np' set but not used [-Wunused-but-set-variable]

It never used since intrdduction in commit
b56ece9a3ac3 ("Input: add OLPC AP-SP driver")

Applied, thank you.

Quoted 26 lines
---
 drivers/input/serio/olpc_apsp.c | 2 --
 1 file changed, 2 deletions(-)
drivers/input/serio/olpc_apsp.c +0 -2
index 91d6fb8..b360847 100644
@@ -189,14 +189,12 @@ static int olpc_apsp_probe(struct platform_device *pdev)
 	struct serio *kb_serio, *pad_serio;
 	struct olpc_apsp *priv;
 	struct resource *res;
-	struct device_node *np;
 	int error;
 
 	priv = devm_kzalloc(&pdev->dev, sizeof(struct olpc_apsp), GFP_KERNEL);
 	if (!priv)
 		return -ENOMEM;
 
-	np = pdev->dev.of_node;
 	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
 	priv->base = devm_ioremap_resource(&pdev->dev, res);
 	if (IS_ERR(priv->base)) {
Signature · 1 line
Dmitry