mirror of
https://github.com/edk2-porting/linux-next.git
synced 2025-01-10 22:54:11 +08:00
leds: tca6507: Convert to use fwnode_device_is_compatible()
Replace open coded fwnode_device_is_compatible() in the driver. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Lee Jones <lee@kernel.org> Link: https://lore.kernel.org/r/20230119175150.77250-1-andriy.shevchenko@linux.intel.com
This commit is contained in:
parent
265d313ee6
commit
8f47707acd
@ -695,8 +695,7 @@ tca6507_led_dt_init(struct device *dev)
|
|||||||
&led.default_trigger);
|
&led.default_trigger);
|
||||||
|
|
||||||
led.flags = 0;
|
led.flags = 0;
|
||||||
if (fwnode_property_match_string(child, "compatible",
|
if (fwnode_device_is_compatible(child, "gpio"))
|
||||||
"gpio") >= 0)
|
|
||||||
led.flags |= TCA6507_MAKE_GPIO;
|
led.flags |= TCA6507_MAKE_GPIO;
|
||||||
|
|
||||||
ret = fwnode_property_read_u32(child, "reg", ®);
|
ret = fwnode_property_read_u32(child, "reg", ®);
|
||||||
|
Loading…
Reference in New Issue
Block a user