Received: by 2002:a05:6358:111d:b0:dc:6189:e246 with SMTP id f29csp2418117rwi; Tue, 1 Nov 2022 07:30:53 -0700 (PDT) X-Google-Smtp-Source: AMsMyM6BF7Xn/KW5Y7h/dLfJaXUNYwj3/wCjjhHHesJu4KiKFI+M1/okKpxFKyM8iJ0KTvUPnbse X-Received: by 2002:aa7:c58e:0:b0:461:77b:7bd with SMTP id g14-20020aa7c58e000000b00461077b07bdmr19581844edq.387.1667313052753; Tue, 01 Nov 2022 07:30:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667313052; cv=none; d=google.com; s=arc-20160816; b=BK3rwWpAVHK8krDhN7pLjs1r0jNe9T2w2qRGn5wJ4SvMkI/2XHzBViGwasT/sPv0HH th4WK5T7WB+ndnaKSDTsy3U2iOwfyUw4Upbq5WvZtiFhP7JRcRh1h36ON/j1xvE8z6kM PXuUfJArbBXYc/TesSUAddnfzdYVNPgn8V0a/C67k5fRpcBjqX0PhBSWiDxBn/LJJIAy dktFcAsCsvKADroP7NOCGbk2hE9zWqzuYi3+Po0xjC2CXNHcwoI8pWTMxz1/89dEua3j 6FiVAjdbK3Ys/xfzSmSJ1xkQRiwscr3UHN15HupzOr1z42HnUe0Vi+gXg9OSihBHLt/b 3Cjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=dbwy8ITCoA5pOVbLQJbEcT2GDetN5uvf+3GbTAUDrCE=; b=psk3tvY5R6Jlb/4UjOet2hZzo91clcyQhQTmlfqhXwLk6CMijau/+LA9VzTclENbX7 u77DZJ1+uSc5I/pPJ6a02GhDH28AVrkqrOT2000DLYfH2FCnLQ5NwU6A7vKEqE59dmc/ uYpd1LjvY7SvCIXT9Pvjv4i3EZLy0rbGvkjOsYIHjX225pL+9o80nLkxVDXO0tq5/PXE 5EHf/o4SudTtltdoDmCILhIsGtFFIwer98q+uf8RdH3tlfRT0qltBILB8MOQvTsBj8aj /wQleSwT1MKWx72mBB0VLcNcaLwapPcimRzwobZjoOvecJcIDHOQFWSHU+mUlZfSN55u Zj5w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=miyy9c9g; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w5-20020a1709061f0500b007adacdfd08asi9700825ejj.295.2022.11.01.07.30.28; Tue, 01 Nov 2022 07:30:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=miyy9c9g; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229954AbiKAOFB (ORCPT + 96 others); Tue, 1 Nov 2022 10:05:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58606 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229531AbiKAOE6 (ORCPT ); Tue, 1 Nov 2022 10:04:58 -0400 Received: from mail-ej1-x62d.google.com (mail-ej1-x62d.google.com [IPv6:2a00:1450:4864:20::62d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 24AD51274C for ; Tue, 1 Nov 2022 07:04:57 -0700 (PDT) Received: by mail-ej1-x62d.google.com with SMTP id kt23so37221699ejc.7 for ; Tue, 01 Nov 2022 07:04:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=dbwy8ITCoA5pOVbLQJbEcT2GDetN5uvf+3GbTAUDrCE=; b=miyy9c9glmyzfufEN5otSKVrH8Sh29yFZ1xv03E4kPsejTjmnT272cRWCp5OvjvP4x MphFAonTt/sh2ROc7RuhjUQRf+ujJcwu0Pl9aUGMLh8HqQWh8CVBUd/eNRFGvpTppP6F yCGeN+9xLm/BJ/yaOc7eAIpzWCLrMTgvgu1AHRYZXyZkc0RHbI4a2IVVsngKmgUF70Wa lHP4JpVBq3+VSpKO7sTGyWDwruOcC03qrcdq19rHA2booqkm1A7FqFkW4b/gIGb9MxXC 18Oq0CpjitQmwHPVq1WJ35uwTaExIjMooXlfHdHjBZopoWXVM7V7fGG4e0V7Wl0dXLRb 6DCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=dbwy8ITCoA5pOVbLQJbEcT2GDetN5uvf+3GbTAUDrCE=; b=pxiWyGjHt8b8X4e6zTE2RiUk8Y3+tYR9/7IwU5FnEe3M4hcRXDw69zNKJcbPknTfs/ C8hIZrnqVJpy0+cYMlZ+3ziNos7KYgaCxgMwvXLyFed+HNvUpogGm7fOuZ3Y1ehFDHTe IQr30BadRKe+MfTkMmtdmYb8iMyRIAKN66Ha6aRoQ7b6TaokP65yjK89QSn5j1NjDhSb cWB5hxGcPRqUpNU6Dj6fdbBvMZ834rhrQUea4wGZDHDHrgU1VpeRPoAA1efK6CN97ah9 9CCxlboL94J1OEnS2rmu018ZjgpX04Kz95AhyMpC8Gk/kgE3rmEvCSDPzV+umLccwNY8 /OZA== X-Gm-Message-State: ACrzQf3w5X/YVyGT3NgW2nz0effU3IX1fWDkPzrtssNsAoC1hBKDbLtL hfJgPbqw7vZIG5FTAWhUAfCRgxCE2zK3AQ8KcMJ1dA== X-Received: by 2002:a17:907:74a:b0:77e:9455:b4e1 with SMTP id xc10-20020a170907074a00b0077e9455b4e1mr18364523ejb.462.1667311495135; Tue, 01 Nov 2022 07:04:55 -0700 (PDT) MIME-Version: 1.0 References: <20220829000920.38185-1-isabbasso@riseup.net> <20220829000920.38185-5-isabbasso@riseup.net> <20221101135425.3ee12c9c@maurocar-mobl2> <20221101145333.5960e6e7@maurocar-mobl2> In-Reply-To: <20221101145333.5960e6e7@maurocar-mobl2> From: Daniel Latypov Date: Tue, 1 Nov 2022 07:04:43 -0700 Message-ID: Subject: Re: [igt-dev] [PATCH i-g-t v2 4/4] tests: DRM selftests: switch to KUnit To: Mauro Carvalho Chehab Cc: Petri Latvala , Isabella Basso , Trevor Woerner , "open list:KERNEL SELFTEST FRAMEWORK" , Magali Lemes , =?UTF-8?B?TWHDrXJhIENhbmFs?= , Tales Aparecida , Brendan Higgins , Linux Kernel Mailing List , leandro.ribeiro@collabora.com, igt-dev@lists.freedesktop.org, ML dri-devel , Daniel Vetter , =?UTF-8?B?TsOtY29sYXMgRi4gUi4gQS4gUHJhZG8=?= , David Gow , Shuah Khan , =?UTF-8?Q?Andr=C3=A9_Almeida?= , KUnit Development Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-17.6 required=5.0 tests=BAYES_00,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, ENV_AND_HDR_SPF_MATCH,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, USER_IN_DEF_DKIM_WL,USER_IN_DEF_SPF_WL autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Nov 1, 2022, 6:53 AM Mauro Carvalho Chehab wrote: > > Ah, the selection is in kunit.ko itself. kunit.filter_glob, set from > > kunit.py with > > > > positional arguments: > > filter_glob Filter which KUnit test suites/tests run at boot-time, e.g. list* or list*.*del_test > > \ > > Gah, permissions are 0: > > module_param_named(filter_glob, filter_glob_param, charp, 0); > > You can't even see what filters were set via sysfs: > > $ ls /sys/module/kunit/parameters/ > stats_enabled > > So, once set, there's no way to change it. > > I wonder why this isn't 0x644. > > It sounds that, if we want to control it at runtime, we'll need to > build with kunit as module, and unload/reload it every time if/when > we want to run IGT with a different filtering ruleset. kunit.filter_glob only works on built-in tests, which is why you can only set it once atm. There is no currently no way for KUnit to run a subset of tests in modules. The module init code is here: https://elixir.bootlin.com/linux/v6.0/source/lib/kunit/test.c#L620 As you can see, that func it calls just initializes and runs all the suites: https://elixir.bootlin.com/linux/v6.0/source/lib/kunit/test.c#L589 This can of course be changed, just needs some work on the KUnit-side. Daniel