]> www.infradead.org Git - users/willy/linux.git/commitdiff
staging:fbtft: Using str_true_false() helper instead of hardcoded strings
authorPaolo Perego <pperego@suse.de>
Wed, 20 Nov 2024 13:57:27 +0000 (14:57 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 4 Dec 2024 15:55:19 +0000 (16:55 +0100)
Using str_true_false() helper instead of hardcoded strings.

Signed-off-by: Paolo Perego <pperego@suse.de>
Link: https://lore.kernel.org/r/20241120135727.376556-1-pperego@suse.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/fbtft/fb_ssd1351.c

index f6db2933ebba2a545dd715433aa0fd2bbd28d953..6736b09b2f458cd0ad97374b3604e264cb90e160 100644 (file)
@@ -6,6 +6,7 @@
 #include <linux/init.h>
 #include <linux/spi/spi.h>
 #include <linux/delay.h>
+#include <linux/string_choices.h>
 
 #include "fbtft.h"
 
@@ -162,7 +163,7 @@ static int set_gamma(struct fbtft_par *par, u32 *curves)
 static int blank(struct fbtft_par *par, bool on)
 {
        fbtft_par_dbg(DEBUG_BLANK, par, "(%s=%s)\n",
-                     __func__, on ? "true" : "false");
+                     __func__, str_true_false(on));
        if (on)
                write_reg(par, 0xAE);
        else