+++ /dev/null
- fs/ext3/xattr.c | 12 +++++-
- fs/ext3/xattr_trusted.c | 86 +++++++++++++++++++++++++++++++++++++++++++++
- include/linux/ext3_xattr.h | 6 +++
- 3 files changed, 102 insertions(+), 2 deletions(-)
-
-Index: linux-2.4.21/fs/ext3/Makefile
-===================================================================
---- linux-2.4.21.orig/fs/ext3/Makefile 2004-06-16 14:52:07.000000000 -0600
-+++ linux-2.4.21/fs/ext3/Makefile 2004-06-16 14:52:08.000000000 -0600
-@@ -12,7 +12,8 @@ O_TARGET := ext3.o
- export-objs := ext3-exports.o
-
- obj-y := balloc.o bitmap.o dir.o file.o fsync.o ialloc.o inode.o iopen.o \
-- ioctl.o namei.o super.o symlink.o hash.o ext3-exports.o
-+ ioctl.o namei.o super.o symlink.o hash.o ext3-exports.o \
-+ xattr_trusted.o
- obj-m := $(O_TARGET)
-
- export-objs += xattr.o
-Index: linux-2.4.21/fs/ext3/xattr.c
-===================================================================
---- linux-2.4.21.orig/fs/ext3/xattr.c 2004-06-16 14:52:08.000000000 -0600
-+++ linux-2.4.21/fs/ext3/xattr.c 2004-06-16 15:47:06.000000000 -0600
-@@ -1780,18 +1780,25 @@ static void ext3_xattr_rehash(struct ext
- int __init
- init_ext3_xattr(void)
- {
-+ int error;
-+
- ext3_xattr_cache = mb_cache_create("ext3_xattr", NULL,
- sizeof(struct mb_cache_entry) +
- sizeof(struct mb_cache_entry_index), 1, 61);
- if (!ext3_xattr_cache)
- return -ENOMEM;
-
-- return 0;
-+ error = init_ext3_xattr_trusted();
-+ if (error)
-+ mb_cache_destroy(ext3_xattr_cache);
-+
-+ return error;
- }
-
- void
- exit_ext3_xattr(void)
- {
-+ exit_ext3_xattr_trusted();
- if (ext3_xattr_cache)
- mb_cache_destroy(ext3_xattr_cache);
- ext3_xattr_cache = NULL;
-@@ -1802,12 +1809,13 @@ exit_ext3_xattr(void)
- int __init
- init_ext3_xattr(void)
- {
-- return 0;
-+ return init_ext3_xattr_trusted();
- }
-
- void
- exit_ext3_xattr(void)
- {
-+ exit_ext3_xattr_trusted();
- }
-
- #endif /* CONFIG_EXT3_FS_XATTR_SHARING */
-Index: linux-2.4.21/fs/ext3/xattr_trusted.c
-===================================================================
---- linux-2.4.21.orig/fs/ext3/xattr_trusted.c 2004-06-16 14:52:06.000000000 -0600
-+++ linux-2.4.21/fs/ext3/xattr_trusted.c 2004-06-16 15:36:26.000000000 -0600
-@@ -2,10 +2,11 @@
- * linux/fs/ext3/xattr_trusted.c
- * Handler for trusted extended attributes.
- *
-- * Copyright (C) 2001 by Andreas Gruenbacher, <a.gruenbacher@computer.org>
-+ * Copyright (C) 2003 by Andreas Gruenbacher, <a.gruenbacher@computer.org>
- */
-
--#include <linux/sched.h>
-+#include <linux/module.h>
-+#include <linux/string.h>
- #include <linux/fs.h>
- #include <linux/ext3_jbd.h>
- #include <linux/ext3_fs.h>
-Index: linux-2.4.21/include/linux/ext3_xattr.h
-===================================================================
---- linux-2.4.21.orig/include/linux/ext3_xattr.h 2004-06-16 14:52:06.000000000 -0600
-+++ linux-2.4.21/include/linux/ext3_xattr.h 2004-06-16 14:52:08.000000000 -0600
-@@ -93,6 +93,9 @@ extern void ext3_xattr_put_super(struct
- extern int init_ext3_xattr(void) __init;
- extern void exit_ext3_xattr(void);
-
-+extern int init_ext3_xattr_trusted(void) __init;
-+extern void exit_ext3_xattr_trusted(void);
-+
- # else /* CONFIG_EXT3_FS_XATTR */
- # define ext3_setxattr NULL
- # define ext3_getxattr NULL