Received: by 2002:a05:6a10:2726:0:0:0:0 with SMTP id ib38csp967642pxb; Wed, 6 Apr 2022 05:34:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzC8+ljdl16iU5uquNP52Ail3zhXM61+LtuNW+ZYDg2KGRqiBUP0k04+nVm0Y1mIfPX7nHJ X-Received: by 2002:a17:902:a9c5:b0:156:32bf:b526 with SMTP id b5-20020a170902a9c500b0015632bfb526mr8560040plr.46.1649248473236; Wed, 06 Apr 2022 05:34:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649248473; cv=none; d=google.com; s=arc-20160816; b=yOBQ/iNXHMPh+PBoMX/f3K89hOZyaYprq7KWxXj9Is2WwfJHqhQ7guicU0rFURA6Wm C4I0jLP3u/B0Jk5N8vK5B9OpmRjsFT07ZtfoWkk30DBL/xcXo5oGTFVqpfdZcnefRj2P ymCw2/EEPvJKPATZWb31bh1FzU+HxYLWNOb5COF5xnOUC7GV0rvSxjazZIWleKpLeGvf MYN9YwiJlgBZeySL9GBW8sY2niP8wyKEVGYEbuZ6l4/3LfowskimxWEj+xo4iZ5fc+k2 RgDsoswsL+uJ0M6rmseU4tLLp+x65eXokHDC7XeausiBLJacOUGRiG6iNvpusWiTTTJ2 aOuQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=Quhq+ANDcyqCuN52eIRgLzLh2IoR3G+Ogb7BY7KkCbE=; b=jpqMqP6FWGMyTA/I0wgcvIqotUnJYYnmdmsW2bam4u2KHI12hmDUBWiUarIO2CtFU6 EKZZojKogmuDXFIMyR3y8P8jKXYgjdOlhErKHENWUhY+oY6cVzEGgLxxvV9vwFMf97/j 5HODVkGg6oCY3Wljeb6P8kHSsQd/vQ0vB+F+fmczRcDMV8sla/MxA5leG420R/2aBLmz EPaUa4yvBwLSZAikviYDG63w6wiG164IsqrTtzTKGTAabOjBNoCnzTFESUrSRgJj+6rj fElYXTBVpe4peTK3HEQIwCjDOXUzpAZR711SA/nu8WN89XVFd/PXfuAb53EVDsIB1O7r RCoA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@axis.com header.s=axis-central1 header.b=JfWw2js+; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=axis.com Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id pf7-20020a17090b1d8700b001c6cf2d1b0csi4823071pjb.126.2022.04.06.05.34.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 06 Apr 2022 05:34:33 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@axis.com header.s=axis-central1 header.b=JfWw2js+; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=axis.com Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id E25DC519D55; Wed, 6 Apr 2022 02:05:05 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1387074AbiDEWAo (ORCPT + 99 others); Tue, 5 Apr 2022 18:00:44 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60350 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1443917AbiDEPk2 (ORCPT ); Tue, 5 Apr 2022 11:40:28 -0400 Received: from smtp1.axis.com (smtp1.axis.com [195.60.68.17]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DF3ED14DFE5; Tue, 5 Apr 2022 07:02:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axis.com; q=dns/txt; s=axis-central1; t=1649167344; x=1680703344; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=Quhq+ANDcyqCuN52eIRgLzLh2IoR3G+Ogb7BY7KkCbE=; b=JfWw2js+sHio6dbd67N4f+BKvGcgXqC+jL6zGIBTKIXzryvcIE7qzxyL fAQhMiRTFUrAJ9Wa9Uqfp6pjIffGUKwtBeQ6kq96gPt0Rcx4I/SQa6+tq /4wesHmr64EULkm16LIV+z66YSSuwmFC/PzXL8EuTqLIbViL5BoPaBUqM MtOqJqtCNazap6UZeRrAMa2IfhYQDY98cmlHqo9nrqZ99WVlsnTUi5tsv ZAz3dFApD9DyI+D9oPjtyKzsvhacBT2JvmJ8EVp/x4TIpKfI2wC/zqp6Y 037kX7KxN0Pk+KkpeKGXDQrZUbxYVdVVHYyPgtan+kxbYXgNOylSg7HWN g==; Date: Tue, 5 Apr 2022 16:02:21 +0200 From: Vincent Whitchurch To: Mark Brown CC: , , , , , , , , , , , , , , Subject: Re: [RFC v1 09/10] regulator: tps62864: add roadtest Message-ID: <20220405140221.GC28574@axis.com> References: <20220311162445.346685-1-vincent.whitchurch@axis.com> <20220311162445.346685-10-vincent.whitchurch@axis.com> <20220317151326.GA7832@axis.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 Thu, Mar 17, 2022 at 05:53:22PM +0000, Mark Brown wrote: > On Thu, Mar 17, 2022 at 04:13:26PM +0100, Vincent Whitchurch wrote: > > On Fri, Mar 11, 2022 at 06:06:54PM +0000, Mark Brown wrote: > > > > > + @classmethod > > > > + def setUpClass(cls) -> None: > > > > + insmod("tps6286x-regulator") > > > > Shouldn't this get figured out when the device gets created in DT (if it > > > doesn't I guess the tests found a bug...)? > > > The system isn't set up to load modules automatically. The reason for > > this is to give the test cases full control of when the module is loaded > > and unload, since the tests could want to load the module with specific > > options. > > That seems like the uncommon case which could remove the module if it > explicitly needed it. Another reason was to get the tests to test module unloading since I've seen a lot of especially new driver writers forget to test that, but I realise that for most normal drivers that should be mostly covered by the fact that we test device unbinding. So I went ahead and implemented this and it seems to work. As you hinted earlier, this also means that the modalias stuff gets tested, and as we know that's been broken in the recent past for a bunch of drivers, so that's another advantage to automatic module loading, besides the boilerplate reduction in the tests.