lkml.org 
[lkml]   [2007]   [Jan]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] Introduce simple TRUE and FALSE boolean macros.

Introduce the TRUE and FALSE boolean macros so that everyone can
stop re-inventing them, and remove the one occurrence in the source
tree that clashes with that change.

Signed-off-by: Robert P. J. Day <rpjday@mindspring.com>

---

once this patch is applied, others can remove all of the superfluous
macro definitions from the source tree at their convenience.

this was compile tested on x86 with "make allyesconfig".


drivers/net/wireless/strip.c | 2 --
include/linux/types.h | 2 ++
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/wireless/strip.c b/drivers/net/wireless/strip.c
index ce3a8ba..5e64ec1 100644
--- a/drivers/net/wireless/strip.c
+++ b/drivers/net/wireless/strip.c
@@ -177,8 +177,6 @@ typedef struct {
MetricomNode node[NODE_TABLE_SIZE];
} MetricomNodeTable;

-enum { FALSE = 0, TRUE = 1 };
-
/*
* Holds the radio's firmware version.
*/
diff --git a/include/linux/types.h b/include/linux/types.h
index 0351bf2..d988636 100644
--- a/include/linux/types.h
+++ b/include/linux/types.h
@@ -34,6 +34,8 @@ typedef __kernel_mqd_t mqd_t;

#ifdef __KERNEL__
typedef _Bool bool;
+#define TRUE 1
+#define FALSE 0

typedef __kernel_uid32_t uid_t;
typedef __kernel_gid32_t gid_t;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2007-01-21 12:13    [W:0.059 / U:0.404 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site