public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ppp: dead code cleanup in Kconfig
@ 2026-03-30 21:32 Julian Braha
  2026-03-31  5:55 ` Qingfang Deng
  2026-04-02  2:00 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 3+ messages in thread
From: Julian Braha @ 2026-03-30 21:32 UTC (permalink / raw)
  To: andrew+netdev, pabeni, davem, kuba; +Cc: netdev, linux-kernel, Julian Braha

There is already an 'if PPP' condition wrapping several config options
e.g. PPP_MPPE and PPPOE, making the 'depends on PPP' statement for each of
these a duplicate dependency (dead code).

I propose leaving the outer 'if PPP...endif' and removing the individual
'depends on PPP' statement from each option.

This dead code was found by kconfirm, a static analysis tool for Kconfig.

Signed-off-by: Julian Braha <julianbraha@gmail.com>
---
 drivers/net/ppp/Kconfig | 14 +++-----------
 1 file changed, 3 insertions(+), 11 deletions(-)

diff --git a/drivers/net/ppp/Kconfig b/drivers/net/ppp/Kconfig
index a1806b4b84be..f57fba84fe55 100644
--- a/drivers/net/ppp/Kconfig
+++ b/drivers/net/ppp/Kconfig
@@ -37,7 +37,6 @@ if PPP
 
 config PPP_BSDCOMP
 	tristate "PPP BSD-Compress compression"
-	depends on PPP
 	help
 	  Support for the BSD-Compress compression method for PPP, which uses
 	  the LZW compression method to compress each PPP packet before it is
@@ -56,7 +55,6 @@ config PPP_BSDCOMP
 
 config PPP_DEFLATE
 	tristate "PPP Deflate compression"
-	depends on PPP
 	select ZLIB_INFLATE
 	select ZLIB_DEFLATE
 	help
@@ -71,7 +69,6 @@ config PPP_DEFLATE
 
 config PPP_FILTER
 	bool "PPP filtering"
-	depends on PPP
 	help
 	  Say Y here if you want to be able to filter the packets passing over
 	  PPP interfaces.  This allows you to control which packets count as
@@ -84,7 +81,6 @@ config PPP_FILTER
 
 config PPP_MPPE
 	tristate "PPP MPPE compression (encryption)"
-	depends on PPP
 	select CRYPTO_LIB_ARC4
 	select CRYPTO_LIB_SHA1
 	help
@@ -96,7 +92,6 @@ config PPP_MPPE
 
 config PPP_MULTILINK
 	bool "PPP multilink support"
-	depends on PPP
 	help
 	  PPP multilink is a protocol (defined in RFC 1990) which allows you
 	  to combine several (logical or physical) lines into one logical PPP
@@ -109,7 +104,7 @@ config PPP_MULTILINK
 
 config PPPOATM
 	tristate "PPP over ATM"
-	depends on ATM && PPP
+	depends on ATM
 	help
 	  Support PPP (Point to Point Protocol) encapsulated in ATM frames.
 	  This implementation does not yet comply with section 8 of RFC2364,
@@ -118,7 +113,6 @@ config PPPOATM
 
 config PPPOE
 	tristate "PPP over Ethernet"
-	depends on PPP
 	help
 	  Support for PPP over Ethernet.
 
@@ -164,7 +158,7 @@ config PPPOE_HASH_BITS
 
 config PPTP
 	tristate "PPP over IPv4 (PPTP)"
-	depends on PPP && NET_IPGRE_DEMUX
+	depends on NET_IPGRE_DEMUX
 	help
 	  Support for PPP over IPv4.(Point-to-Point Tunneling Protocol)
 
@@ -175,7 +169,7 @@ config PPTP
 
 config PPPOL2TP
 	tristate "PPP over L2TP"
-	depends on L2TP && PPP
+	depends on L2TP
 	help
 	  Support for PPP-over-L2TP socket family. L2TP is a protocol
 	  used by ISPs and enterprises to tunnel PPP traffic over UDP
@@ -184,7 +178,6 @@ if TTY
 
 config PPP_ASYNC
 	tristate "PPP support for async serial ports"
-	depends on PPP
 	select CRC_CCITT
 	help
 	  Say Y (or M) here if you want to be able to use PPP over standard
@@ -198,7 +191,6 @@ config PPP_ASYNC
 
 config PPP_SYNC_TTY
 	tristate "PPP support for sync tty ports"
-	depends on PPP
 	help
 	  Say Y (or M) here if you want to be able to use PPP over synchronous
 	  (HDLC) tty devices, such as the SyncLink adapter. These devices
-- 
2.51.2


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] ppp: dead code cleanup in Kconfig
  2026-03-30 21:32 [PATCH] ppp: dead code cleanup in Kconfig Julian Braha
@ 2026-03-31  5:55 ` Qingfang Deng
  2026-04-02  2:00 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: Qingfang Deng @ 2026-03-31  5:55 UTC (permalink / raw)
  To: Julian Braha
  Cc: andrew+netdev, pabeni, davem, kuba, ebiggers, edumazet, netdev,
	linux-kernel

On Mon, 30 Mar 2026 22:32:58 +0100, Julian Braha wrote:
> There is already an 'if PPP' condition wrapping several config options
> e.g. PPP_MPPE and PPPOE, making the 'depends on PPP' statement for each of
> these a duplicate dependency (dead code).
> 
> I propose leaving the outer 'if PPP...endif' and removing the individual
> 'depends on PPP' statement from each option.
> 
> This dead code was found by kconfirm, a static analysis tool for Kconfig.
> 
> Signed-off-by: Julian Braha <julianbraha@gmail.com>

Reviewed-by: Qingfang Deng <dqfext@gmail.com>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] ppp: dead code cleanup in Kconfig
  2026-03-30 21:32 [PATCH] ppp: dead code cleanup in Kconfig Julian Braha
  2026-03-31  5:55 ` Qingfang Deng
@ 2026-04-02  2:00 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2026-04-02  2:00 UTC (permalink / raw)
  To: Julian Braha; +Cc: andrew+netdev, pabeni, davem, kuba, netdev, linux-kernel

Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Mon, 30 Mar 2026 22:32:58 +0100 you wrote:
> There is already an 'if PPP' condition wrapping several config options
> e.g. PPP_MPPE and PPPOE, making the 'depends on PPP' statement for each of
> these a duplicate dependency (dead code).
> 
> I propose leaving the outer 'if PPP...endif' and removing the individual
> 'depends on PPP' statement from each option.
> 
> [...]

Here is the summary with links:
  - ppp: dead code cleanup in Kconfig
    https://git.kernel.org/netdev/net-next/c/4cbcf82e26b6

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-04-02  2:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-30 21:32 [PATCH] ppp: dead code cleanup in Kconfig Julian Braha
2026-03-31  5:55 ` Qingfang Deng
2026-04-02  2:00 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox