From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.4 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 97D5AC433DF for ; Wed, 27 May 2020 13:27:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 749C8208C3 for ; Wed, 27 May 2020 13:27:11 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="Zwtz3KVN" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388042AbgE0N1K (ORCPT ); Wed, 27 May 2020 09:27:10 -0400 Received: from us-smtp-delivery-1.mimecast.com ([205.139.110.120]:41730 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2387867AbgE0N1E (ORCPT ); Wed, 27 May 2020 09:27:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1590586022; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rO0Xmu3kpwaS+spo70btHKk/n/bl2TDfOUNRISjvedY=; b=Zwtz3KVNBkXkOAz7DJgnrvHQF910iCD0DumL8CXrwm+AxuidxSFfM0RhTeC+ggATVChFy3 VFlVuy7lUS8/hAoKFNgHbMJzej25iaW6narm54BNj/1QRjgpaSt4P4s83CDeu0S6YKgIOL Fvydh9KyOOeBFinUXN8p0rU7UmSj9po= Received: from mail-wr1-f70.google.com (mail-wr1-f70.google.com [209.85.221.70]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-8-fEyHqr_yP4KFgCB8iB93-A-1; Wed, 27 May 2020 09:26:59 -0400 X-MC-Unique: fEyHqr_yP4KFgCB8iB93-A-1 Received: by mail-wr1-f70.google.com with SMTP id z8so11189588wrp.7 for ; Wed, 27 May 2020 06:26:59 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=rO0Xmu3kpwaS+spo70btHKk/n/bl2TDfOUNRISjvedY=; b=PjUvVnl7r9JvydMK4x0GceyDG40Xn7MstWrZXvYz6JW2Yz7AzX1rwj9lZTpD8A8kZl safweBRsSgfzTrt7ig0kkMb3WvNFEylkq+PaHu9cHmIrHeGQVnn+dXqgBc2ZxKSjK5RA bv5r/TRatMxPoZ/0wy2QhdG5+7w74l8I+Kr5hBoIbw9GqbcvFZr1rphaML4IbXL639UG fwA/vHDPu4m4BcXaFUmoD4EL76luNIsgiVF3WuLz1Zyhu3Aq7hzhtGnGnhumLK+aiwzV rnqzL9YrZtdYNj+6qBTapmE5KPRImWlwqgMAB3lpWhtkuXokOEQBPCCzafEaeY0B46ax rIHA== X-Gm-Message-State: AOAM533VU3qZnXrOsWjezJ4pnqrf4fqrKDEhyRbpTsBOyepc70LmKH9f iCHhGzfbQxU+7iws2LkmY0zyf39wSA/piRoGxC4eKd2s7/Ur+Jk/LJitfzZQuS9n7wrfkRTTs8v we/qNYLsTTOrDz/P0LByjTnPL X-Received: by 2002:adf:f582:: with SMTP id f2mr23080022wro.204.1590586018595; Wed, 27 May 2020 06:26:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzksEVrGsPk/xGJQnD5AtcYNTpqAooqkuvHIUr1bqlDBm3LvIU1wHX3ffnsooF7m2BY4wdfbQ== X-Received: by 2002:adf:f582:: with SMTP id f2mr23079984wro.204.1590586018345; Wed, 27 May 2020 06:26:58 -0700 (PDT) Received: from localhost.localdomain ([194.230.155.225]) by smtp.gmail.com with ESMTPSA id c25sm2844600wmb.44.2020.05.27.06.26.56 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 27 May 2020 06:26:57 -0700 (PDT) Subject: Re: [PATCH v3 3/7] kunit: tests for stats_fs API To: Alan Maguire Cc: kvm@vger.kernel.org, Christian Borntraeger , Paolo Bonzini , Jim Mattson , Alexander Viro , Emanuele Giuseppe Esposito , David Rientjes , Jonathan Adams , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mips@vger.kernel.org, kvm-ppc@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-s390@vger.kernel.org, linux-fsdevel@vger.kernel.org, netdev@vger.kernel.org, brendanhiggins@google.com, linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com References: <20200526110318.69006-1-eesposit@redhat.com> <20200526110318.69006-4-eesposit@redhat.com> From: Emanuele Giuseppe Esposito Message-ID: <7178ea00-cee5-d5e9-a7aa-58aa46ee416a@redhat.com> Date: Wed, 27 May 2020 15:26:55 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org >> In order to run them, the kernel .config must set CONFIG_KUNIT=y >> and a new .kunitconfig file must be created with CONFIG_STATS_FS=y >> and CONFIG_STATS_FS_TEST=y >> > > It looks like CONFIG_STATS_FS is built-in, but it exports > much of the functionality you are testing. However could the > tests also be built as a module (i.e. make CONFIG_STATS_FS_TEST > a tristate variable)? To test this you'd need to specify > CONFIG_KUNIT=m and CONFIG_STATS_FS_TEST=m, and testing would > simply be a case of "modprobe"ing the stats fs module and collecting > results in /sys/kernel/debug/kunit/ (rather > than running kunit.py). Are you relying on unexported internals in > the the tests that would prevent building them as a module? > I haven't checked it yet, but tests should work as separate module. I will look into it, thanks. Emanuele From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.0 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 88057C433E1 for ; Wed, 27 May 2020 13:29:53 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0866120899 for ; Wed, 27 May 2020 13:29:52 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="isViUrG3"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="W+9Pu+8g" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0866120899 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 49XBWx4jytzDqQt for ; Wed, 27 May 2020 23:29:49 +1000 (AEST) Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=redhat.com (client-ip=205.139.110.120; helo=us-smtp-1.mimecast.com; envelope-from=eesposit@redhat.com; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=pass (p=none dis=none) header.from=redhat.com Authentication-Results: lists.ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=isViUrG3; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=W+9Pu+8g; dkim-atps=neutral Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 49XBSr56pZzDqLT for ; Wed, 27 May 2020 23:27:07 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1590586023; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rO0Xmu3kpwaS+spo70btHKk/n/bl2TDfOUNRISjvedY=; b=isViUrG3m7kn8zMC2gaqLARWKDeM0+dRBaSX2JrNjY4bLXaWETbqWgTSkNxvCf52aX6En7 ba8Lq6nGNhV4u5d9Miql8QIaI5BFv2+YBzmk800FXOSWQGNPmE6WWEF0C+wYHf+wUEEzxq fqpaMNpSC2cpVXLddb9i8AQGG8qKA7I= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1590586024; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rO0Xmu3kpwaS+spo70btHKk/n/bl2TDfOUNRISjvedY=; b=W+9Pu+8gqJVqZM+MD03Fp7DNentCrUmemTG1i9wVZX8JYS6efAyyEf3WRCm1xT2Syih9De 6zjXXlPn4x1XfZc09AosHFewEd9RpmqzTdwpZtbQDIN/WhyefV63XuxiIxxHusn+RaY1yD H0blU6HSpJE4KCwXUvpn4k+cTc+lXXM= Received: from mail-wr1-f71.google.com (mail-wr1-f71.google.com [209.85.221.71]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-450-vmpEtpyBNz6hNNnro2hHBg-1; Wed, 27 May 2020 09:26:59 -0400 X-MC-Unique: vmpEtpyBNz6hNNnro2hHBg-1 Received: by mail-wr1-f71.google.com with SMTP id l18so6158311wrm.0 for ; Wed, 27 May 2020 06:26:59 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=rO0Xmu3kpwaS+spo70btHKk/n/bl2TDfOUNRISjvedY=; b=ABV0yPDc/9usvhi9yXgX0hUv+RP5Ltzf4/f9pDzCDE9Sx5iUPEYCNtbIaXLdPAKzsh OFitBbE+wIKXRHHa1CQs8KI/28hrK3xAVTk9YjMXigX8aPGMdnIU5Dzo04zJiSRcc9LD W9D46kT2cDBigkiW5EoOeJmJTNvhCfU9Cqc8faXTrp+nu2kx48bclA+ZbDYIzD06xqid qtB6xCAvI981+ZK1hE469Y9t3kw8vrijPPbr7GLWxCq+hc7+J1Fj0q1SMO4HbRbEtNIK oHLLlFDi57FCq1Z0ANXkf+wc/If6H8Tg5qX0T2vMklxnnsfHkMKd2XjxHml05jfzpDFg LrVg== X-Gm-Message-State: AOAM530CRMjpJ0gCQxd4jxmPgH8x51m2FYZEEdelcJ/e2QtMjecElyXk i3R0PaWlgtP4I0TEcwl09/K6VPn7LhEfD9iL4uoCS8aS6duX7OlXEtn4MbDP1OhBoAGsd/0Ccp2 fG2zxrk1QROyaPb9NYwEAx2L5/A== X-Received: by 2002:adf:f582:: with SMTP id f2mr23080010wro.204.1590586018525; Wed, 27 May 2020 06:26:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzksEVrGsPk/xGJQnD5AtcYNTpqAooqkuvHIUr1bqlDBm3LvIU1wHX3ffnsooF7m2BY4wdfbQ== X-Received: by 2002:adf:f582:: with SMTP id f2mr23079984wro.204.1590586018345; Wed, 27 May 2020 06:26:58 -0700 (PDT) Received: from localhost.localdomain ([194.230.155.225]) by smtp.gmail.com with ESMTPSA id c25sm2844600wmb.44.2020.05.27.06.26.56 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 27 May 2020 06:26:57 -0700 (PDT) Subject: Re: [PATCH v3 3/7] kunit: tests for stats_fs API To: Alan Maguire References: <20200526110318.69006-1-eesposit@redhat.com> <20200526110318.69006-4-eesposit@redhat.com> From: Emanuele Giuseppe Esposito Message-ID: <7178ea00-cee5-d5e9-a7aa-58aa46ee416a@redhat.com> Date: Wed, 27 May 2020 15:26:55 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-s390@vger.kernel.org, kvm@vger.kernel.org, linux-doc@vger.kernel.org, netdev@vger.kernel.org, kunit-dev@googlegroups.com, Emanuele Giuseppe Esposito , linux-kernel@vger.kernel.org, kvm-ppc@vger.kernel.org, Jonathan Adams , brendanhiggins@google.com, Christian Borntraeger , Alexander Viro , linux-kselftest@vger.kernel.org, David Rientjes , linux-fsdevel@vger.kernel.org, Paolo Bonzini , linux-mips@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, Jim Mattson Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" >> In order to run them, the kernel .config must set CONFIG_KUNIT=y >> and a new .kunitconfig file must be created with CONFIG_STATS_FS=y >> and CONFIG_STATS_FS_TEST=y >> > > It looks like CONFIG_STATS_FS is built-in, but it exports > much of the functionality you are testing. However could the > tests also be built as a module (i.e. make CONFIG_STATS_FS_TEST > a tristate variable)? To test this you'd need to specify > CONFIG_KUNIT=m and CONFIG_STATS_FS_TEST=m, and testing would > simply be a case of "modprobe"ing the stats fs module and collecting > results in /sys/kernel/debug/kunit/ (rather > than running kunit.py). Are you relying on unexported internals in > the the tests that would prevent building them as a module? > I haven't checked it yet, but tests should work as separate module. I will look into it, thanks. Emanuele From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.2 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B687EC433E0 for ; Wed, 27 May 2020 13:27:09 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 8A87C214D8 for ; Wed, 27 May 2020 13:27:09 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Q07gfHcQ"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="W+9Pu+8g" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8A87C214D8 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender:Content-Type: Content-Transfer-Encoding:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=oC1nhD6cAmDHadELco6aVheR/VUC+jBdkkWJNzMtEFA=; b=Q07gfHcQ12GeCKMSCORsiVZ8f mQ0PPBveB7wvZpyW+N0Dvmte96fFMI65+B1+ADniM9SzhLtmhuJmySzO73M6vr1e5uLHNJsfK92pi 1WhhBQfQx7E2UXx4LgiC9vUqxTqABijg85yHJfO6vg9pwh+xznMkn2iWkgR/Mrsyt9lwNaiJAWhnT h/R3izpCPqan5JmYUjSAa61SEgR3jHYCfnChvsddrhrudQeC/pSNFs6yWjysoE3SEgr+iF98JIFqi BmamQc+ckf8bjP23j+3s1erxdQ9Eq/cwovI5fdwjpF8TOEN3ykumejRz7SWFGDQ4Eu2d+uFjuGBY2 BogaNUZNg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jdw5N-0001zM-1M; Wed, 27 May 2020 13:27:09 +0000 Received: from us-smtp-2.mimecast.com ([207.211.31.81] helo=us-smtp-delivery-1.mimecast.com) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jdw5K-0001ye-0o for linux-arm-kernel@lists.infradead.org; Wed, 27 May 2020 13:27:07 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1590586024; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=rO0Xmu3kpwaS+spo70btHKk/n/bl2TDfOUNRISjvedY=; b=W+9Pu+8gqJVqZM+MD03Fp7DNentCrUmemTG1i9wVZX8JYS6efAyyEf3WRCm1xT2Syih9De 6zjXXlPn4x1XfZc09AosHFewEd9RpmqzTdwpZtbQDIN/WhyefV63XuxiIxxHusn+RaY1yD H0blU6HSpJE4KCwXUvpn4k+cTc+lXXM= Received: from mail-wr1-f69.google.com (mail-wr1-f69.google.com [209.85.221.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-95-LpLmUHEoN26bXglUlS6DUw-1; Wed, 27 May 2020 09:26:59 -0400 X-MC-Unique: LpLmUHEoN26bXglUlS6DUw-1 Received: by mail-wr1-f69.google.com with SMTP id n6so3485188wrv.6 for ; Wed, 27 May 2020 06:26:59 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=rO0Xmu3kpwaS+spo70btHKk/n/bl2TDfOUNRISjvedY=; b=Tb/8h7auPsmqeZX+nDmcF65x1r9ugyp7a1FEdtpmrejrST+WML8mlEXt3mKQ+2rcuN fRvqePoxPkfsO3XJlpgYdNTky6QJLfzUaxBrn8X5K01oDt8uEg3RUJh/MHhPuwylByQO T+XcozS935WpzAvlBsgfJ8AErxt7oULsM7PZRi/kNyKKalIw23iq4r8CzV5VYA2uSUIj x/NVc2ZMFakEwpTtM0CbPm5+F6rw4FwAJaEFZhJOkJgHsO/i2zJr66DrGMHxq0kddCcE /2Yn0znSINlS7P2Cx3Iyl2THTyZE841UwKtja6O6SNDyG+kQFP5pl78mgR1e/fE0bM94 2X5A== X-Gm-Message-State: AOAM531OT3armyu7pvG0wUVv1C2sakoadn8VDkg4EAeb3p2Ho56B6wZQ TNovei0wPNY6hp5E5mwXz1mpBEtN42MHuydjNgKFuWl5XySobCg9++bCxuMUL+Ge6jCOBUa0JCl em+UOu81ltr8BsBZYWiUYSzxyIXvskQeIuC4= X-Received: by 2002:adf:f582:: with SMTP id f2mr23079999wro.204.1590586018523; Wed, 27 May 2020 06:26:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzksEVrGsPk/xGJQnD5AtcYNTpqAooqkuvHIUr1bqlDBm3LvIU1wHX3ffnsooF7m2BY4wdfbQ== X-Received: by 2002:adf:f582:: with SMTP id f2mr23079984wro.204.1590586018345; Wed, 27 May 2020 06:26:58 -0700 (PDT) Received: from localhost.localdomain ([194.230.155.225]) by smtp.gmail.com with ESMTPSA id c25sm2844600wmb.44.2020.05.27.06.26.56 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 27 May 2020 06:26:57 -0700 (PDT) Subject: Re: [PATCH v3 3/7] kunit: tests for stats_fs API To: Alan Maguire References: <20200526110318.69006-1-eesposit@redhat.com> <20200526110318.69006-4-eesposit@redhat.com> From: Emanuele Giuseppe Esposito Message-ID: <7178ea00-cee5-d5e9-a7aa-58aa46ee416a@redhat.com> Date: Wed, 27 May 2020 15:26:55 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200527_062706_141838_2C08F6BC X-CRM114-Status: GOOD ( 14.49 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-s390@vger.kernel.org, kvm@vger.kernel.org, linux-doc@vger.kernel.org, netdev@vger.kernel.org, kunit-dev@googlegroups.com, Emanuele Giuseppe Esposito , linux-kernel@vger.kernel.org, kvm-ppc@vger.kernel.org, Jonathan Adams , brendanhiggins@google.com, Christian Borntraeger , Alexander Viro , linux-kselftest@vger.kernel.org, David Rientjes , linux-fsdevel@vger.kernel.org, Paolo Bonzini , linux-mips@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-arm-kernel@lists.infradead.org, Jim Mattson Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org >> In order to run them, the kernel .config must set CONFIG_KUNIT=y >> and a new .kunitconfig file must be created with CONFIG_STATS_FS=y >> and CONFIG_STATS_FS_TEST=y >> > > It looks like CONFIG_STATS_FS is built-in, but it exports > much of the functionality you are testing. However could the > tests also be built as a module (i.e. make CONFIG_STATS_FS_TEST > a tristate variable)? To test this you'd need to specify > CONFIG_KUNIT=m and CONFIG_STATS_FS_TEST=m, and testing would > simply be a case of "modprobe"ing the stats fs module and collecting > results in /sys/kernel/debug/kunit/ (rather > than running kunit.py). Are you relying on unexported internals in > the the tests that would prevent building them as a module? > I haven't checked it yet, but tests should work as separate module. I will look into it, thanks. Emanuele _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel From mboxrd@z Thu Jan 1 00:00:00 1970 From: Emanuele Giuseppe Esposito Date: Wed, 27 May 2020 13:26:55 +0000 Subject: Re: [PATCH v3 3/7] kunit: tests for stats_fs API Message-Id: <7178ea00-cee5-d5e9-a7aa-58aa46ee416a@redhat.com> List-Id: References: <20200526110318.69006-1-eesposit@redhat.com> <20200526110318.69006-4-eesposit@redhat.com> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Alan Maguire Cc: kvm@vger.kernel.org, Christian Borntraeger , Paolo Bonzini , Jim Mattson , Alexander Viro , Emanuele Giuseppe Esposito , David Rientjes , Jonathan Adams , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mips@vger.kernel.org, kvm-ppc@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-s390@vger.kernel.org, linux-fsdevel@vger.kernel.org, netdev@vger.kernel.org, brendanhiggins@google.com, linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com >> In order to run them, the kernel .config must set CONFIG_KUNIT=y >> and a new .kunitconfig file must be created with CONFIG_STATS_FS=y >> and CONFIG_STATS_FS_TEST=y >> > > It looks like CONFIG_STATS_FS is built-in, but it exports > much of the functionality you are testing. However could the > tests also be built as a module (i.e. make CONFIG_STATS_FS_TEST > a tristate variable)? To test this you'd need to specify > CONFIG_KUNIT=m and CONFIG_STATS_FS_TEST=m, and testing would > simply be a case of "modprobe"ing the stats fs module and collecting > results in /sys/kernel/debug/kunit/ (rather > than running kunit.py). Are you relying on unexported internals in > the the tests that would prevent building them as a module? > I haven't checked it yet, but tests should work as separate module. I will look into it, thanks. Emanuele