Skip to content

Commit 5af89b6

Browse files
andy-shevTzung-Bi Shih
authored andcommitted
platform/chrome: chromeos_laptop: Replace open coded variant of DEFINE_RES_IRQ()
DEFINE_RES_*() are compound literals, and hence no need to do that explicitly. Besides that, we have no IRQ name provided, no need to use _NAMED() variant. Replace open coded variant of DEFINE_RES_IRQ(). No functional changes intended. Signed-off-by: Andy Shevchenko <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Tzung-Bi Shih <[email protected]>
1 parent 0c8fe93 commit 5af89b6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/platform/chrome/chromeos_laptop.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -726,9 +726,9 @@ static int __init chromeos_laptop_setup_irq(struct i2c_peripheral *i2c_dev)
726726
if (irq < 0)
727727
return irq;
728728

729-
i2c_dev->irq_resource = (struct resource)
730-
DEFINE_RES_NAMED(irq, 1, NULL,
731-
IORESOURCE_IRQ | i2c_dev->irqflags);
729+
i2c_dev->irq_resource = DEFINE_RES_IRQ(irq);
730+
i2c_dev->irq_resource.flags |= i2c_dev->irqflags;
731+
732732
i2c_dev->board_info.resources = &i2c_dev->irq_resource;
733733
i2c_dev->board_info.num_resources = 1;
734734
}

0 commit comments

Comments
 (0)