[SRU][Questing][PATCH 4/8] HID: Intel-thc-hid: Intel-thc: Use str_true_false() helper

You-Sheng Yang vicamo.yang at canonical.com
Tue Jan 20 12:43:56 UTC 2026


From: Liu Song <liu.song13 at zte.com.cn>

BugLink: https://bugs.launchpad.net/bugs/2137272

Remove hard-coded strings by using the str_true_false() helper function.

Signed-off-by: Liu Song <liu.song13 at zte.com.cn>
Reviewed-by: Even Xu <even.xu at intel.com>
Signed-off-by: Jiri Kosina <jkosina at suse.com>
(cherry picked from commit 1860b13beca829c056179c63530eebfec9a3efb4)
Signed-off-by: You-Sheng Yang <vicamo.yang at canonical.com>
---
 drivers/hid/intel-thc-hid/intel-thc/intel-thc-dev.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/hid/intel-thc-hid/intel-thc/intel-thc-dev.c b/drivers/hid/intel-thc-hid/intel-thc/intel-thc-dev.c
index e1cb9b117ebc5..636a683065015 100644
--- a/drivers/hid/intel-thc-hid/intel-thc/intel-thc-dev.c
+++ b/drivers/hid/intel-thc-hid/intel-thc/intel-thc-dev.c
@@ -4,6 +4,7 @@
 #include <linux/bitfield.h>
 #include <linux/math.h>
 #include <linux/regmap.h>
+#include <linux/string_choices.h>
 
 #include "intel-thc-dev.h"
 #include "intel-thc-hw.h"
@@ -664,7 +665,7 @@ int thc_interrupt_quiesce(const struct thc_device *dev, bool int_quiesce)
 	if (ret) {
 		dev_err_once(dev->dev,
 			     "Timeout while waiting THC idle, target quiesce state = %s\n",
-			     int_quiesce ? "true" : "false");
+			     str_true_false(int_quiesce));
 		return ret;
 	}
 
-- 
2.51.0




More information about the kernel-team mailing list