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.6 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,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 96CB8C433DF for ; Wed, 27 May 2020 21:46:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 6FB3D20B80 for ; Wed, 27 May 2020 21:46:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1590615974; bh=o/19GIssmexZ2dq1VzI9u5wRihhIkIqyBJzab36Gty4=; h=Subject:To:Cc:References:From:Date:In-Reply-To:List-ID:From; b=VQJzipoKQwMuoxTVLYEtJOfMO7oc+yuGjSzE6PnSOuwdZ8pbmcWhccQSy3rZeRTnq 2zPaAF/Xq6noVeCRaiabfMNaqkqhRxVJxIZgphk/OZOvust4VIdEx9o9nwo+w5S2Y5 pK1LuDgh61gpggRJjhm5rHxaZ51iUqM8k73FfwHM= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726815AbgE0VqO (ORCPT ); Wed, 27 May 2020 17:46:14 -0400 Received: from mail.kernel.org ([198.145.29.99]:57164 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726787AbgE0VqN (ORCPT ); Wed, 27 May 2020 17:46:13 -0400 Received: from [192.168.1.112] (c-24-9-64-241.hsd1.co.comcast.net [24.9.64.241]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 168622075A; Wed, 27 May 2020 21:46:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1590615973; bh=o/19GIssmexZ2dq1VzI9u5wRihhIkIqyBJzab36Gty4=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=TPuQfDUJ7N4BGc2epf1p/AgWw208vbe+698oJ0WKbimrTDS5uM7qcc7AZYktiMlF3 6OsEB56g8ZaM2gt6R/Yq3w7YCKfvCNDm9vr52gZPYIqBVHh2OUglvFz39CAhzQxcT+ zi0dhy/+jyLwqldZOdc5JghdB69QqwmivEHS8ioU= Subject: Re: kselftest OOT run_tests To: Yauheni Kaliuta Cc: Masahiro Yamada , "open list:KERNEL SELFTEST FRAMEWORK" , bpf , shuah References: <07bb723f-8174-5373-6715-65b61942080c@kernel.org> From: shuah Message-ID: <788d61a2-8471-a6b2-8ab6-d4af386c2884@kernel.org> Date: Wed, 27 May 2020 15:46:12 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.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: bpf-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: bpf@vger.kernel.org On 5/27/20 12:40 PM, Yauheni Kaliuta wrote: > On Wed, May 27, 2020 at 9:22 PM shuah wrote: >> >> On 5/27/20 1:30 AM, Yauheni Kaliuta wrote: >>> Hi, shuah! >>> >>>>>>>> On Tue, 26 May 2020 11:13:29 -0600, shuah wrote: >>> >>> > On 5/25/20 7:55 AM, Yauheni Kaliuta wrote: >>> >> Hi! >>> >> >>> >> I'm wondering how out of tree check is supposed to work for make >>> >> O=dir run_tests from selftests (or make -C ...) directory? >>> >> >>> >> (both with 051f278e9d81 ("kbuild: replace KBUILD_SRCTREE with >>> >> boolean building_out_of_srctree") and without) >>> >> >>> >> make M= ... does not work with run_tests. >>> >> >>> >>> > Kselftests run_tests target isn't intended for building and >>> > running tests OOT. >>> >>> But there is code there trying to handle it. All that OUTPUT >>> related things must be removed if it's broken, right? Can I post >>> a patch? >>> >>> > Also make M= doesn't make sense for them. >>> >>> Well, M=... at least includes all the makefiles. >>> >>> > There is no support to build OOT at the moment. I would like >>> > to get a better understanding of your use-case. Can you >>> > elaborate? >>> >>> I care about make install actually. But fixing it I had to deal >>> with OUTPUT. Looking a proper for that I found that it's a bit >>> broken. >>> >>> >> >> kselftest supports install of all all tests and a sub-set of tests >> both native and cross-builds. >> >> Simple case: >> If you want to build all tests and install to $HOME/install/ >> This has a dependency on kernel being built in the source repo >> you are running the following install command from: >> >> In Kernel source root dir run: >> make kselftest-install O=$HOME/install >> >> You will find installed tests with run script to run them all >> under $HOME/install/kselftest/kselftest_install/ >> >> If you run run_kselftest.sh under kselftest_install, it will run >> all the tests. >> >> You can use TARGETS var to build a sub-set of tests. >> >> In Kernel source root dir run: >> make kselftest-install TARGETS=bpf O=$HOME/install >> > > Have you tried it with the recent bpf tree? ;) > > (BTW, it is a bit misleading, it's building there, not installing). > It doesn't build for me on Linux 5.7-rc7 - install is another story bpf install through kselftest-install hasn't been working for a while. bpf test has dependency bpftool and its Makefile is more complex as a result. thanks, -- Shuah