Index: uspace/lib/c/include/ipc/sysman.h
===================================================================
--- uspace/lib/c/include/ipc/sysman.h	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/lib/c/include/ipc/sysman.h	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -67,5 +67,5 @@
 
 typedef enum {
-	STATE_EMBRYO = 0,
+	STATE_EMBRYO = 0, // embryo is orthogonal to states (again convergence to systemd...)
 	STATE_STARTING,
 	STATE_STARTED,
Index: uspace/srv/sysman/Makefile
===================================================================
--- uspace/srv/sysman/Makefile	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/Makefile	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -40,5 +40,5 @@
 	connection_broker.c \
 	connection_ctl.c \
-	dep.c \
+	edge.c \
 	job.c \
 	log.c \
Index: pace/srv/sysman/dep.c
===================================================================
--- uspace/srv/sysman/dep.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ 	(revision )
@@ -1,141 +1,0 @@
-/*
- * Copyright (c) 2015 Michal Koutny
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include <assert.h>
-#include <errno.h>
-#include <stdlib.h>
-#include <str.h>
-
-#include "dep.h"
-
-static void dep_dependency_init(unit_dependency_t *dep)
-{
-	memset(dep, 0, sizeof(*dep));
-	link_initialize(&dep->dependants);
-	link_initialize(&dep->dependencies);
-
-	dep->state = DEP_EMBRYO;
-}
-
-unit_dependency_t *dep_dependency_create(void)
-{
-	unit_dependency_t *dep = malloc(sizeof(unit_dependency_t));
-	if (dep) {
-		dep_dependency_init(dep);
-	}
-	return dep;
-}
-
-void dep_dependency_destroy(unit_dependency_t **dep_ptr)
-{
-	unit_dependency_t *dep = *dep_ptr;
-	if (dep == NULL) {
-		return;
-	}
-
-	list_remove(&dep->dependencies);
-	list_remove(&dep->dependants);
-
-	free(dep->dependency_name);
-	free(dep);
-
-	*dep_ptr = NULL;
-}
-
-int dep_sprout_dependency(unit_t *dependant, const char *dependency_name)
-{
-	unit_dependency_t *dep = dep_dependency_create();
-	int rc;
-
-	if (dep == NULL) {
-		rc = ENOMEM;
-		goto finish;
-	}
-
-	dep->dependency_name = str_dup(dependency_name);
-	if (dep->dependency_name == NULL) {
-		rc = ENOMEM;
-		goto finish;
-	}
-
-	list_append(&dep->dependencies, &dependant->dependencies);
-	dep->dependant = dependant;
-
-	rc = EOK;
-
-finish:
-	if (rc != EOK) {
-		dep_dependency_destroy(&dep);
-	}
-	return rc;
-}
-
-void dep_resolve_dependency(unit_dependency_t *dep, unit_t *unit)
-{
-	assert(dep->dependency == NULL);
-	assert(dep->dependency_name != NULL);
-
-	// TODO add to other side dependants list
-	dep->dependency = unit;
-	free(dep->dependency_name);
-	dep->dependency_name = NULL;
-}
-
-
-/**
- * @return        EOK on success
- * @return        ENOMEM
- */
-int dep_add_dependency(unit_t *dependant, unit_t *dependency)
-{
-	unit_dependency_t *dep = dep_dependency_create();
-	if (dep == NULL) {
-		return ENOMEM;
-	}
-
-	// TODO check existence of the dep
-	// TODO locking
-	// TODO check types and states of connected units
-	list_append(&dep->dependants, &dependency->dependants);
-	list_append(&dep->dependencies, &dependant->dependencies);
-
-	dep->dependant = dependant;
-	dep->dependency = dependency;
-	return EOK;
-}
-
-/** Remove dependency from dependency graph
- *
- * Given dependency is removed from graph and unallocated.
- */
-void dep_remove_dependency(unit_dependency_t **dep_ptr)
-{
-	// TODO here should be some checks, othewise replace this wrapper with
-	//      direct destroy
-	dep_dependency_destroy(dep_ptr);
-}
Index: pace/srv/sysman/dep.h
===================================================================
--- uspace/srv/sysman/dep.h	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ 	(revision )
@@ -1,82 +1,0 @@
-/*
- * Copyright (c) 2015 Michal Koutny
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * - Redistributions of source code must retain the above copyright
- *   notice, this list of conditions and the following disclaimer.
- * - Redistributions in binary form must reproduce the above copyright
- *   notice, this list of conditions and the following disclaimer in the
- *   documentation and/or other materials provided with the distribution.
- * - The name of the author may not be used to endorse or promote products
- *   derived from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef SYSMAN_DEP_H
-#define SYSMAN_DEP_H
-
-#include <adt/list.h>
-
-#include "unit.h"
-
-typedef enum {
-	DEP_EMBRYO,
-	DEP_VALID
-} dependency_state_t;
-
-/** Dependency edge between unit in dependency graph
- *
- * @code
- * dependant ---> dependency
- * @endcode
- *
- */
-typedef struct {
-	/** Link to dependants list */
-	link_t dependants;
-	/** Link to dependencies list */
-	link_t dependencies;
-
-	dependency_state_t state;
-
-	/** Unit that depends on another */
-	unit_t *dependant;
-
-	/** Unit that is dependency for another */
-	unit_t *dependency;
-
-	/** Name of the dependency unit, for resolved dependencies it's NULL
-	 *
-	 * @note Either dependency or dependency_name is set. Never both nor
-	 *       none.
-	 */
-	char *dependency_name;
-} unit_dependency_t;
-
-extern unit_dependency_t *dep_dependency_create(void);
-extern void dep_dependency_destroy(unit_dependency_t **);
-
-extern int dep_sprout_dependency(unit_t *, const char *);
-extern void dep_resolve_dependency(unit_dependency_t *, unit_t *);
-
-extern int dep_add_dependency(unit_t *, unit_t *);
-extern void dep_remove_dependency(unit_dependency_t **);
-
-
-#endif
-
-
Index: uspace/srv/sysman/edge.c
===================================================================
--- uspace/srv/sysman/edge.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
+++ uspace/srv/sysman/edge.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -0,0 +1,139 @@
+/*
+ * Copyright (c) 2015 Michal Koutny
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * - Redistributions of source code must retain the above copyright
+ *   notice, this list of conditions and the following disclaimer.
+ * - Redistributions in binary form must reproduce the above copyright
+ *   notice, this list of conditions and the following disclaimer in the
+ *   documentation and/or other materials provided with the distribution.
+ * - The name of the author may not be used to endorse or promote products
+ *   derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include <assert.h>
+#include <errno.h>
+#include <stdlib.h>
+#include <str.h>
+
+#include "edge.h"
+
+static void edge_init(unit_edge_t *e)
+{
+	memset(e, 0, sizeof(*e));
+	link_initialize(&e->edges_in);
+	link_initialize(&e->edges_out);
+}
+
+unit_edge_t *edge_create(void)
+{
+	unit_edge_t *e = malloc(sizeof(unit_edge_t));
+	if (e) {
+		edge_init(e);
+	}
+	return e;
+}
+
+void edge_destroy(unit_edge_t **e_ptr)
+{
+	unit_edge_t *e = *e_ptr;
+	if (e == NULL) {
+		return;
+	}
+
+	list_remove(&e->edges_in);
+	list_remove(&e->edges_out);
+
+	free(e->output_name);
+	free(e);
+
+	*e_ptr = NULL;
+}
+
+int edge_sprout_out(unit_t *input, const char *output_name)
+{
+	unit_edge_t *e = edge_create();
+	int rc;
+
+	if (e == NULL) {
+		rc = ENOMEM;
+		goto finish;
+	}
+
+	e->output_name = str_dup(output_name);
+	if (e->output_name == NULL) {
+		rc = ENOMEM;
+		goto finish;
+	}
+
+	list_append(&e->edges_out, &input->edges_out);
+	e->input = input;
+
+	rc = EOK;
+
+finish:
+	if (rc != EOK) {
+		edge_destroy(&e);
+	}
+	return rc;
+}
+
+void edge_resolve_output(unit_edge_t *e, unit_t *unit)
+{
+	assert(e->output == NULL);
+	assert(e->output_name != NULL);
+
+	// TODO add to other side edges_in list
+	e->output = unit;
+	free(e->output_name);
+	e->output_name = NULL;
+}
+
+
+/**
+ * @return        EOK on success
+ * @return        ENOMEM
+ */
+int edge_connect(unit_t *input, unit_t *output)
+{
+	unit_edge_t *e = edge_create();
+	if (e == NULL) {
+		return ENOMEM;
+	}
+
+	// TODO check existence of the e
+	// TODO locking
+	// TODO check types and states of connected units
+	list_append(&e->edges_in, &output->edges_in);
+	list_append(&e->edges_out, &input->edges_out);
+
+	e->input = input;
+	e->output = output;
+	return EOK;
+}
+
+/** Remove output from output graph
+ *
+ * Given output is removed from graph and unallocated.
+ */
+void edge_remove(unit_edge_t **e_ptr)
+{
+	// TODO here should be some checks, othewise replace this wrapper with
+	//      direct destroy
+	edge_destroy(e_ptr);
+}
Index: uspace/srv/sysman/edge.h
===================================================================
--- uspace/srv/sysman/edge.h	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
+++ uspace/srv/sysman/edge.h	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -0,0 +1,76 @@
+/*
+ * Copyright (c) 2015 Michal Koutny
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * - Redistributions of source code must retain the above copyright
+ *   notice, this list of conditions and the following disclaimer.
+ * - Redistributions in binary form must reproduce the above copyright
+ *   notice, this list of conditions and the following disclaimer in the
+ *   documentation and/or other materials provided with the distribution.
+ * - The name of the author may not be used to endorse or promote products
+ *   derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef SYSMAN_EDGE_H
+#define SYSMAN_EDGE_H
+
+#include <adt/list.h>
+
+#include "unit.h"
+
+/** Dependency edge between units in dependency graph
+ *
+ * @code
+ * input ---> output
+ * @endcode
+ *
+ */
+typedef struct {
+	/** Link to edges_out list */
+	link_t edges_in;
+	/** Link to edges_out list */
+	link_t edges_out;
+
+	bool commited;
+
+	/** Unit that depends on another */
+	unit_t *input;
+
+	/** Unit that is dependency for another */
+	unit_t *output;
+
+	/** Name of the output unit, for resolved edges it's NULL
+	 *
+	 * @note Either output or output_nameis set. Never both nor none.
+	 */
+	char *output_name;
+} unit_edge_t;
+
+extern unit_edge_t *edge_create(void);
+extern void edge_destroy(unit_edge_t **);
+
+extern int edge_sprout_out(unit_t *, const char *);
+extern void edge_resolve_output(unit_edge_t *, unit_t *);
+
+extern int edge_connect(unit_t *, unit_t *);
+extern void edge_remove(unit_edge_t **);
+
+
+#endif
+
+
Index: uspace/srv/sysman/job.c
===================================================================
--- uspace/srv/sysman/job.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/job.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -33,5 +33,5 @@
 
 #include "repo.h"
-#include "dep.h"
+#include "edge.h"
 #include "job.h"
 #include "log.h"
@@ -411,6 +411,6 @@
 		 * appropriate jobs (currently "After" only).
 		 */
-		list_foreach(unit->dependencies, dependencies, unit_dependency_t, dep) {
-			unit_t *u = dep->dependency;
+		list_foreach(unit->edges_out, edges_out, unit_edge_t, e) {
+			unit_t *u = e->output;
 			job_t *blocking_job;
 
Index: uspace/srv/sysman/main.c
===================================================================
--- uspace/srv/sysman/main.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/main.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -40,5 +40,5 @@
 #include "connection_broker.h"
 #include "connection_ctl.h"
-#include "dep.h"
+#include "edge.h"
 #include "job.h"
 #include "log.h"
@@ -137,10 +137,10 @@
 	repo_add_unit(tgt_init);
 
-	rc = dep_add_dependency(tgt_init, cfg_init);
+	rc = edge_connect(tgt_init, cfg_init);
 	if (rc != EOK) {
 		goto rollback;
 	}
 
-	rc = dep_add_dependency(cfg_init, mnt_initrd);
+	rc = edge_connect(cfg_init, mnt_initrd);
 	if (rc != EOK) {
 		goto rollback;
Index: uspace/srv/sysman/repo.c
===================================================================
--- uspace/srv/sysman/repo.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/repo.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -35,5 +35,5 @@
 
 #include "repo.h"
-#include "dep.h"
+#include "edge.h"
 #include "log.h"
 
@@ -148,13 +148,10 @@
 {
 	unit_t *unit = hash_table_get_inst(ht_link, unit_t, units_by_name);
-	// TODO state locking?
 	if (unit->state == STATE_EMBRYO) {
 		unit->state = STATE_STOPPED;
 	}
 
-	list_foreach(unit->dependencies, dependencies, unit_dependency_t, dep) {
-		if (dep->state == DEP_EMBRYO) {
-			dep->state = DEP_VALID;
-		}
+	list_foreach(unit->edges_out, edges_out, unit_edge_t, e) {
+		e->commited = true;
 	}
 	return true;
@@ -177,9 +174,9 @@
 	unit_t *unit = hash_table_get_inst(ht_link, unit_t, units_by_name);
 
-	list_foreach_safe(unit->dependencies, cur_link, next_link) {
-		unit_dependency_t *dep =
-		    list_get_instance(cur_link, unit_dependency_t, dependencies);
-		if (dep->state == DEP_EMBRYO) {
-			dep_remove_dependency(&dep);
+	list_foreach_safe(unit->edges_out, cur_link, next_link) {
+		unit_edge_t *e =
+		    list_get_instance(cur_link, unit_edge_t, edges_out);
+		if (!e->commited) {
+			edge_remove(&e);
 		}
 	}
@@ -210,21 +207,21 @@
 	unit_t *unit = hash_table_get_inst(ht_link, unit_t, units_by_name);
 
-	list_foreach(unit->dependencies, dependencies, unit_dependency_t, dep) {
-		assert(dep->dependant == unit);
-		assert((dep->dependency != NULL) != (dep->dependency_name != NULL));
-		if (dep->dependency) {
+	list_foreach(unit->edges_out, edges_out, unit_edge_t, e) {
+		assert(e->input == unit);
+		assert((e->output != NULL) != (e->output_name != NULL));
+		if (e->output) {
 			continue;
 		}
 
-		unit_t *dependency =
-		    repo_find_unit_by_name(dep->dependency_name);
-		if (dependency == NULL) {
+		unit_t *output =
+		    repo_find_unit_by_name(e->output_name);
+		if (output == NULL) {
 			sysman_log(LVL_ERROR,
 			    "Cannot resolve dependency of '%s' to unit '%s'",
-			    unit_name(unit), dep->dependency_name);
+			    unit_name(unit), e->output_name);
 			*has_error_ptr = true;
 			// TODO should we just leave the sprout untouched?
 		} else {
-			dep_resolve_dependency(dep, dependency);
+			edge_resolve_output(e, output);
 		}
 	}
@@ -238,5 +235,5 @@
  * @return ENOENT  when one or more resolution fails, information is logged
  */
-int repo_resolve_dependecies(void)
+int repo_resolve_references(void)
 {
 	sysman_log(LVL_DEBUG2, "%s", __func__);
Index: uspace/srv/sysman/repo.h
===================================================================
--- uspace/srv/sysman/repo.h	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/repo.h	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -47,5 +47,5 @@
 extern void repo_rollback(void);
 
-extern int repo_resolve_dependecies(void);
+extern int repo_resolve_references(void);
 
 extern unit_t *repo_find_unit_by_name(const char *);
Index: uspace/srv/sysman/test/job_closure.c
===================================================================
--- uspace/srv/sysman/test/job_closure.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/test/job_closure.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -140,7 +140,7 @@
 	 * u0 -> u1 -> u2 -> u3
 	 */
-	mock_add_dependency(u0, u1);
-	mock_add_dependency(u1, u2);
-	mock_add_dependency(u2, u3);
+	mock_add_edge(u0, u1);
+	mock_add_edge(u1, u2);
+	mock_add_edge(u2, u3);
 
 	/* Intentionally omit u0 */
@@ -172,7 +172,7 @@
 	 *          \-> u3
 	 */
-	mock_add_dependency(u0, u1);
-	mock_add_dependency(u1, u2);
-	mock_add_dependency(u1, u3);
+	mock_add_edge(u0, u1);
+	mock_add_edge(u1, u2);
+	mock_add_edge(u1, u3);
 
 	job_t *main_job = job_create(u1, STATE_STARTED);
@@ -204,8 +204,8 @@
 	 *          \-> u3
 	 */
-	mock_add_dependency(u0, u1);
-	mock_add_dependency(u1, u2);
-	mock_add_dependency(u1, u3);
-	mock_add_dependency(u2, u3);
+	mock_add_edge(u0, u1);
+	mock_add_edge(u1, u2);
+	mock_add_edge(u1, u3);
+	mock_add_edge(u2, u3);
 
 	job_t *main_job = job_create(u1, STATE_STARTED);
Index: uspace/srv/sysman/test/job_queue.c
===================================================================
--- uspace/srv/sysman/test/job_queue.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/test/job_queue.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -131,9 +131,9 @@
 
 	/* All services require root fs */
-	mock_add_dependency(s0, m0);
-	mock_add_dependency(s1, m0);
+	mock_add_edge(s0, m0);
+	mock_add_edge(s1, m0);
 	
 	/* S1 requires another mount and S0 */
-	mock_add_dependency(s1, s0);
+	mock_add_edge(s1, s0);
 
 	/* Enforce initial state */
Index: uspace/srv/sysman/test/mock_unit.c
===================================================================
--- uspace/srv/sysman/test/mock_unit.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/test/mock_unit.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -29,5 +29,5 @@
 #include <assert.h>
 
-#include "../dep.h"
+#include "../edge.h"
 
 #include "mock_unit.h"
@@ -76,13 +76,13 @@
 }
 
-void mock_add_dependency(unit_t *dependant, unit_t *dependency)
+void mock_add_edge(unit_t *input, unit_t *output)
 {
-	int rc = dep_add_dependency(dependant, dependency);
+	int rc = edge_connect(input, output);
 	assert(rc == EOK);
 
-	link_t *link = list_last(&dependant->dependencies);
-	unit_dependency_t *dep =
-	    list_get_instance(link, unit_dependency_t, dependencies);
-	dep->state = DEP_VALID;
+	link_t *link = list_last(&input->edges_out);
+	unit_edge_t *e =
+	    list_get_instance(link, unit_edge_t, edges_out);
+	e->commited = true;
 }
 
Index: uspace/srv/sysman/test/mock_unit.h
===================================================================
--- uspace/srv/sysman/test/mock_unit.h	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/test/mock_unit.h	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -46,5 +46,5 @@
 
 extern void mock_set_units_state(unit_state_t state);
-extern void mock_add_dependency(unit_t *dependant, unit_t *dependency);
+extern void mock_add_edge(unit_t *, unit_t *);
 
 extern int mock_unit_vmt_start_sync(unit_t *);
Index: uspace/srv/sysman/unit.c
===================================================================
--- uspace/srv/sysman/unit.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/unit.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -39,5 +39,5 @@
 #include <sysman/unit.h>
 
-#include "dep.h"
+#include "edge.h"
 #include "log.h"
 #include "sysman.h"
@@ -72,6 +72,6 @@
 	link_initialize(&unit->units);
 	link_initialize(&unit->bfs_link);
-	list_initialize(&unit->dependants);
-	list_initialize(&unit->dependencies);
+	list_initialize(&unit->edges_in);
+	list_initialize(&unit->edges_out);
 
 	UNIT_VMT(unit)->init(unit);
@@ -159,4 +159,5 @@
 }
 
+// TODO move to libsysman
 unit_type_t unit_type_name_to_type(const char *type_name)
 {
@@ -199,5 +200,5 @@
 
 	while ((cur_tok = str_tok(to_split, " ", &to_split))) {
-		if (dep_sprout_dependency(unit, cur_tok) != EOK) {
+		if (edge_sprout_out(unit, cur_tok) != EOK) {
 			result = false;
 			goto finish;
Index: uspace/srv/sysman/unit.h
===================================================================
--- uspace/srv/sysman/unit.h	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/unit.h	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -74,6 +74,6 @@
 	unit_state_t state;
 
-	list_t dependencies;
-	list_t dependants;
+	list_t edges_in;
+	list_t edges_out;
 } unit_t;
 
Index: uspace/srv/sysman/units/unit_cfg.c
===================================================================
--- uspace/srv/sysman/units/unit_cfg.c	(revision af923091a195e92212b03425f9d384e6b59c4dc5)
+++ uspace/srv/sysman/units/unit_cfg.c	(revision 9532981c809e6450c3fe6b10fecbed3683acb15c)
@@ -182,5 +182,5 @@
 	closedir(dir);
 
-	int rc = repo_resolve_dependecies();
+	int rc = repo_resolve_references();
 	if (rc != EOK) {
 		repo_rollback();
