-depmod: ERROR: Found 5 modules in dependency cycles!
depmod: ERROR: Cycle detected: mod_loop_d -> mod_loop_e -> mod_loop_d
depmod: ERROR: Cycle detected: mod_loop_b -> mod_loop_c -> mod_loop_a -> mod_loop_b
+depmod: ERROR: Found 5 modules in dependency cycles!
{
const char sep[] = " -> ";
int ir = 0;
- ERR("Found %u modules in dependency cycles!\n", n_roots);
+ int num_cyclic = 0;
while (n_roots > 0) {
int is, ie;
if (m->visited) {
int i, n = 0, sz = 0;
char *buf;
+ bool is_cyclic = false;
for (i = ie - 1; i >= 0; i--) {
struct mod *loop = depmod->modules.array[edges[i]];
n++;
if (loop == m) {
sz += loop->modnamesz - 1;
+ is_cyclic = true;
break;
}
}
+ /* Current module not found in dependency list.
+ * Must be a related module. Ignore it.
+ */
+ if (!is_cyclic)
+ continue;
+
+ num_cyclic += n;
buf = malloc(sz + n * strlen(sep) + 1);
sz = 0;
}
}
}
+
+ ERR("Found %d modules in dependency cycles!\n", num_cyclic);
}
static int depmod_calculate_dependencies(struct depmod *depmod)