Commit 32237677 authored by Guenter Roeck's avatar Guenter Roeck Committed by Dmitry Torokhov

Input: xilinx_ps2 - use 'dev' instead of dereferencing it

Use local variable 'dev' instead of dereferencing it several times.
Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent 009af5fd
...@@ -243,18 +243,17 @@ static int xps2_of_probe(struct platform_device *ofdev) ...@@ -243,18 +243,17 @@ static int xps2_of_probe(struct platform_device *ofdev)
unsigned int irq; unsigned int irq;
int error; int error;
dev_info(dev, "Device Tree Probing \'%s\'\n", dev_info(dev, "Device Tree Probing \'%s\'\n", dev->of_node->name);
ofdev->dev.of_node->name);
/* Get iospace for the device */ /* Get iospace for the device */
error = of_address_to_resource(ofdev->dev.of_node, 0, &r_mem); error = of_address_to_resource(dev->of_node, 0, &r_mem);
if (error) { if (error) {
dev_err(dev, "invalid address\n"); dev_err(dev, "invalid address\n");
return error; return error;
} }
/* Get IRQ for the device */ /* Get IRQ for the device */
irq = irq_of_parse_and_map(ofdev->dev.of_node, 0); irq = irq_of_parse_and_map(dev->of_node, 0);
if (!irq) { if (!irq) {
dev_err(dev, "no IRQ found\n"); dev_err(dev, "no IRQ found\n");
return -ENODEV; return -ENODEV;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment