summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/automount.c2
-rw-r--r--src/manager.h2
-rw-r--r--src/mount.c16
-rw-r--r--src/path.c2
-rw-r--r--src/service.c4
-rw-r--r--src/socket.c6
-rw-r--r--src/swap.c6
-rw-r--r--src/unit.c4
-rw-r--r--src/unit.h2
9 files changed, 22 insertions, 22 deletions
diff --git a/src/automount.c b/src/automount.c
index 33c962e0c0..51fa0030dd 100644
--- a/src/automount.c
+++ b/src/automount.c
@@ -142,7 +142,7 @@ static int automount_add_mount_links(Automount *a) {
assert(a);
- LIST_FOREACH(units_per_type, other, a->meta.manager->units_per_type[UNIT_MOUNT])
+ LIST_FOREACH(units_by_type, other, a->meta.manager->units_by_type[UNIT_MOUNT])
if ((r = automount_add_one_mount_link(a, (Mount*) other)) < 0)
return r;
diff --git a/src/manager.h b/src/manager.h
index 07b92c8e4e..4557d5f0d5 100644
--- a/src/manager.h
+++ b/src/manager.h
@@ -102,7 +102,7 @@ struct Manager {
/* To make it easy to iterate through the units of a specific
* type we maintain a per type linked list */
- LIST_HEAD(Meta, units_per_type[_UNIT_TYPE_MAX]);
+ LIST_HEAD(Meta, units_by_type[_UNIT_TYPE_MAX]);
/* Units that need to be loaded */
LIST_HEAD(Meta, load_queue); /* this is actually more a stack than a queue, but uh. */
diff --git a/src/mount.c b/src/mount.c
index 423cf434a4..660af131dc 100644
--- a/src/mount.c
+++ b/src/mount.c
@@ -114,7 +114,7 @@ static void mount_done(Unit *u) {
m->where = NULL;
/* Try to detach us from the automount unit if there is any */
- LIST_FOREACH(units_per_type, other, m->meta.manager->units_per_type[UNIT_AUTOMOUNT]) {
+ LIST_FOREACH(units_by_type, other, m->meta.manager->units_by_type[UNIT_AUTOMOUNT]) {
Automount *a = (Automount*) other;
if (a->mount == m)
@@ -166,7 +166,7 @@ static int mount_add_mount_links(Mount *m) {
/* Adds in links to other mount points that might lie below or
* above us in the hierarchy */
- LIST_FOREACH(units_per_type, other, m->meta.manager->units_per_type[UNIT_MOUNT]) {
+ LIST_FOREACH(units_by_type, other, m->meta.manager->units_by_type[UNIT_MOUNT]) {
Mount *n = (Mount*) other;
MountParameters *pn;
@@ -223,7 +223,7 @@ static int mount_add_swap_links(Mount *m) {
assert(m);
- LIST_FOREACH(units_per_type, other, m->meta.manager->units_per_type[UNIT_SWAP])
+ LIST_FOREACH(units_by_type, other, m->meta.manager->units_by_type[UNIT_SWAP])
if ((r = swap_add_one_mount_link((Swap*) other, m)) < 0)
return r;
@@ -236,7 +236,7 @@ static int mount_add_path_links(Mount *m) {
assert(m);
- LIST_FOREACH(units_per_type, other, m->meta.manager->units_per_type[UNIT_PATH])
+ LIST_FOREACH(units_by_type, other, m->meta.manager->units_by_type[UNIT_PATH])
if ((r = path_add_one_mount_link((Path*) other, m)) < 0)
return r;
@@ -249,7 +249,7 @@ static int mount_add_automount_links(Mount *m) {
assert(m);
- LIST_FOREACH(units_per_type, other, m->meta.manager->units_per_type[UNIT_AUTOMOUNT])
+ LIST_FOREACH(units_by_type, other, m->meta.manager->units_by_type[UNIT_AUTOMOUNT])
if ((r = automount_add_one_mount_link((Automount*) other, m)) < 0)
return r;
@@ -262,7 +262,7 @@ static int mount_add_socket_links(Mount *m) {
assert(m);
- LIST_FOREACH(units_per_type, other, m->meta.manager->units_per_type[UNIT_SOCKET])
+ LIST_FOREACH(units_by_type, other, m->meta.manager->units_by_type[UNIT_SOCKET])
if ((r = socket_add_one_mount_link((Socket*) other, m)) < 0)
return r;
@@ -1687,7 +1687,7 @@ void mount_fd_event(Manager *m, int events) {
log_error("Failed to reread /proc/self/mountinfo: %s", strerror(-r));
/* Reset flags, just in case, for later calls */
- LIST_FOREACH(units_per_type, meta, m->units_per_type[UNIT_MOUNT]) {
+ LIST_FOREACH(units_by_type, meta, m->units_by_type[UNIT_MOUNT]) {
Mount *mount = (Mount*) meta;
mount->is_mounted = mount->just_mounted = mount->just_changed = false;
@@ -1698,7 +1698,7 @@ void mount_fd_event(Manager *m, int events) {
manager_dispatch_load_queue(m);
- LIST_FOREACH(units_per_type, meta, m->units_per_type[UNIT_MOUNT]) {
+ LIST_FOREACH(units_by_type, meta, m->units_by_type[UNIT_MOUNT]) {
Mount *mount = (Mount*) meta;
if (!mount->is_mounted) {
diff --git a/src/path.c b/src/path.c
index c722a45377..1c20dcfed6 100644
--- a/src/path.c
+++ b/src/path.c
@@ -102,7 +102,7 @@ static int path_add_mount_links(Path *p) {
assert(p);
- LIST_FOREACH(units_per_type, other, p->meta.manager->units_per_type[UNIT_MOUNT])
+ LIST_FOREACH(units_by_type, other, p->meta.manager->units_by_type[UNIT_MOUNT])
if ((r = path_add_one_mount_link(p, (Mount*) other)) < 0)
return r;
diff --git a/src/service.c b/src/service.c
index d59c4cbad8..1f748688e2 100644
--- a/src/service.c
+++ b/src/service.c
@@ -372,7 +372,7 @@ static int sysv_fix_order(Service *s) {
/* For each pair of services where at least one lacks a LSB
* header, we use the start priority value to order things. */
- LIST_FOREACH(units_per_type, other, s->meta.manager->units_per_type[UNIT_SERVICE]) {
+ LIST_FOREACH(units_by_type, other, s->meta.manager->units_by_type[UNIT_SERVICE]) {
Service *t;
UnitDependency d;
bool special_s, special_t;
@@ -1006,7 +1006,7 @@ static int fsck_fix_order(Service *s) {
/* For each pair of services where both have an fsck priority
* we order things based on it. */
- LIST_FOREACH(units_per_type, other, s->meta.manager->units_per_type[UNIT_SERVICE]) {
+ LIST_FOREACH(units_by_type, other, s->meta.manager->units_by_type[UNIT_SERVICE]) {
Service *t;
UnitDependency d;
diff --git a/src/socket.c b/src/socket.c
index c0139587e3..8b78a3fd25 100644
--- a/src/socket.c
+++ b/src/socket.c
@@ -131,7 +131,7 @@ static void socket_done(Unit *u) {
unit_unwatch_timer(u, &s->timer_watch);
/* Make sure no service instance refers to us anymore. */
- LIST_FOREACH(units_per_type, i, u->meta.manager->units_per_type[UNIT_SERVICE]) {
+ LIST_FOREACH(units_by_type, i, u->meta.manager->units_by_type[UNIT_SERVICE]) {
Service *service = (Service *) i;
if (service->accept_socket == s)
@@ -283,7 +283,7 @@ static int socket_add_mount_links(Socket *s) {
assert(s);
- LIST_FOREACH(units_per_type, other, s->meta.manager->units_per_type[UNIT_MOUNT])
+ LIST_FOREACH(units_by_type, other, s->meta.manager->units_by_type[UNIT_MOUNT])
if ((r = socket_add_one_mount_link(s, (Mount*) other)) < 0)
return r;
@@ -1361,7 +1361,7 @@ static void socket_enter_running(Socket *s, int cfd) {
/* If there's already a start pending don't bother to
* do anything */
- LIST_FOREACH(units_per_type, i, s->meta.manager->units_per_type[UNIT_SERVICE]) {
+ LIST_FOREACH(units_by_type, i, s->meta.manager->units_by_type[UNIT_SERVICE]) {
Service *service = (Service *) i;
if (!set_get(service->configured_sockets, s))
diff --git a/src/swap.c b/src/swap.c
index 04df5854ad..14719ad18c 100644
--- a/src/swap.c
+++ b/src/swap.c
@@ -155,7 +155,7 @@ static int swap_add_mount_links(Swap *s) {
assert(s);
- LIST_FOREACH(units_per_type, other, s->meta.manager->units_per_type[UNIT_MOUNT])
+ LIST_FOREACH(units_by_type, other, s->meta.manager->units_by_type[UNIT_MOUNT])
if ((r = swap_add_one_mount_link(s, (Mount*) other)) < 0)
return r;
@@ -1100,7 +1100,7 @@ int swap_fd_event(Manager *m, int events) {
log_error("Failed to reread /proc/swaps: %s", strerror(-r));
/* Reset flags, just in case, for late calls */
- LIST_FOREACH(units_per_type, meta, m->units_per_type[UNIT_SWAP]) {
+ LIST_FOREACH(units_by_type, meta, m->units_by_type[UNIT_SWAP]) {
Swap *swap = (Swap*) meta;
swap->is_active = swap->just_activated = false;
@@ -1111,7 +1111,7 @@ int swap_fd_event(Manager *m, int events) {
manager_dispatch_load_queue(m);
- LIST_FOREACH(units_per_type, meta, m->units_per_type[UNIT_SWAP]) {
+ LIST_FOREACH(units_by_type, meta, m->units_by_type[UNIT_SWAP]) {
Swap *swap = (Swap*) meta;
if (!swap->is_active) {
diff --git a/src/unit.c b/src/unit.c
index 9bb4e56073..057431c808 100644
--- a/src/unit.c
+++ b/src/unit.c
@@ -159,7 +159,7 @@ int unit_add_name(Unit *u, const char *text) {
u->meta.id = s;
u->meta.instance = i;
- LIST_PREPEND(Meta, units_per_type, u->meta.manager->units_per_type[t], &u->meta);
+ LIST_PREPEND(Meta, units_by_type, u->meta.manager->units_by_type[t], &u->meta);
if (UNIT_VTABLE(u)->init)
UNIT_VTABLE(u)->init(u);
@@ -354,7 +354,7 @@ void unit_free(Unit *u) {
bidi_set_free(u, u->meta.dependencies[d]);
if (u->meta.type != _UNIT_TYPE_INVALID)
- LIST_REMOVE(Meta, units_per_type, u->meta.manager->units_per_type[u->meta.type], &u->meta);
+ LIST_REMOVE(Meta, units_by_type, u->meta.manager->units_by_type[u->meta.type], &u->meta);
if (u->meta.in_load_queue)
LIST_REMOVE(Meta, load_queue, u->meta.manager->load_queue, &u->meta);
diff --git a/src/unit.h b/src/unit.h
index 717c928075..1c8cf63870 100644
--- a/src/unit.h
+++ b/src/unit.h
@@ -168,7 +168,7 @@ struct Meta {
CGroupBonding *cgroup_bondings;
/* Per type list */
- LIST_FIELDS(Meta, units_per_type);
+ LIST_FIELDS(Meta, units_by_type);
/* Load queue */
LIST_FIELDS(Meta, load_queue);