From: "Josef 'Jeff' Sipek" <jsipek@cs.sunysb.edu>
To: randy.dunlap@oracle.com, akpm@linux-foundation.org,
unionfs@filesystems.org, linux-kernel@vger.kernel.org,
ezk@cs.sunysb.edu
Cc: ezk@cs.sunysb.edu, "Josef 'Jeff' Sipek" <jsipek@cs.sunysb.edu>
Subject: [PATCH 1/1] Unionfs: move poison #define into poison.h
Date: Tue, 25 Sep 2007 13:45:19 -0400 [thread overview]
Message-ID: <1190742319943-git-send-email-jsipek@cs.sunysb.edu> (raw)
In-Reply-To: <20070925102637.79e1dc75.randy.dunlap@oracle.com>
This also fixes a compile warning on 64-bit systems.
Cc: ezk@cs.sunysb.edu
Signed-off-by: Josef 'Jeff' Sipek <jsipek@cs.sunysb.edu>
---
fs/unionfs/debug.c | 12 ++----------
fs/unionfs/union.h | 1 +
include/linux/poison.h | 3 +++
3 files changed, 6 insertions(+), 10 deletions(-)
diff --git a/fs/unionfs/debug.c b/fs/unionfs/debug.c
index f678534..aa6a76a 100644
--- a/fs/unionfs/debug.c
+++ b/fs/unionfs/debug.c
@@ -25,14 +25,6 @@
} \
} while (0)
-#if BITS_PER_LONG == 32
-#define POISONED_PTR ((void*) 0x5a5a5a5a)
-#elif BITS_PER_LONG == 64
-#define POISONED_PTR ((void*) 0x5a5a5a5a5a5a5a5a)
-#else
-#error Unknown BITS_PER_LONG value
-#endif /* BITS_PER_LONG != known */
-
/*
* __unionfs_check_{inode,dentry,file} perform exhaustive sanity checking on
* the fan-out of various Unionfs objects. We check that no lower objects
@@ -93,7 +85,7 @@ void __unionfs_check_inode(const struct inode *inode,
printk(" Ci5: inode/linode=%p:%p bindex=%d "
"istart/end=%d:%d\n", inode,
lower_inode, bindex, istart, iend);
- } else if (lower_inode == POISONED_PTR) {
+ } else if (lower_inode == UNIONFS_POISONED_PTR) {
/* freed inode! */
PRINT_CALLER(fname, fxn, line);
printk(" Ci6: inode/linode=%p:%p bindex=%d "
@@ -261,7 +253,7 @@ void __unionfs_check_dentry(const struct dentry *dentry,
printk(" CI5: dentry/linode=%p:%p bindex=%d "
"istart/end=%d:%d\n", dentry,
lower_inode, bindex, istart, iend);
- } else if (lower_inode == POISONED_PTR) {
+ } else if (lower_inode == UNIONFS_POISONED_PTR) {
/* freed inode! */
PRINT_CALLER(fname, fxn, line);
printk(" CI6: dentry/linode=%p:%p bindex=%d "
diff --git a/fs/unionfs/union.h b/fs/unionfs/union.h
index 9ec5f82..3b6881a 100644
--- a/fs/unionfs/union.h
+++ b/fs/unionfs/union.h
@@ -43,6 +43,7 @@
#include <linux/fs_stack.h>
#include <linux/magic.h>
#include <linux/log2.h>
+#include <linux/poison.h>
#include <asm/mman.h>
#include <asm/system.h>
diff --git a/include/linux/poison.h b/include/linux/poison.h
index d93c300..c81118b 100644
--- a/include/linux/poison.h
+++ b/include/linux/poison.h
@@ -38,6 +38,9 @@
/********** fs/jbd/journal.c **********/
#define JBD_POISON_FREE 0x5b
+/********** fs/unionfs/debug.c **********/
+#define UNIONFS_POISONED_PTR ((void *) 0x75757575)
+
/********** drivers/base/dmapool.c **********/
#define POOL_POISON_FREED 0xa7 /* !inuse */
#define POOL_POISON_ALLOCATED 0xa9 /* !initted */
--
1.5.2.2.238.g7cbf2f2
next prev parent reply other threads:[~2007-09-25 17:46 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-09-25 8:46 2.6.23-rc8-mm1 Andrew Morton
2007-09-25 10:39 ` 2.6.23-rc8-mm1 Kamalesh Babulal
2007-09-25 15:46 ` 2.6.23-rc8-mm1 Andrew Morton
2007-09-25 12:19 ` [-mm Patch] fs/udf/balloc.c: mark a variable as uninitialized_var() WANG Cong
2007-09-25 12:52 ` [-mm Patch] drivers/usb/misc/sisusbvga/sisusb.c: kill two unused variables WANG Cong
2007-09-25 12:53 ` 2.6.23-rc8-mm1 - drivers/net/ibm_newemac/mal - broken Kamalesh Babulal
2007-09-25 16:16 ` Andrew Morton
2007-09-25 13:46 ` 2.6.23-rc8-mm1 -- powerpc link failure Andy Whitcroft
2007-09-25 15:23 ` Jiri Kosina
2007-09-27 12:03 ` Andy Whitcroft
2007-09-27 12:13 ` Jiri Kosina
2007-09-27 17:13 ` Andrew Morton
2007-09-27 19:31 ` Sam Ravnborg
2007-09-27 22:13 ` Andrew Morton
2007-09-27 22:17 ` Jiri Kosina
2007-09-25 17:26 ` 2.6.23-rc8-mm1 Randy Dunlap
2007-09-25 17:39 ` 2.6.23-rc8-mm1 Josef Sipek
2007-09-25 17:45 ` Josef 'Jeff' Sipek [this message]
2007-09-26 1:02 ` [PATCH 1/1] Unionfs: move poison #define into poison.h Josef 'Jeff' Sipek
2007-09-25 19:02 ` 2.6.23-rc8-mm1: unscrew UFS Alexey Dobriyan
2007-09-25 20:00 ` 2.6.23-rc8-mm1 - powerpc memory hotplug link failure Kamalesh Babulal
2007-09-25 20:00 ` Kamalesh Babulal
2007-09-25 22:01 ` Badari Pulavarty
2007-09-25 22:01 ` Badari Pulavarty
2007-09-26 8:18 ` Kamalesh Babulal
2007-09-26 8:18 ` Kamalesh Babulal
2007-09-26 1:32 ` KAMEZAWA Hiroyuki
2007-09-26 1:32 ` KAMEZAWA Hiroyuki
2007-09-26 1:48 ` KAMEZAWA Hiroyuki
2007-09-26 1:48 ` KAMEZAWA Hiroyuki
2007-09-26 8:19 ` Kamalesh Babulal
2007-09-26 8:19 ` Kamalesh Babulal
2007-09-25 20:56 ` 2.6.23-rc8-mm1: drivers/kvm/ioapic.o build failure Mariusz Kozlowski
2007-09-26 9:00 ` [kvm-devel] " Avi Kivity
2007-09-26 9:00 ` Avi Kivity
2007-09-26 9:14 ` [kvm-devel] " Andrew Morton
2007-09-26 9:14 ` Andrew Morton
2007-09-26 9:18 ` [kvm-devel] " Avi Kivity
2007-09-26 9:18 ` Avi Kivity
2007-09-25 22:05 ` 2.6.23-rc8-mm1 Badari Pulavarty
2007-09-26 12:28 ` 2.6.23-rc8-mm1 Andy Whitcroft
2007-09-25 22:23 ` 2.6.23-rc8-mm1 : wgt634u.c trem
2007-09-26 7:51 ` black screen after kill X [Was: 2.6.23-rc8-mm1] Jiri Slaby
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1190742319943-git-send-email-jsipek@cs.sunysb.edu \
--to=jsipek@cs.sunysb.edu \
--cc=akpm@linux-foundation.org \
--cc=ezk@cs.sunysb.edu \
--cc=linux-kernel@vger.kernel.org \
--cc=randy.dunlap@oracle.com \
--cc=unionfs@filesystems.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.