Skip to content

Commit 1bc2dc1

Browse files
committed
set default flow as KMS
Signed-off-by: ChunAn Wu <an.wu@canonical.com>
1 parent 6824c3d commit 1bc2dc1

1 file changed

Lines changed: 5 additions & 8 deletions

File tree

  • contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin

contrib/checkbox-ce-oem/checkbox-provider-ce-oem/bin/drm.py

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -724,7 +724,7 @@ def run_flow_kms():
724724
def main() -> int:
725725
ap = argparse.ArgumentParser()
726726
ap.add_argument(
727-
"--expect-kms",
727+
"--expect-nomodeset",
728728
action="store_true",
729729
help="Treat missing KMS pieces as FAIL (desktop expectation).",
730730
)
@@ -734,15 +734,12 @@ def main() -> int:
734734
print("[INFO] " + bullet("Kernel cmdline", cmd.get("_raw", "")))
735735

736736
nomodeset = ("nomodeset" in cmd) or (cmd.get("nomodeset") == "1")
737-
if nomodeset and args.expect_kms:
738-
print("The system run with nomodeset but we expected KMS.")
739-
return
740-
# logging.error("The system run with nomodeset but we expected KMS.")
741-
# raise SystemExit("FAIL: RPMSG channel is not created")
742-
elif nomodeset:
737+
if nomodeset and args.expect_nomodeset:
743738
run_flow_nomodeset()
744-
else:
739+
elif not nomodeset and not args.expect_nomodeset:
745740
run_flow_kms()
741+
else:
742+
raise SystemExit("[FAIL]: modeset is not correct")
746743

747744

748745
if __name__ == "__main__":

0 commit comments

Comments
 (0)