From 5e68649891b15e2bd0678e6a4c2183eee3c680cc Mon Sep 17 00:00:00 2001 From: Hauke Mehrtens Date: Sun, 24 Nov 2013 01:01:04 +0100 Subject: [PATCH] backports: add current_user_ns() current_user_ns() is used by seq_user_ns() if CONFIG_USER_NS is set and kernel version <= 2.6.38. This was added to the kernel in version 2.6.29. Signed-off-by: Hauke Mehrtens --- backport/backport-include/linux/cred.h | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 backport/backport-include/linux/cred.h diff --git a/backport/backport-include/linux/cred.h b/backport/backport-include/linux/cred.h new file mode 100644 index 000000000000..2fbcf0111155 --- /dev/null +++ b/backport/backport-include/linux/cred.h @@ -0,0 +1,10 @@ +#ifndef __BACKPORT_LINUX_CRED_H +#define __BACKPORT_LINUX_CRED_H +#include_next +#include + +#ifndef current_user_ns +#define current_user_ns() (current->nsproxy->user_ns) +#endif + +#endif /* __BACKPORT_LINUX_CRED_H */ -- 2.30.2