diff -urN linux/fs/aufs/export.c linux-aufs/fs/aufs/export.c
--- linux/fs/aufs/export.c 1970-01-01 01:00:00.000000000 +0100
+++ linux-aufs/fs/aufs/export.c 2009-03-12 16:18:04.000000000 +0100
-@@ -0,0 +1,826 @@
+@@ -0,0 +1,827 @@
+/*
+ * Copyright (C) 2005-2009 Junjiro Okajima
+ *
+#include <linux/exportfs.h>
+#include <linux/mnt_namespace.h>
+#include <linux/random.h>
++#include <linux/nsproxy.h>
+#include "aufs.h"
+
+union conv {
+ if (file && au_test_nfs(h_dentry->d_sb))
+ h_file = au_h_intent(dentry, bindex, file);
+ if (!h_file)
-+ h_file = dentry_open(dget(h_dentry), mntget(br->br_mnt), flags, file->f_cred);
++ h_file = dentry_open(dget(h_dentry), mntget(br->br_mnt), flags, current_cred());
+
+ /*
+ * a dirty trick for handling FMODE_EXEC and deny_write_access().
diff -urN linux/fs/aufs/wkq.c linux-aufs/fs/aufs/wkq.c
--- linux/fs/aufs/wkq.c 1970-01-01 01:00:00.000000000 +0100
+++ linux-aufs/fs/aufs/wkq.c 2009-03-12 16:18:04.000000000 +0100
-@@ -0,0 +1,343 @@
+@@ -0,0 +1,353 @@
+/*
+ * Copyright (C) 2005-2009 Junjiro Okajima
+ *
+
+struct au_wkq *au_wkq;
+
-+
++struct au_cred {
++#ifdef CONFIG_AUFS_DLGT
++ struct cred *cred;
++#if 0 /* reserved for future use */
++ unsigned keep_capabilities:1;
++ struct user_struct *user;
++ struct fs_struct *fs;
++ struct nsproxy *nsproxy;
++#endif
++#endif
++};
+
+struct au_wkinfo {
+ struct work_struct wk;
+ struct super_block *sb;
+
+ unsigned int flags;
-+ struct cred cred;
++ struct au_cred cred;
+
+ au_wkq_func_t func;
+ void *args;
+/* ---------------------------------------------------------------------- */
+
+#ifdef CONFIG_AUFS_DLGT
-+static void cred_store(struct cred *cred)
++static void cred_store(struct au_cred *cred)
+{
+ cred = get_current_cred();
+}
+
-+static void cred_revert(struct cred *cred)
++static void cred_revert(struct au_cred *cred)
+{
+ AuDebugOn(!au_test_wkq(current));
+ revert_creds(cred);
+}
+
-+static void cred_switch(struct cred *old, struct cred *new)
++static void cred_switch(struct au_cred *old, struct au_cred *new)
+{
+ cred_store(old);
+ cred_revert(new);
+ if (!au_ftest_wkq(wkinfo->flags, DLGT))
+ wkinfo->func(wkinfo->args);
+ else {
-+ struct cred cred;
++ struct au_cred cred;
+ cred_switch(&cred, &wkinfo->cred);
+ wkinfo->func(wkinfo->args);
+ cred_revert(&cred);
diff -urN linux/fs/Makefile linux-aufs/fs/Makefile
--- linux/fs/Makefile 2009-03-12 11:25:26.000000000 +0100
+++ linux-aufs/fs/Makefile 2009-03-12 17:03:22.897115295 +0100
-@@ -89,6 +89,7 @@
- obj-$(CONFIG_HFS_FS) += hfs/
- obj-$(CONFIG_ECRYPT_FS) += ecryptfs/
- obj-$(CONFIG_UNION_FS) += unionfs/
+@@ -125,3 +125,4 @@
+ obj-$(CONFIG_BTRFS_FS) += btrfs/
+ obj-$(CONFIG_GFS2_FS) += gfs2/
+ obj-$(CONFIG_EXOFS_FS) += exofs/
+obj-$(CONFIG_AUFS) += aufs/
- obj-$(CONFIG_VXFS_FS) += freevxfs/
- obj-$(CONFIG_NFS_FS) += nfs/
- obj-$(CONFIG_EXPORTFS) += exportfs/
diff -urN linux/include/linux/aufs_type.h linux-aufs/include/linux/aufs_type.h
--- linux/include/linux/aufs_type.h 1970-01-01 01:00:00.000000000 +0100
+++ linux-aufs/include/linux/aufs_type.h 2009-03-12 16:18:04.000000000 +0100