]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
core/taint: we know we're always running on cgv2 now
authorMike Yuan <me@yhndnzj.com>
Sun, 16 Mar 2025 14:24:18 +0000 (15:24 +0100)
committerMike Yuan <me@yhndnzj.com>
Sun, 16 Mar 2025 17:02:07 +0000 (18:02 +0100)
src/core/taint.c
src/test/test-taint.c

index b7a1c647a2bfad482e3ec91ddf95ff5014520abc..d02ad7fe53af99cb1edb86aa0192dba7fa372137 100644 (file)
@@ -52,9 +52,6 @@ char** taint_strv(void) {
         if (readlink_malloc("/var/run", &var_run) < 0 || !PATH_IN_SET(var_run, "../run", "/run"))
                 stage[n++] = "var-run-bad";
 
-        if (cg_all_unified() == 0)
-                stage[n++] = "cgroupsv1";
-
         if (clock_is_localtime(NULL) > 0)
                 stage[n++] = "local-hwclock";
 
index d9aa79dca57c948bdefa027d904e0ee255d42980..784885824c237bde2ebe38104badf0e822a133d9 100644 (file)
@@ -1,5 +1,6 @@
 /* SPDX-License-Identifier: LGPL-2.1-or-later */
 
+#include "clock-util.h"
 #include "taint.h"
 #include "tests.h"
 
@@ -8,7 +9,7 @@ TEST(taint_string) {
         assert_se(a);
         log_debug("taint string: '%s'", a);
 
-        assert_se(!!strstr(a, "cgroupsv1") == (cg_all_unified() == 0));
+        assert_se(!!strstr(a, "local-hwclock") == (clock_is_localtime(NULL) > 0));
 }
 
 DEFINE_TEST_MAIN(LOG_DEBUG);