summaryrefslogtreecommitdiff
path: root/src/login/logind.h
diff options
context:
space:
mode:
authorSven Eden <yamakuzure@gmx.net>2017-06-14 17:39:24 +0200
committerSven Eden <yamakuzure@gmx.net>2017-06-16 10:13:01 +0200
commit6f2f5118f1ba06b7fd93a0ce6661530ea1f7e7ee (patch)
tree1481d89ff6c97a3dea56df79ffd8b24b54f0a5fb /src/login/logind.h
parentd5fe86b9254c47ef077a467746fec3b6e193ab4b (diff)
Prep v231: Move elogind specific code in login/logind.c to login/elogind.c
Diffstat (limited to 'src/login/logind.h')
-rw-r--r--src/login/logind.h15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/login/logind.h b/src/login/logind.h
index 41b48ef74..9be29ab28 100644
--- a/src/login/logind.h
+++ b/src/login/logind.h
@@ -29,7 +29,6 @@
#include "sd-bus.h"
#include "sd-event.h"
-#include "cgroup-util.h"
#include "hashmap.h"
#include "list.h"
#include "set.h"
@@ -40,7 +39,14 @@ typedef struct Manager Manager;
#include "logind-button.h"
#include "logind-device.h"
#include "logind-inhibit.h"
-#include "logind-sleep.h"
+
+/// Additional includes needed by elogind
+#include "cgroup-util.h"
+
+#if 1 /// elogind has to ident itself
+#define MANAGER_IS_SYSTEM(m) ((m)->is_system)
+#define MANAGER_IS_USER(m) (!((m)->is_system))
+#endif // 1
struct Manager {
sd_event *event;
@@ -78,8 +84,13 @@ struct Manager {
* file system */
int pin_cgroupfs_fd;
+ /* fd for handling cgroup socket if elogind is its own cgroups manager */
+ int cgroups_agent_fd;
+ sd_event_source *cgroups_agent_event_source;
+
/* Flags */
bool test_run:1;
+ bool is_system:1; /* true if elogind is its own cgroups manager */
/* Data specific to the cgroup subsystem */
CGroupMask cgroup_supported;