🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #23693

[PATCH net-next v4 16/16] ipv4: make CONFIG_IPV4 boolean

#23693
From: Fernando Fernandez Mancera
Date: Fri, 27 Nov 2026 17:18
40 lines
9837 bytes
Change CONFIG_IPV4 from hidden 'def_bool y' into an exposed boolean.
This allows users to explicitly disable IPv4 via Kconfig to build
IPv6-only. The default is kept at 'INET' to prevent breaking existing
configurations.

Signed-off-by: Fernando Fernandez Mancera <fmancera@suse.de>
---
Sashiko: Yes, disabling IPV4 will currently disable many relevant kernel
modules. I acknowledge that in the cover letter. This is just an
introductory series and many patches will follow-up so we can respect
the 15~ patches series in netdev. I have more work prepared to send once
this is merged.
---
 net/ipv4/Kconfig | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/net/ipv4/Kconfig b/net/ipv4/Kconfig
index f34e31f06c7f..8b7f4a0613fb 100644
--- a/net/ipv4/Kconfig
+++ b/net/ipv4/Kconfig
@@ -3,7 +3,15 @@
 # IP configuration
 #
 config IPV4
-	def_bool y
+	bool "The IPv4 protocol" if IPV6
+	default INET
+	help
+	  Support for IP version 4 (IPv4).
+
+	  Disabling this option compiles the kernel networking stack without
+	  IPv4 support, resulting in a IPv6-only system.
+
+	  If unsure, say Y.
 
 config IP_MULTICAST
 	bool "IP: multicasting"
-- 
2.56.1
Technical Details
Message-ID: <20261127171824.27362-17-fmancera@suse.de>
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-372898-linux-kernel-netdev=dewy.ru
References: <20261127171824.27362-1-fmancera@suse.de>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-372898-linux-kernel-netdev=dewy.ru
From: fmancera@suse.de (Fernando Fernandez Mancera)
Newsgroups: linux.kernel.netdev
Subject: [PATCH net-next v4 16/16] ipv4: make CONFIG_IPV4 boolean
Date: Fri, 27 Nov 2026 18:18:01 +0100
Organization: Usenet Network
Message-ID: <20261127171824.27362-17-fmancera@suse.de>
References: <20261127171824.27362-1-fmancera@suse.de>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Injection-Info: usenet.network;
	logging-data="782502"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:AZEv2PcZ5I3DRgWuaA4Qz2WZisg= sha256:IBA/gL049Fdt6LZ4lVBJGuuC9Ki07MeDLMvFQ6a6Ukg=
	sha1:D5j5QBc+HmPMNuzBTqukJpKCtJU= sha256:vXaaB3DcTNh76WLDG/DFUz+SETe1u0+9nisxbQscUyk=
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 3DD94125F5E; Fri, 27 Nov 2026 20:20:55 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.051
X-Spam-Status: No, score=-3.051 tagged_above=-9999 required=6.31
	tests=[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]
	autolearn=ham autolearn_force=no
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 rZCtS8gQfUme;
	Fri, 27 Nov 2026 20:20:52 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.232.135.74; helo=sto.lore.kernel.org; envelope-from=netdev+bounces-372898-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> 
X-Authentication-Results: OpenDMARC; dmarc=fail (p=none dis=none) header.from=suse.de
X-Received: from sto.lore.kernel.org (sto.lore.kernel.org [172.232.135.74])
	by mail.dewy.ru (Postfix) with ESMTPS id 0021E125F63; Fri, 27 Nov 2026 20:20:47 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sto.lore.kernel.org (Postfix) with ESMTP id D8768606511; Fri, 27 Nov 2026 17:20:46 +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=1795800042;
	b=SKzS3BwDWzqbOQI8GBqsFHvFPiA91OmfW9lwevl3wvhUsCYrf4dY8kJPxUOJh/YSvqpA
	 HNn1Tu1AwRiDxSYb9oqzWz5y2q2DCNuGMAy4QJ2Do1/ggrYnKLsfP6TGKsxr0a0d3mVAr
	 wy7mt311OfhRqjFXR2ARqaCHPYjWOSTLMVtAGDXCx37HoWJ3LhynKWjkaTYqUoxmf6ZKO
	 uvFgsTXG+W6G3YNRcblYy/bBFZTLVlx+5ew4bIhqs/ueutEsG4J41L2jBlBuYOaKEUiY0
	 VPx3iFVSPhr0hMkzDnmM2pIn2PO0b+K88wiyhiu1Ig0vk0Hh03l+KjKBNEiQHaY2ZTw==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1795800042;
	h=X-Original-To:Received:DMARC-Filter:Received:Received:Received:From:
	 To:Cc:Subject:Date:Message-ID:X-Mailer:In-Reply-To:References:
	 X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe:
	 List-Unsubscribe:List-Owner:Precedence:MIME-Version:
	 Content-Transfer-Encoding:X-Rspamd-Pre-Result:X-Rspamd-Queue-Id:
	 X-Rspamd-Pre-Result:X-Rspamd-Action:X-Rspamd-Server:X-Spam-Level:
	 X-Spamd-Result:X-Spam-Flag:X-Spam-Score;
	bh=QydS19oSkNCTTBPLLeZxya3Ay1kS6ux9KdOCRVuTgRY=;
	b=fsQxwDx1TQDsVN7DzCHFrE9lfg34EWpT7qHgg7SD9r98lIVNH6fzvl+kbYCfbYW4FfR8
	 5jCW6ZPnh+XW/YuUvnuiX30SL1VRvJaojVHZaA+xbtwm5+GvUTQbgkvGLfyZpZwnnBV/H
	 CnigfINF8uJNEAy65D8h8LqxTty7ylqsOGkhJTFw2V1L5R0eCtkbpsQaOIREn4fbLyBcQ
	 7VG3ugKjrDxh6AfwMjH2dQeqVJ4XIoBLOBbTHPpCyEuDE1yb5sq6OjJ1d8F9O4gHxZhGe
	 bO8tlStmSiGKu/J3Rja0xaYCMmJLj5yNI9mEEXIt2DD7mZyEIvQbDAnHPFWlCVFpGiw==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dmarc=pass header.from=suse.de;
	spf=pass smtp.mailfrom=suse.de;
	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 B43D5606A33C;
	Fri, 27 Nov 2026 17:20:42 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=195.135.223.130
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1795800042;
	b=Q7cIqhuRHTLEUfjCZ077VCs7+YrKQv5u0pskjNLhQpdfQWcDRbAUtj2CwZB+AgVWyNC5
	 wnwjULEGk7hHFACSS1KwA2MC8ONvBLveijT9wKq+lK+SpXEm7dZ3ekUn2MnoX6cgfHEms
	 f6dsbocgp7uW6sZwWMbOXYdjcOklB+KiXRyx5IGDGDzuhorjaxSNa2B72CFo+8iSc7fJC
	 sFBa0xfMcD81XOWFI1bM9vxn9519PgDIQJ1PyEotkn72Cj9o3ug7/2sXUZ0yyLPv1P3t3
	 Wptho3W0e5m7wKQlNFtbDUAKcI0CXUO2P+8IaiOg51LH3xkY00RgVDWKnhpX/k4clmQ==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1795800042;
	h=DMARC-Filter:Received:Received:Received:From:To:Cc:Subject:Date:
	 Message-ID:X-Mailer:In-Reply-To:References:MIME-Version:
	 Content-Transfer-Encoding:X-Rspamd-Pre-Result:X-Rspamd-Queue-Id:
	 X-Rspamd-Pre-Result:X-Rspamd-Action:X-Rspamd-Server:X-Spam-Level:
	 X-Spamd-Result:X-Spam-Flag:X-Spam-Score;
	bh=QydS19oSkNCTTBPLLeZxya3Ay1kS6ux9KdOCRVuTgRY=;
	b=jogP0bL1+8H0p+yX2oljPZLMWvwQTo4QbDeTK0tg5yy6vRnFRBT5oHwfuP5CkrO8fv9v
	 OLYNeqf1DPhl9Pp1j2gi+OljaubHvJiQWZY+TnAWc+Q4bBRk2FlTS4gK5DqUZQ2Lz0ffn
	 6sL5c/+oPe9B0sQLmqX0Hdp1GlW+eGyDijFsjrL8+b14pUsKY+8ZP2lQFKIn2ft5BCpph
	 ynd+1JTb3BuHw6GnuVhf066Fwv0uxHT8381lB5cXdM0J7syLnL4qlzMCjad5fVPD5w27Y
	 rJn4/5MqpE3DXRx9X8nWYHK/Vw5wc0O28LIrqIvOvf5DeNU0zPOPd6qhzqulTqPgR/g==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dmarc=pass header.from=suse.de;
	spf=pass smtp.mailfrom=suse.de;
	arc=none smtp.remote-ip=195.135.223.130
X-Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.223.130])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256)
	(No client certificate requested)
	by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9EFCE606A33E
	for <netdev@vger.kernel.org>; Fri, 27 Nov 2026 17:20:41 +0000 (UTC)
X-DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 9EFCE606A33E
X-Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=suse.de
X-Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=suse.de
X-Received: from imap1.dmz-prg2.suse.org (imap1.dmz-prg2.suse.org [IPv6:2a07:de40:b281:104:10:150:64:97])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256)
	(No client certificate requested)
	by smtp-out1.suse.de (Postfix) with ESMTPS id F41EA229B4;
	Fri, 27 Nov 2026 17:20:39 +0000 (UTC)
X-Authentication-Results: smtp-out1.suse.de;
	none
X-Received: from imap1.dmz-prg2.suse.org (localhost [127.0.0.1])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256)
	(No client certificate requested)
	by imap1.dmz-prg2.suse.org (Postfix) with ESMTPS id 3405C13432;
	Fri, 27 Nov 2026 17:20:39 +0000 (UTC)
X-Received: from dovecot-director2.suse.de ([2a07:de40:b281:106:10:150:64:167])
	by imap1.dmz-prg2.suse.org with ESMTPSA
	id /Yb1MH67CWuMAwAAD6G6ig:T17
	(envelope-from <fmancera@suse.de>); Fri, 27 Nov 2026 17:20:39 +0000
X-Cc: davem@davemloft.net,
	kuba@kernel.org,
	edumazet@kernel.org,
	pabeni@redhat.com,
	horms@kernel.org,
	Fernando Fernandez Mancera <fmancera@suse.de>,
	Willem de Bruijn <willemb@google.com>,
	Eric Biggers <ebiggers@kernel.org>,
	Ard Biesheuvel <ardb@kernel.org>,
	Krzysztof Kozlowski <krzk@kernel.org>,
	Tim Fuechsel <t.fuechsel@gmx.de>
X-Mailer: git-send-email 2.51.0
X-In-Reply-To: <20261127171824.27362-1-fmancera@suse.de>
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-Rspamd-Pre-Result: action=no action;
	module=replies;
	Message is reply to one we originated
X-Rspamd-Queue-Id: F41EA229B4
X-Rspamd-Pre-Result: action=no action;
	module=replies;
	Message is reply to one we originated
X-Rspamd-Action: no action
X-Rspamd-Server: rspamd2.dmz-prg2.suse.org
X-Spamd-Result: default: False [-4.00 / 50.00];
	REPLY(-4.00)[]