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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id E672DD6DDEC for ; Fri, 15 Nov 2024 09:03:46 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 3F3766B0082; Fri, 15 Nov 2024 04:03:46 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 37CC86B0085; Fri, 15 Nov 2024 04:03:46 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 221846B0089; Fri, 15 Nov 2024 04:03:46 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id F36116B0082 for ; Fri, 15 Nov 2024 04:03:45 -0500 (EST) Received: from smtpin25.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 76A1181084 for ; Fri, 15 Nov 2024 09:03:45 +0000 (UTC) X-FDA: 82787739888.25.F70A910 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by imf24.hostedemail.com (Postfix) with ESMTP id CBDFD180010 for ; Fri, 15 Nov 2024 09:03:36 +0000 (UTC) Authentication-Results: imf24.hostedemail.com; dkim=none; spf=pass (imf24.hostedemail.com: domain of linyunsheng@huawei.com designates 45.249.212.189 as permitted sender) smtp.mailfrom=linyunsheng@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1731661247; h=from:from:sender: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=lSlJ0mFVcSZ1OJh5WXBzsljVqeFjszoVZhdg2ZnRGAg=; b=dnacjaVyxNMeKgCk+UA7PuH19CXNawDKprZOYFebejSmQtVwz3KdsTBS0fjTObDbPVEY49 PHd0CRPRwVByJp5vT+mbNrV1WYeFRgEIYfFu4Hl/fFhP4ELex7fjlenmTQ3YT24siE/hQN 5ELKGQyaBB7M5lZBLRo1cKwz7onEgQw= ARC-Authentication-Results: i=1; imf24.hostedemail.com; dkim=none; spf=pass (imf24.hostedemail.com: domain of linyunsheng@huawei.com designates 45.249.212.189 as permitted sender) smtp.mailfrom=linyunsheng@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1731661247; a=rsa-sha256; cv=none; b=AhmVipd6LJCpCui7KmLk539yOa8GLulns+PIQqvnPheDabHqbZDv1kqZ+B3Njjm+EHMV6Z 6Nd0EcOZjKSyFXev7s8hKuxj4hirjQXzLQeFhjg7dLvGzGliWMeXmd1Q4Vx5rTHCFzC6Xe K2QRIQ8fbP9GxwbGvbNBmR0d6SRSz24= Received: from mail.maildlp.com (unknown [172.19.88.194]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4XqWHZ2Jj2zQtpf; Fri, 15 Nov 2024 17:02:18 +0800 (CST) Received: from dggpemf200006.china.huawei.com (unknown [7.185.36.61]) by mail.maildlp.com (Postfix) with ESMTPS id 2C710141045; Fri, 15 Nov 2024 17:03:35 +0800 (CST) Received: from [10.67.120.129] (10.67.120.129) by dggpemf200006.china.huawei.com (7.185.36.61) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.11; Fri, 15 Nov 2024 17:03:34 +0800 Message-ID: Date: Fri, 15 Nov 2024 17:03:34 +0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH net-next v23 1/7] mm: page_frag: add a test module for page_frag To: Mark Brown CC: , , , , , Andrew Morton , Alexander Duyck , Linux-MM , Alexander Duyck , Shuah Khan , , References: <20241028115343.3405838-1-linyunsheng@huawei.com> <20241028115343.3405838-2-linyunsheng@huawei.com> Content-Language: en-US From: Yunsheng Lin In-Reply-To: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.67.120.129] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggpemf200006.china.huawei.com (7.185.36.61) X-Rspamd-Server: rspam09 X-Rspamd-Queue-Id: CBDFD180010 X-Stat-Signature: b5wxzj7zcki6k9oawwoog77hk16srrx7 X-Rspam-User: X-HE-Tag: 1731661416-344313 X-HE-Meta: U2FsdGVkX1/LtTUf1IqbCYnLffnYUT2vTyNxNnbNdx/fkt7jV7zrW9GJYKT5NtEjxRkbw4Z6vPZK6jHvN+MzhIUni5Ng79PMPZo9uuncXfeeLRXt3tnn3dSjiXnmtxOfqgJ2SwwH79g1bhAF+ZIO1+8vW7raZFcoVAT05Mspgzm8FJKsiesEbN/mf+SwjI0oRXvbure5eBq4Juicz4lAm56pcUXM9LmxPmSPozTPZe4RJu0IBSxhUI1ikeuexXie+Pz8ROfoj/V6SX11nj3PvL5Jn8l2PdnSHZf8ycjRnOBJiNyFmbizN6bj70RYnvqep9pBqZLelz6AzP1IXiHmZti4F6xwFJHDCSiM7H1xoNZ62HPhBw3KaKn+NSBMxA4PEVoompsCi6gs3jox3hEP8yEy3vbV4FkiD7xDyO9VjebYZuN7WMHVxmNYVjgbkxUQEXIjLR4o8L7ClzGdAFQWBvpIVFaqCm2Fb8vDYqeEp2gtjfdj1b+68ldd96RbSICaqDCCAppaBuDubn19E8abZfEVW6J7Z/lIu15P2oIXi2P66H6zNxAcHLEuclUBRYkuX3MNpRMmIYxQhkbyTE2J4L/yqJCgtgxNm2PHl06nrjMAetP6OwM3bDxD7ixR9WaBrP7yRB05oR2BNuNqQ7vhWvLPiv2VooY+Z9SXTKF4QtGxx9dA6ldpizX2dIJwZYlc1orfatFYYeQEf9TnjlQUkDYIClK/WhBpCEbE8VxcZAqoGTH8MeYXfI2GbXA0ReaO/ZHQMCR3XyNdQa4R6yZOLEL3aVXCPf/AiXOawFYaGNRUzTJi+xte8RDBH9GRDKD52fEruT/p41MWRJUXxqqiCASHQ0DGev6/3DlUiUx0oWftsquJGZeVKDAjzYIgCNTRg8lxAfZKUQfpxmoejRkHLftD3+G7n4mxjI2st/w4S6aYnZa6V0L11fpPPSR89xDw791iYrum9nl5k1tsxMB B87isHat l7+hp9SFRtQSkZbIQdqDVnT7V5nyyYTiYtbOANTH1sNC64FR5LCkr3ILMgcJsj5DTc/88II5r218l5TDdg9O8kOkMwd3Z6XMVg/Nzvp/x4Xsga/xcSIHkggdKob8rjISysvJLCccUX28hfGnFKGeXRtX9xgKDbioXtI9mHo3hXI7i1z7jf13OFytZB0gyJXtZVrAG2omOUzzv9s7ZUeMwOr7GnxrvfK7ljoo7wFw5HH9xA4hd40/8eC6Z61VmjySeDmc9TlOJGU+mlhruOskbWQilMeDksBGoinNvpdLEjtLiS0PdxLpa3UxTYFF5gTwQPHNMiar6E9mLiz59PqmohYLYElERtaDVp4kmt2g4j+drm+OeCePrtQuestInNtIiRs7mkCyyf41j2diXhvLKTGWB6Q== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: On 2024/11/15 0:02, Mark Brown wrote: > On Mon, Oct 28, 2024 at 07:53:36PM +0800, Yunsheng Lin wrote: >> The testing is done by ensuring that the fragment allocated >> from a frag_frag_cache instance is pushed into a ptr_ring >> instance in a kthread binded to a specified cpu, and a kthread >> binded to a specified cpu will pop the fragment from the >> ptr_ring and free the fragment. Hi, Thanks for reporting. > > This is breaking the build in -next on at least arm64 and x86_64 since > it's trying to build an out of tree kernel module which is included in > the selftests directory, the kselftest build system just isn't set up to > do that in a sensible and robust fashion. The module should probably be I tried the below kernel modules in the testing directory, they seemed to have the similar problem if the kernel is not compiled yet. make -C tools/testing/nvdimm make -C tools/testing/selftests/bpf/bpf_testmod/ make -C tools/testing/selftests/livepatch/test_modules/ > in the main kernel tree and enabled by the config file for the mm tests. As discussed in [1], this module is not really a vaild kernel module by returning '-EAGAIN', which is the main reason that it is setup in the selftests instead of the main kernel tree. 1. https://lore.kernel.org/all/CAKgT0UdL77J4reY0JRaQfCJAxww3R=jOkHfDmkuJHSkd1uE55A@mail.gmail.com/ > > KernelCI sees: > > *** > *** Configuration file ".config" not found! > *** > *** Please run some configurator (e.g. "make oldconfig" or > *** "make menuconfig" or "make xconfig"). > *** > Makefile:810: include/config/auto.conf.cmd: No such file or directory > > (see https://storage.kernelci.org/next/master/next-20241114/x86_64/x86_64_defconfig%2Bkselftest/gcc-12/logs/kselftest.log) > > and I've seen: > > ERROR: Kernel configuration is invalid. > include/generated/autoconf.h or include/config/auto.conf are missing. > Run 'make oldconfig && make prepare' on kernel src to fix it. > > make[3]: *** [Makefile:788: include/config/auto.conf] Error 1 As above, I am not sure if there is some elegant way to avoid the above error in the selftest core, one possible way to avoid the above error is to skip compiling like below as tools/testing/selftests/mm/test_page_frag.sh already skip the testing for page_frag if the test module is not compiled: diff --git a/tools/testing/selftests/mm/page_frag/Makefile b/tools/testing/selftests/mm/page_frag/Makefile index 58dda74d50a3..ab5f457bd39e 100644 --- a/tools/testing/selftests/mm/page_frag/Makefile +++ b/tools/testing/selftests/mm/page_frag/Makefile @@ -7,6 +7,8 @@ else Q = @ endif +ifneq (,$(wildcard $(KDIR)/Module.symvers)) + MODULES = page_frag_test.ko obj-m += page_frag_test.o @@ -16,3 +18,10 @@ all: clean: +$(Q)make -C $(KDIR) M=$(PAGE_FRAG_TEST_DIR) clean + +else + +all: + $(warning Please build the kernel before building the test ko) + +endif