| Message ID | 20260120231814.2033069-2-sjg@u-boot.org |
|---|---|
| State | New |
| Headers |
Return-Path: <concept-bounces+u-boot-concept=u-boot.org@u-boot.org> X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768951118; bh=8FlTjAXlqG/Sc4A/3brATOqTZn9BjHJQBPUbPErIZPc=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=LwJeXo3XQesW2VjNPCkVbs3DkhWFeFmwbWay2yTGwHBqOykfuBOtH480GHwWkkl/F DP5BLnNidZKh+5udQkq7sEuehAY05DE4CouUPahiLIq3Az1Xc7sIlIpIYATzNJ1EEw bI1bQMiahMNerkzHMwxmPlcIAklgyki5ZcDAE3wEcEFJEwlq5ijdAJgs08otEvNqTb A140YJ+W3hQ8g+zW6ew10Qf9icdMks0qj7hEOlllfeUbvDaFkg0WQ/ZYm9fHitIiw5 cTlJTtRDF/SrDPb3AQ75WOYhfEbbgXGt1KysAScMfBYdHew2m/X7jWBJMPUUVnt6oP 6Ij0HXdBUVPgg== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 588AB69589 for <u-boot-concept@u-boot.org>; Tue, 20 Jan 2026 16:18:38 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id rTImhIeDv0j1 for <u-boot-concept@u-boot.org>; Tue, 20 Jan 2026 16:18:38 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768951118; bh=8FlTjAXlqG/Sc4A/3brATOqTZn9BjHJQBPUbPErIZPc=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=LwJeXo3XQesW2VjNPCkVbs3DkhWFeFmwbWay2yTGwHBqOykfuBOtH480GHwWkkl/F DP5BLnNidZKh+5udQkq7sEuehAY05DE4CouUPahiLIq3Az1Xc7sIlIpIYATzNJ1EEw bI1bQMiahMNerkzHMwxmPlcIAklgyki5ZcDAE3wEcEFJEwlq5ijdAJgs08otEvNqTb A140YJ+W3hQ8g+zW6ew10Qf9icdMks0qj7hEOlllfeUbvDaFkg0WQ/ZYm9fHitIiw5 cTlJTtRDF/SrDPb3AQ75WOYhfEbbgXGt1KysAScMfBYdHew2m/X7jWBJMPUUVnt6oP 6Ij0HXdBUVPgg== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 3EF8169583 for <u-boot-concept@u-boot.org>; Tue, 20 Jan 2026 16:18:38 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768951117; bh=PusqgzgAa41wfroRF9+/NH27LYX1xDlrDHaDmo47364=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=lm4Yd+BxFGlaR0CcYrHjNPj9Cc95i+qDmvFa3RsLE+OtcKMfvOgDgRk8yeVbI7ygQ K6t9YEWhhlMXoFAqLvJS+rCs13zj837VOaGZmTs4kRRUzFhpYJ6i8gKEcG7bnGNK6b vCEUClhZsrjK4K6pF7+2KM1wOuMnete+VktmQjsa/9PiOpw73BmxGqCvRYnJ67G27W 3ZLU6MHMtTXq7gxJQ154ux3w8qgIooBFDR1LnEGLBVZ13+eswpQd0qex7Qpr1u8NEw ZkDPHv0sj2d0SJhPOlagYEb1gLN4HaqcIH7AAV36YrLUvjFj4zBmubSzSvpXyXVZOq eSEypYTrvpBkw== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 8D29B6957E; Tue, 20 Jan 2026 16:18:37 -0700 (MST) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id PxL46tWjypXZ; Tue, 20 Jan 2026 16:18:37 -0700 (MST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1768951113; bh=UeSGs6dpKOJg6V0qTnaLnZhZMtQCLK5uNU7YTi9pj1k=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=esNcMiNd0ySk4cfM0hFxi4awKNqpc8aj/HKKnu4V0v+x2CSa8vdhoAjZHy5HO5Vus xzSBzNHYJSRrblHJPyycdzTN7plSHIpC4c9r9iWJfe5hAvUuu6YegpUlTZmAdAvlGb OKRTQmSAkGhr8bu8thNn2drII6nP/oK1+fDGPXWTt91KBLFVwy9OlqD1Zy8IuJIJ5C xHL4ipIt8Qx0+gojkwhOdyUUxVxo7RGtVOjkpJMRu1mBuBE4g4vfU0m2Xkux8oVmkN LUti1Kw1DYqrh49juFo21KC8jkm87k8AFUArK16FLNYI3bzREQntzwKSrZ9QxlETN2 kb+XaZZ/sBkxQ== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 2C15C6913F; Tue, 20 Jan 2026 16:18:33 -0700 (MST) From: Simon Glass <sjg@u-boot.org> To: U-Boot Concept <concept@u-boot.org> Date: Tue, 20 Jan 2026 16:17:28 -0700 Message-ID: <20260120231814.2033069-2-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20260120231814.2033069-1-sjg@u-boot.org> References: <20260120231814.2033069-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: SK4KDQM7FD5ACQNMTFXXG76W6WC7QB7P X-Message-ID-Hash: SK4KDQM7FD5ACQNMTFXXG76W6WC7QB7P X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Simon Glass <simon.glass@canonical.com>, "Claude Opus 4 . 5" <noreply@anthropic.com> X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH 01/36] test: Fix LUKS device-name collision in CI environments List-Id: Discussion and patches related to U-Boot Concept <concept.u-boot.org> Archived-At: <https://lists.u-boot.org/archives/list/concept@u-boot.org/message/SK4KDQM7FD5ACQNMTFXXG76W6WC7QB7P/> List-Archive: <https://lists.u-boot.org/archives/list/concept@u-boot.org/> List-Help: <mailto:concept-request@u-boot.org?subject=help> List-Owner: <mailto:concept-owner@u-boot.org> List-Post: <mailto:concept@u-boot.org> List-Subscribe: <mailto:concept-join@u-boot.org> List-Unsubscribe: <mailto:concept-leave@u-boot.org> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit |
| Series |
video: Add multiple-context support to vidconsole (part F)
|
|
Commit Message
Simon Glass
Jan. 20, 2026, 11:17 p.m. UTC
From: Simon Glass <simon.glass@canonical.com> In CI environments where process IDs are reused quickly, the LUKS device name (luks_test_<pid>) can collide with a stale device from a previous test run. This causes cryptsetup to fail with "Device already exists". Add a timestamp component to the device name to ensure uniqueness even when PIDs are reused. Co-developed-by: Claude Opus 4.5 <noreply@anthropic.com> Signed-off-by: Simon Glass <simon.glass@canonical.com> --- test/py/tests/fs_helper.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/test/py/tests/fs_helper.py b/test/py/tests/fs_helper.py index ccde6683534..269b1c2d10f 100644 --- a/test/py/tests/fs_helper.py +++ b/test/py/tests/fs_helper.py @@ -11,6 +11,7 @@ import shutil from subprocess import call, check_call, check_output, CalledProcessError, run from subprocess import DEVNULL import tempfile +import time class FsHelper: @@ -269,9 +270,11 @@ class FsHelper: 'kernel module is loaded and you have permission to use ' 'device-mapper. This is required for LUKS encryption tests.') - device_name = f'luks_test_{os.getpid()}' + # Use PID and timestamp for uniqueness in CI environments where PIDs + # get reused + device_name = f'luks_test_{os.getpid()}_{int(time.time() * 1000) % 100000}' - # Clean up any stale device with the same name + # Clean up any stale device with the same name (unlikely with timestamp) run(['sudo', 'cryptsetup', 'close', device_name], stdout=DEVNULL, stderr=DEVNULL, check=False)