/* main header file for Linux
- * Copyright (C) 2005-2013 Red Hat Inc.
+ * Copyright (C) 2005-2014 Red Hat Inc.
* Copyright (C) 2005-2006 Intel Corporation.
*
* This file is part of systemtap, and is free software. You can
#ifdef STAPCONF_TASK_UID
#define STP_CURRENT_EUID (current->euid)
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
#define STP_CURRENT_EUID (from_kuid_munged(current_user_ns(), task_euid(current)))
#else
#define STP_CURRENT_EUID (task_euid(current))
#ifdef STAPCONF_TASK_UID
tsk_euid = tsk->euid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
tsk_euid = from_kuid_munged(current_user_ns(), task_euid(tsk));
#else
tsk_euid = task_euid(tsk);
#ifdef STAPCONF_TASK_UID
tsk_euid = tsk->euid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
tsk_euid = from_kuid_munged(current_user_ns(), task_euid(tsk));
#else
tsk_euid = task_euid(tsk);
#ifdef STAPCONF_TASK_UID
tsk_euid = tsk->euid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
tsk_euid = from_kuid_munged(current_user_ns(), task_euid(tsk));
#else
tsk_euid = task_euid(tsk);
#ifdef STAPCONF_TASK_UID
tsk_euid = tsk->euid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
tsk_euid = from_kuid_munged(current_user_ns(), task_euid(tsk));
#else
tsk_euid = task_euid(tsk);
/* -*- linux-c -*-
*
* control channel
- * Copyright (C) 2007-2011 Red Hat Inc.
+ * Copyright (C) 2007-2014 Red Hat Inc.
*
* This file is part of systemtap, and is free software. You can
* redistribute it and/or modify it under the terms of the GNU General
#ifdef STAPCONF_TASK_UID
uid_t euid = current->euid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
uid_t euid = from_kuid_munged(current_user_ns(), current_euid());
#else
uid_t euid = current_euid();
* transport.c - stp transport functions
*
* Copyright (C) IBM Corporation, 2005
- * Copyright (C) Red Hat Inc, 2005-2011
+ * Copyright (C) Red Hat Inc, 2005-2014
* Copyright (C) Intel Corporation, 2006
*
* This file is part of systemtap, and is free software. You can
_stp_uid = current->uid;
_stp_gid = current->gid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
_stp_uid = from_kuid_munged(current_user_ns(), current_uid());
_stp_gid = from_kgid_munged(current_user_ns(), current_gid());
#else
#ifdef STAPCONF_TASK_UID
STAP_RETVALUE = current->gid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
STAP_RETVALUE = from_kgid_munged(current_user_ns(), current_gid());
#else
STAP_RETVALUE = current_gid();
#ifdef STAPCONF_TASK_UID
STAP_RETVALUE = current->egid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
STAP_RETVALUE = from_kgid_munged(current_user_ns(), current_egid());
#else
STAP_RETVALUE = current_egid();
#ifdef STAPCONF_TASK_UID
STAP_RETVALUE = current->uid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
STAP_RETVALUE = from_kuid_munged(current_user_ns(), current_uid());
#else
STAP_RETVALUE = current_uid();
#ifdef STAPCONF_TASK_UID
STAP_RETVALUE = current->euid;
#else
-#ifdef CONFIG_UIDGID_STRICT_TYPE_CHECKS
+#ifdef CONFIG_USER_NS
STAP_RETVALUE = from_kuid_munged(current_user_ns(), current_euid());
#else
STAP_RETVALUE = current_euid();