summaryrefslogtreecommitdiff
path: root/include/linux/string_choices.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/string_choices.h')
-rw-r--r--include/linux/string_choices.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/string_choices.h b/include/linux/string_choices.h
index f3ba4f52ff26..6c4077be7742 100644
--- a/include/linux/string_choices.h
+++ b/include/linux/string_choices.h
@@ -17,6 +17,12 @@
#include <linux/types.h>
+static inline const char *str_assert_deassert(bool v)
+{
+ return v ? "assert" : "deassert";
+}
+#define str_deassert_assert(v) str_assert_deassert(!(v))
+
static inline const char *str_enable_disable(bool v)
{
return v ? "enable" : "disable";