subsystem: Gather list changed conditions.
Just remove the duplicated Code and make the Conditions for g_subsystems list to subsystems_list together. Signed-off-by: yidong0635 <dongx.yi@intel.com> Change-Id: I011b550b83d32580bfd25130dab9e44bcbdc1daf Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/13753 Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
c0ff46030b
commit
92a3903478
@ -111,14 +111,9 @@ subsystem_sort(void)
|
||||
}
|
||||
}
|
||||
|
||||
if (depends_on == false) {
|
||||
if (!depends_on || depends_on_sorted) {
|
||||
TAILQ_REMOVE(&g_subsystems, subsystem, tailq);
|
||||
TAILQ_INSERT_TAIL(&subsystems_list, subsystem, tailq);
|
||||
} else {
|
||||
if (depends_on_sorted == true) {
|
||||
TAILQ_REMOVE(&g_subsystems, subsystem, tailq);
|
||||
TAILQ_INSERT_TAIL(&subsystems_list, subsystem, tailq);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user