Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp3435538pxb; Mon, 16 Nov 2020 14:52:09 -0800 (PST) X-Google-Smtp-Source: ABdhPJwXKmfC0ZCSGmWGrVuCKU899nPfQDquaX9spmPAyu26hBoUKHFvpt/sod4HAYRIdxxmxBQ2 X-Received: by 2002:a50:858a:: with SMTP id a10mr12844719edh.190.1605567129138; Mon, 16 Nov 2020 14:52:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605567129; cv=none; d=google.com; s=arc-20160816; b=RgMDDjI2ZMcs0qeOh3P6jhaOP0XHfD8y9dXEYm9tiVcv/KWmd77z3Z8PlYaIe2K3eJ wWLLwMSZDdP8LhqSMZAerFEVWvmfYcLS1FVhKzMpPwRR5uamj7SmwliCVFGtkMR7zC65 wyEgMIo0tTEdkrwOMd/zZqazM3O7p6wpr4FUM5BuGWoNeUhdf13+K7kKO8g7K7yizjCE OO3YuMqi03Ay4i4hsj1p8HgA0RH41UbK/9P/55nA2GxvmI0V5t5oFSTeAW9zWqxNkH/H zqe4Wn4TEU+QH6JkS5YvoAUtI5f5+Rn4Tdlunr5k0o3NG1CPWoQz+oDogVzMyJAkBg52 0Nvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=W6s3RsL1+Pv3zw5nuaAWroFuty/3B4F4bAkGdMnhnOc=; b=cj0Dd2BasSegKh/yxRyq82x/07vaxF6HKp23/QJLSnXw+rn5vid4PxmD7b1L682Kip BiXp/bpDrGH/xBNHgt4PheduaYI/3ltW741Cw0tqcr2Pmnx+SQu2Y4+pQhKZhYenS8Pa FJs2/FXIZxc/WaRDb/H7+8Pcnjq+wy5f/TkfOcp8ji6YGEiBeFPwKlh/3YFGjjITK4u+ Jjb/thOHzPPpWXGRpoi3bJsML50uhhP9e2nSHSvNxBUG6L/8i1jpFS1vDRHKdfIwI8S7 JxfP/OAuYfNPG9FHS9vjGS8MT3LMefPsIgwWtaXN84UBkvlYdqOu1AdCZRyHiIovbytW PILg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="gag1Zu/O"; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d17si54525edv.208.2020.11.16.14.51.46; Mon, 16 Nov 2020 14:52:09 -0800 (PST) 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=@kernel.org header.s=default header.b="gag1Zu/O"; 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=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728142AbgKPVYS (ORCPT + 99 others); Mon, 16 Nov 2020 16:24:18 -0500 Received: from mail.kernel.org ([198.145.29.99]:55434 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726035AbgKPVYR (ORCPT ); Mon, 16 Nov 2020 16:24:17 -0500 Received: from kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com (unknown [163.114.132.5]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 79B8220A8B; Mon, 16 Nov 2020 21:24:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1605561857; bh=3VnnvbQxkgfASwo/IG6GbeA05RjPoW7wuXX55oj4FDU=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=gag1Zu/ORHuCHgWwv+NvGvtK9SMbAuDQuCCkYwWURW/O5fvAraeWSGljpFBivRDFq m4oZBpreeRID81fgbwaJBLu2ijOpHjy58kcBNol1jlmGu3H4+SzSuomMr3bB/PJFNO 1oGbBVN9LWBk0HKekCNMlBufYcH54yO6hh5RgBz4= Date: Mon, 16 Nov 2020 13:24:15 -0800 From: Jakub Kicinski To: Andrii Nakryiko Cc: "Allan, Bruce W" , Song Liu , Andrii Nakryiko , bpf , Networking , "Starovoitov, Alexei" , Daniel Borkmann , Kernel Team , open list , "rafael@kernel.org" , "jeyu@kernel.org" , Arnaldo Carvalho de Melo , Greg Kroah-Hartman , Masahiro Yamada Subject: Re: [PATCH v4 bpf-next 3/5] kbuild: build kernel module BTFs if BTF is enabled and pahole supports it Message-ID: <20201116132409.4a5b8e0b@kicinski-fedora-pc1c0hjn.dhcp.thefacebook.com> In-Reply-To: References: <20201110011932.3201430-1-andrii@kernel.org> <20201110011932.3201430-4-andrii@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 16 Nov 2020 12:34:17 -0800 Andrii Nakryiko wrote: > > This change, commit 5f9ae91f7c0d ("kbuild: Build kernel module BTFs if BTF is enabled and pahole > > supports it") currently in net-next, linux-next, etc. breaks the use-case of compiling only a specific > > kernel module (both in-tree and out-of-tree, e.g. 'make M=drivers/net/ethernet/intel/ice') after > > first doing a 'make modules_prepare'. Previously, that use-case would result in a warning noting > > "Symbol info of vmlinux is missing. Unresolved symbol check will be entirely skipped" but now it > > errors out after noting "No rule to make target 'vmlinux', needed by '<...>.ko'. Stop." > > > > Is that intentional? > > I wasn't aware of such a use pattern, so definitely not intentional. > But vmlinux is absolutely necessary to generate the module BTF. So I'm > wondering what's the proper fix here? Leave it as is (that error > message is actually surprisingly descriptive, btw)? Force vmlinux > build? Or skip BTF generation for that module? For an external out-of-tree module there is no guarantee that vmlinux will even be on the system, no? So only the last option can work in that case.