kolibrios/drivers/include/linux/uidgid.h
Sergey Semyonov (Serge) 66fbaa74b0 ddk: v4.6.7
git-svn-id: svn://kolibrios.org@7143 a494cfbc-eb01-0410-851d-a64ba20cac60
2018-02-02 14:53:42 +00:00

28 lines
726 B
C

#ifndef _LINUX_UIDGID_H
#define _LINUX_UIDGID_H
/*
* A set of types for the internal kernel types representing uids and gids.
*
* The types defined in this header allow distinguishing which uids and gids in
* the kernel are values used by userspace and which uid and gid values are
* the internal kernel values. With the addition of user namespaces the values
* can be different. Using the type system makes it possible for the compiler
* to detect when we overlook these differences.
*
*/
#include <linux/types.h>
typedef struct {
uid_t val;
} kuid_t;
typedef struct {
gid_t val;
} kgid_t;
#define KUIDT_INIT(value) (kuid_t){ value }
#define KGIDT_INIT(value) (kgid_t){ value }
#endif /* _LINUX_UIDGID_H */