Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp597802pxa; Tue, 4 Aug 2020 13:04:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwE/yHYKbknDtxzz8Odt1FCTNMOrhmlz2jAfOD+CrAYUQXcCcX8oEQL1RpBxdP0KnkiCWhs X-Received: by 2002:a50:fc02:: with SMTP id i2mr22476481edr.121.1596571491952; Tue, 04 Aug 2020 13:04:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1596571491; cv=none; d=google.com; s=arc-20160816; b=YlquAiZSDNUPfGU5Fu7obOQnCHG4MkUWjUSd6X9+scP5mqD/cwuhil+3VAdNfedN1e nTNP906evIV5wHmg8ufRaycq1FseXX+GmvprxWuRdMvl5+5ByhmxpQ38u11enDSn3RoG izdQXf5/+ebTDkKOsQi2zRPhTuqKPTQyjhvGmTZB7LkGc3Q0swLEGy76NznOQa8VshlQ 9iDTcrHu5y5/beSempOay450zLno5RMLgHT1SYuR3pE2UUSwD5aL7QlelBnpTa4YdjM2 VqeehJZnKgW7iaaZvm9i96q2RwCrzUX1NatBuV6zc86YG5OnmsJw38GeCdV9ok2Pzf1d PMhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=NGNEd3Lp8fYqN2xdgBLfWZRJYT3O7WzzWQnO9+HSxQk=; b=YBrrMpoSUeupstdE/eq94GfTzhrHIeF4VVZN2lRsJwXgYf8R9a2+mva7oUjsUobrDE nadFLqIwBjO1JqaRr5ChQlwcxyvhrtZYNL7r2ac7glbW0cmXCvrnH0jEUOy6DsYCJP3y 2HV5rRnOs0djBKqQ+IHmKCF/SzVKtY/A44fjhRV9hy+6uJOM3kllH5KMSIT8FAkE5Wou /JMH+HJ6Cs1hVrMy94O1vfFYALEp9tGb7BM/T70VX8BPUnc1EZ4rAIHQynnblGdQCETG 418gXo/zMvj1HWmJWK6EBQL5cj5jc4XmuvyrYEk+cO9bTZ5oNxVHyAdBi8rJbzfqlGjU pJkg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=GflFL1WY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i22si10420372ejf.220.2020.08.04.13.04.28; Tue, 04 Aug 2020 13:04:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=GflFL1WY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S1726878AbgHDUBp (ORCPT + 99 others); Tue, 4 Aug 2020 16:01:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52048 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726918AbgHDUBn (ORCPT ); Tue, 4 Aug 2020 16:01:43 -0400 Received: from mail-pf1-x442.google.com (mail-pf1-x442.google.com [IPv6:2607:f8b0:4864:20::442]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5CE36C06179E for ; Tue, 4 Aug 2020 13:01:43 -0700 (PDT) Received: by mail-pf1-x442.google.com with SMTP id y206so10952024pfb.10 for ; Tue, 04 Aug 2020 13:01:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=NGNEd3Lp8fYqN2xdgBLfWZRJYT3O7WzzWQnO9+HSxQk=; b=GflFL1WYfQVzQD4fL/T4jBZKh7JPXp0BjIk5sL7JE/3ZK5A3sV3xZbh/yfGVUE0qsP E8yzX9X+hsi/jPgMOXv5KyzdGbchiQfB+e6evv0M2SBqQeIpPvQCBY7+peu0nO4BLYGa rdDx5ycRqouMDJsTRzYND+Tolb/oVleKFhJtjOjIQORoJT/S/6+FUy7Kqq7ICEsZ9Bbl 0OVwDgiwpMSYG30M2rS3A8VLQOVW8i0aLpgdwxcBGN+zSp9A98eH6F083YoTKVXDwSul ItGmc4NUog48QtQq1C+v7I7SDLF2999IlOerOmbpf1fsDJ45bAYCsHylk7gjqEPEQWPz rsTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=NGNEd3Lp8fYqN2xdgBLfWZRJYT3O7WzzWQnO9+HSxQk=; b=DNpJ5x65vTkcj6peMKKhape66TuHOnx+EsCVFif1l9p/PN6vgaVG/5G4ziTAkflvXq u3bb31oAD3UtsJlDoEGaykydszTB9pYQ2IjrXp4n1J8h9MtjYqfwp9eY2buRRDkMW+dM W50RhFpyXNhQjTr/L3xREjZtv6tVwmlr7Rn3XsLQWtUGuwoC0t3GClY5UlnTHoNxah/y UrQRSBA2BgXagsfNaqkqWN/gL3gafsjcEM3WD+TRDiQHYKTzjjuqCBF7Zsw6fOQIlkA4 y7NGdQyShE37y3MyM9fSgnoVwo/d/LG6Wf+8geEYI4k9/pA1ZJAJ9mbTWh1mHUE9pL7k IzEw== X-Gm-Message-State: AOAM532PPNToFK8HbK5K5o16qKJOAcZQCgiUfkDoo0PB8+tkz7r4K9Xg 1eJ38qXsnGoRjL8rb1Rfh+taNwe++q8xrVgLxfqRng== X-Received: by 2002:a62:1d0e:: with SMTP id d14mr46991pfd.106.1596571302143; Tue, 04 Aug 2020 13:01:42 -0700 (PDT) MIME-Version: 1.0 References: <20200626210917.358969-1-brendanhiggins@google.com> <202006261442.5C245709@keescook> In-Reply-To: <202006261442.5C245709@keescook> From: Brendan Higgins Date: Tue, 4 Aug 2020 13:01:30 -0700 Message-ID: Subject: Re: [PATCH v5 00/12] kunit: create a centralized executor to dispatch all KUnit tests To: Kees Cook Cc: Jeff Dike , Richard Weinberger , Anton Ivanov , Arnd Bergmann , Shuah Khan , Alan Maguire , Iurii Zaikin , David Gow , Andrew Morton , rppt@linux.ibm.com, Frank Rowand , catalin.marinas@arm.com, will@kernel.org, Michal Simek , Michael Ellerman , Benjamin Herrenschmidt , Paul Mackerras , Chris Zankel , jcmvbkbc@gmail.com, Greg KH , Stephen Boyd , Logan Gunthorpe , Luis Chamberlain , linux-um , linux-arch@vger.kernel.org, "open list:KERNEL SELFTEST FRAMEWORK" , KUnit Development , Linux Kernel Mailing List , "open list:DOCUMENTATION" , Linux ARM , linuxppc-dev@lists.ozlabs.org, linux-xtensa@linux-xtensa.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jun 26, 2020 at 2:52 PM Kees Cook wrote: > > On Fri, Jun 26, 2020 at 02:09:05PM -0700, Brendan Higgins wrote: > > This patchset adds a centralized executor to dispatch tests rather than > > relying on late_initcall to schedule each test suite separately along > > with a couple of new features that depend on it. Sorry it took so long to reply. I got sucked into some other stuff again. > So, the new section looks fine to me (modulo the INIT_DATA change). The > plumbing to start the tests, though, I think is redundant. Why not just > add a sysctl that starts all known tests? We already have that; however, we use debugfs to start the tests - same difference. I just find it convenient to not have to build and then maintain a userland for each architecture. It's also really nice that KUnit "just works out of the box" - you don't have to download anything other than the kernel source, and you don't need to do any steps outside of just run "kuit.py run". That seems like a big advantage to me. > That way you don't need the plumbing into init/main.c, and you can have > a mode where builtin tests can be started on a fully booted system too. > > i.e. boot with "sysctl.kernel.kunit=start" or when fully booted with > "echo start > /proc/sys/kernel/kunit" > > And instead of the kunit-specific halt/reboot stuff, how about moving > /proc/sysrq-trigger into /proc/sys instead? Then you (or anything) could > do: > > sysctl.kernel.kunit=start sysctl.kernel.sysrq-trigger=b I think it might be harder to make a case for the reboot stuff without the stuff I am working on outside of this patchset. I think I will probably drop that patch from this patchset and reintroduce it later.