Article View: linux.kernel.netdev
Article #12532[PATCH bpf-next v3 8/8] bpf: Fix "unresolved symbol tcp_request_sock" build error
From: Michal Luczaj
Date: Sat, 07 Nov 2026 17:58
Date: Sat, 07 Nov 2026 17:58
39 lines
10226 bytes
10226 bytes
CONFIG_WERROR=y CONFIG_NET=y CONFIG_INET=n build fails:
WARN: resolve_btfids: unresolved symbol tcp_request_sock
Failed to generate BTF for vmlinux
Try to disable CONFIG_DEBUG_INFO_BTF
make[2]: *** [scripts/Makefile.vmlinux:72: vmlinux.unstripped] Error 1
make[1]: *** [.../Makefile:1379: vmlinux] Error 2
make: *** [Makefile:248: __sub-make] Error 2
Handle it in the style of commit d82a532a6115 ("bpf: Fix "unresolved
symbol" build error with resolve_btfids"): force BTF generation.
Signed-off-by: Michal Luczaj <mhal@rbox.co>
---
Technically, since tcp_request_sock embedds inet_request_sock there's no
need to explicitly emit for inet_.
---
net/core/filter.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/net/core/filter.c b/net/core/filter.c
index 6a67bc2a0c4b..b86529dead65 100644
--- a/net/core/filter.c
+++ b/net/core/filter.c
@@ -12391,6 +12391,10 @@ const struct bpf_func_proto bpf_skc_to_tcp_timewait_sock_proto = {
BPF_CALL_1(bpf_skc_to_tcp_request_sock, struct sock *, sk)
{
+ /* Ensure BTF for the structs exists even with CONFIG_INET=n. */
+ BTF_TYPE_EMIT(struct inet_request_sock);
+ BTF_TYPE_EMIT(struct tcp_request_sock);
+
#ifdef CONFIG_INET
if (sk && sk->sk_prot == &tcp_prot && sk->sk_state == TCP_NEW_SYN_RECV)
return (unsigned long)sk;
--
2.56.0
Technical Details
Message-ID:
<20261107-sockmap-update-limit-iter-v3-8-7c0bad1ad036@rbox.co>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-358458-linux-kernel-netdev=dewy.ruReferences:
<20261107-sockmap-update-limit-iter-v3-0-7c0bad1ad036@rbox.co>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-358458-linux-kernel-netdev=dewy.ru From: mhal@rbox.co (Michal Luczaj) Newsgroups: linux.kernel.netdev Subject: [PATCH bpf-next v3 8/8] bpf: Fix "unresolved symbol tcp_request_sock" build error Date: Sat, 07 Nov 2026 18:58:30 +0100 Organization: Usenet Network Message-ID: <20261107-sockmap-update-limit-iter-v3-8-7c0bad1ad036@rbox.co> References: <20261107-sockmap-update-limit-iter-v3-0-7c0bad1ad036@rbox.co> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Injection-Info: usenet.network; logging-data="4158706"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:W7UReO9Aete2CNtt5sdu+kKshXk= sha256:U+5oRYc/dCJObDm7VCBBd7993HeJKbgUxjzNHqRNNbw= sha1:LYqgmCWgsPimdQK0n/LNN9civU0= sha256:s7Lqz8UujJSjj+BLFrDiHBJTTY4DS5SWH8En99io1wI= List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id 67FC711346B; Sat, 7 Nov 2026 21:01:32 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.048 X-Spam-Status: No, score=-3.048 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_FORGED_FROMDOMAIN=0.001, FREEMAIL_FROM=0.001, HEADER_FROM_DIFFERENT_DOMAINS=0.249, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=rbox.co X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id YMnFYdLKmGB4; Sat, 7 Nov 2026 21:01:29 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.105.105.114; helo=tor.lore.kernel.org; envelope-from=netdev+bounces-358458-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=rbox.co X-Received: from tor.lore.kernel.org (tor.lore.kernel.org [172.105.105.114]) by mail.dewy.ru (Postfix) with ESMTPS id 52A6D11346A; Sat, 7 Nov 2026 21:01:21 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92]) by tor.lore.kernel.org (Postfix) with ESMTP id 2CF2B83214; Sat, 7 Nov 2026 18:00:01 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass; t=1794074390; b=doP5w7ccn8F+NII66WA8Zdhhl7CzoqxVFEJV8HpEKN9sFZjbb4EV8QMzh4QJBAwPKZmK PEXg1fwM7y87keaE8V87zxFjbulrkUgmEo6umBAU6tJoHULU9rkQUdwFOafyL6fUb+D2q QOCPJp2szfHnwmzaeH0s2ZBmmL1Y6+mqVD+q+nN+KFTv93n29dMdOgJ21op+tAInWsm9n tVatvJFy+K4ZgWMFvsGRHv8F8ZV7EgxrdpOljzPNKgKUX+5gw2yZZw7y8IH0uq8cxxlel aASVsTpM7rI2NSIUg60/2RubwaPO5AdX8BbjEi1a4CRN0fNUS+1RZfaQ1rZli9539UQ== X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794074390; h=X-Original-To:Received:DMARC-Filter:Received:DKIM-Signature:Received: Received:From:Date:Subject:X-Mailing-List:List-Id:List-Post:List-Help: List-Subscribe:List-Unsubscribe:List-Owner:Precedence:MIME-Version: Content-Type:Content-Transfer-Encoding:Message-Id:References: In-Reply-To:To:Cc:X-Mailer; bh=+sOGB5lb2oiDR2pVte8gE4CcBLvveiaJEtksFCZ6wwI=; b=RSnW6z4nZR660yi2AgkvyfZQn/eYfYebDJNoE+Xj67kNtsxsuHIxPPiDncNa/FsWU9mZ oPAyxzmFslmRHskftZxMWjXpZ3nBCRmwSXiai22RYXEpv0p44lRil0x51tB3QM2VsQg0K vIsZgDk0c5tQHzruU2w2D3vuH4PdbgcASpYO4zy9LpAdGdNWrmftp6lYxfk96lefl87G4 xFybv4uajQSkrxTXxcEW/X7sSCNU1TErZi+SBZ5dwKelG+9lUNlexQq/K+07up1ychUna V06i5V9xgIgpPV5ISSb6ua5bYxLH+SejMC+aXnGXveFgpu6RL/ywsHxAJWVss/ctZng== X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dkim=pass header.d=rbox.co header.i=@rbox.co header.a=rsa-sha256 header.s=selector1 header.b=xDY+Dzg7; dmarc=pass header.from=rbox.co; spf=pass smtp.mailfrom=rbox.co; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1 X-Received: from localhost.localdomain (localhost [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6A312606D831; Sat, 7 Nov 2026 17:59:50 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=rbox.co header.i=@rbox.co header.a=rsa-sha256 header.s=selector1 header.b=xDY+Dzg7 X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=185.226.149.38 X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1794074389; b=Fnat8L9C5FCMLWSdDYFRoVWANi1vm0lFvSMKusbwwDPkztig4cAv9Pjtp2OoQh72uWE5 +X9VVXEZCiCu+oNcHG7S9jkpDgOQ7VxqopE/EbuxQJDwFpOghTNfAJoaOg25jyXr2o5p3 5V/h0H+bFkKWqAgxNF9E1CO24E74+c+2FVT0WEcFempPokrSUaUNetJgdKAjE54WxZX1I KoKQhXSHzTQRISntwXDKfX4fWDVZIiPY7u/aTpKd+6ZnJqsIKheT8WLTDAIh3BfxUSJ17 PH1txjCdejpV8agyYpKco2eNTO/1N4zOyXOqpCiXvFPNhaqmth6FtWf/yppaX1/RchQ== X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1794074389; h=DMARC-Filter:Received:DKIM-Signature:Received:Received:From:Date: Subject:MIME-Version:Content-Type:Content-Transfer-Encoding: Message-Id:References:In-Reply-To:To:Cc:X-Mailer; bh=+sOGB5lb2oiDR2pVte8gE4CcBLvveiaJEtksFCZ6wwI=; b=hcr/gZ6xewGKdjsXd5o4TOXJBUXmVAOKTej0Z0oeAZVmGSchzm4GoeHOLOlGSKK5/72m oqt863zXq7LIj1Yu8S+4U8E6pP3DB4X/Q8RnvYEWK6bfb53OuIhrjufcRsasGxi8xn1OH odVpysMKJ3VpvTlvtnyAqufgAL1RHDDlHu9zcXwh0rUgcHqQM2nNHVoqyBAad/EhXOgQY 3GRxQ7vquYaY+shx4MhgDwNtBrGOPxI2pCioGTOICpINnV1UhSEA51K5pwx/zSH1zfKu2 t+FYA71eYgDnxTcgGZlwQpRW4QIUoHokEvXFukWNvRi2ccgRhMTrEojyfcEcLXJC/ug== X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=rbox.co; spf=pass smtp.mailfrom=rbox.co; dkim=pass header.d=rbox.co header.i=@rbox.co header.a=rsa-sha256 header.s=selector1 header.b=xDY+Dzg7; arc=none smtp.remote-ip=185.226.149.38 X-Received: from mailtransmit05.runbox.com (mailtransmit05.runbox.com [185.226.149.38]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 43C9A606EE84; Sat, 7 Nov 2026 17:59:49 +0000 (UTC) X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 43C9A606EE84 X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=rbox.co X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=rbox.co X-Received: from mailtransmit03.runbox ([10.9.9.163] helo=aibo.runbox.com) by mailtransmit05.runbox.com with esmtps (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.93) (envelope-from <mhal@rbox.co>) id 1xPkhN-007oUE-OS; Sat, 07 Nov 2026 18:59:29 +0100 X-DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=rbox.co; s=selector1; h=Cc:To:In-Reply-To:References:Message-Id: Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date:From; bh=+sOGB5lb2oiDR2pVte8gE4CcBLvveiaJEtksFCZ6wwI=; b=xDY+Dzg720FHSgO6gJscshGB1F iEGBF5XtYLBoeSPg+5+9pG5Q9MHbDH1wNhh9Vu5PZkvD6D2n8uCqrwkbNhi1/u1CK6If6e002EwNu 1L9VrG03D+8cQBxGQsFim8qs3gH7STN1ZA8RTvT3M908BXtVm/OAptwK4WHlZu7ES/tNGfTD+rkHL hM09NtFYZyPqgwAq1DWMF1XMeen1Ftt2ctJbn+7eIPdnFSbvCLP22aVTNddSWr+mfLOHgronrVV1p m+getDbUhjameJbwET2jR9yBoSjmr466DK1bi2sMtKMzd4rzxs9q5C5ka3Tpjukp//322RUfNRt3x yrSc/AAA==; X-Received: from [10.9.9.74] (helo=submission03.runbox) by mailtransmit03.runbox with esmtp (Exim 4.86_2) (envelope-from <mhal@rbox.co>) id 1xPkhC-0006az-Og; Sat, 07 Nov 2026 18:59:18 +0100 X-Received: by submission03.runbox with esmtpsa [Authenticated ID (604044)] (TLS1.2:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim 4.95) id 1xPkhB-007LnK-1s; Sat, 07 Nov 2026 18:59:17 +0100 X-Mailing-List: netdev@vger.kernel.org X-List-Post: <mailto:netdev@vger.kernel.org> X-List-Help: <mailto:netdev+help@vger.kernel.org> X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-List-Owner: <mailto:netdev+owner@vger.kernel.org> X-Precedence: list X-In-Reply-To: <20261107-sockmap-update-limit-iter-v3-0-7c0bad1ad036@rbox.co> X-Cc: Michal Luczaj <mhal@rbox.co>, bpf@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-doc@vger.kernel.org X-Mailer: b4 0.15.2