netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] net: simplify eeecfg_mac_can_tx_lpi
@ 2024-11-12 20:36 Heiner Kallweit
  2024-11-12 21:19 ` Russell King (Oracle)
  2024-11-14  3:00 ` patchwork-bot+netdevbpf
  0 siblings, 2 replies; 3+ messages in thread
From: Heiner Kallweit @ 2024-11-12 20:36 UTC (permalink / raw)
  To: Russell King - ARM Linux, Andrew Lunn, Paolo Abeni,
	Jakub Kicinski, David Miller, Eric Dumazet
  Cc: netdev@vger.kernel.org

Simplify the function.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
---
 include/net/eee.h | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/include/net/eee.h b/include/net/eee.h
index 84837aba3..cfab1b8bc 100644
--- a/include/net/eee.h
+++ b/include/net/eee.h
@@ -13,10 +13,7 @@ struct eee_config {
 static inline bool eeecfg_mac_can_tx_lpi(const struct eee_config *eeecfg)
 {
 	/* eee_enabled is the master on/off */
-	if (!eeecfg->eee_enabled || !eeecfg->tx_lpi_enabled)
-		return false;
-
-	return true;
+	return eeecfg->eee_enabled && eeecfg->tx_lpi_enabled;
 }
 
 static inline void eeecfg_to_eee(struct ethtool_keee *eee,
-- 
2.47.0


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

* Re: [PATCH net-next] net: simplify eeecfg_mac_can_tx_lpi
  2024-11-12 20:36 [PATCH net-next] net: simplify eeecfg_mac_can_tx_lpi Heiner Kallweit
@ 2024-11-12 21:19 ` Russell King (Oracle)
  2024-11-14  3:00 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: Russell King (Oracle) @ 2024-11-12 21:19 UTC (permalink / raw)
  To: Heiner Kallweit
  Cc: Andrew Lunn, Paolo Abeni, Jakub Kicinski, David Miller,
	Eric Dumazet, netdev@vger.kernel.org

On Tue, Nov 12, 2024 at 09:36:29PM +0100, Heiner Kallweit wrote:
> Simplify the function.
> 
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>

Reviewed-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>

Thanks!

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

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

* Re: [PATCH net-next] net: simplify eeecfg_mac_can_tx_lpi
  2024-11-12 20:36 [PATCH net-next] net: simplify eeecfg_mac_can_tx_lpi Heiner Kallweit
  2024-11-12 21:19 ` Russell King (Oracle)
@ 2024-11-14  3:00 ` patchwork-bot+netdevbpf
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2024-11-14  3:00 UTC (permalink / raw)
  To: Heiner Kallweit; +Cc: linux, andrew, pabeni, kuba, davem, edumazet, netdev

Hello:

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

On Tue, 12 Nov 2024 21:36:29 +0100 you wrote:
> Simplify the function.
> 
> Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
> ---
>  include/net/eee.h | 5 +----
>  1 file changed, 1 insertion(+), 4 deletions(-)

Here is the summary with links:
  - [net-next] net: simplify eeecfg_mac_can_tx_lpi
    https://git.kernel.org/netdev/net-next/c/6b998404c71e

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:[~2024-11-14  3:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-12 20:36 [PATCH net-next] net: simplify eeecfg_mac_can_tx_lpi Heiner Kallweit
2024-11-12 21:19 ` Russell King (Oracle)
2024-11-14  3: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;
as well as URLs for NNTP newsgroup(s).