Skip to contentSkip to conversation

gpio: merrifield: Use str_enable_disable() helper

PATCH In review Andy Shevchenko 1 participant 2 messages Oct 17, 2022 – Oct 18, 2022

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gpio: merrifield: Use str_enable_disable() helper

Use str_enable_disable() helper instead of open coding the same.

---
 drivers/gpio/gpio-merrifield.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/gpio/gpio-merrifield.c +2 -1
index 72ac09a59702..92ea8411050d 100644
@@ -14,6 +14,7 @@
 #include <linux/module.h>
 #include <linux/pci.h>
 #include <linux/pinctrl/consumer.h>
+#include <linux/string_helpers.h>
 
 #define GCCR		0x000	/* controller configuration */
 #define GPLR		0x004	/* pin level r/o */
@@ -331,7 +332,7 @@ static int mrfld_irq_set_wake(struct irq_data *d, unsigned int on)
 
 	raw_spin_unlock_irqrestore(&priv->lock, flags);
 
-	dev_dbg(priv->dev, "%sable wake for gpio %u\n", on ? "en" : "dis", gpio);
+	dev_dbg(priv->dev, "%s wake for gpio %u\n", str_enable_disable(on), gpio);
 	return 0;
 }
 
Signature · 1 line
2.35.1
#1 lore raw
Quoted 1 line · Andy Shevchenko

Use str_enable_disable() helper instead of open coding the same.

Pushed to my review and testing queue, thanks!

Signature · 2 lines
With Best Regards,
Andy Shevchenko