netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/8] Use max/min to simplify the code
@ 2024-08-24  7:40 Hongbo Li
  2024-08-24  7:40 ` [PATCH net-next 1/8] net/mac80211: use max " Hongbo Li
                   ` (8 more replies)
  0 siblings, 9 replies; 32+ messages in thread
From: Hongbo Li @ 2024-08-24  7:40 UTC (permalink / raw)
  To: johannes, davem, edumazet, kuba, pabeni, allison.henderson,
	dsahern, pshelar
  Cc: linux-wireless, netdev, rds-devel, dccp, dev, linux-afs,
	lihongbo22

Many Coccinelle/coccicheck warning reported by minmax.cocci
in net module, such as:
        WARNING opportunity for max()
        WARNING opportunity for min()

Let's use max/min to simplify the code and fix these warnings.
These patch have passed compilation test.

Hongbo Li (8):
  net/mac80211: use max to simplify the code
  net/rds: Use max() to simplify the code
  net/ipv4: Use min() to simplify the code
  net/core: Use min()/max() to simplify the code
  net/dccp: Use min()/max() to simplify the code
  net/openvswitch: Use max() to simplify the code
  net/rxrpc: Use min() to simplify the code
  net/ceph: Use min() to simplify the code

 net/ceph/osd_client.c     | 2 +-
 net/core/pktgen.c         | 6 ++----
 net/core/sock.c           | 2 +-
 net/dccp/ackvec.c         | 2 +-
 net/dccp/dccp.h           | 2 +-
 net/ipv4/ip_sockglue.c    | 2 +-
 net/mac80211/driver-ops.h | 2 +-
 net/mac80211/mlme.c       | 2 +-
 net/mac80211/scan.c       | 6 ++----
 net/mac80211/tdls.c       | 2 +-
 net/openvswitch/vport.c   | 2 +-
 net/rds/info.c            | 5 +----
 net/rxrpc/input.c         | 3 +--
 13 files changed, 15 insertions(+), 23 deletions(-)

-- 
2.34.1


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

end of thread, other threads:[~2024-08-30  8:41 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-24  7:40 [PATCH net-next 0/8] Use max/min to simplify the code Hongbo Li
2024-08-24  7:40 ` [PATCH net-next 1/8] net/mac80211: use max " Hongbo Li
2024-08-26 19:02   ` Kalle Valo
2024-08-24  7:40 ` [PATCH net-next 2/8] net/rds: Use max() " Hongbo Li
2024-08-27  5:28   ` Allison Henderson
2024-08-28 13:53   ` Simon Horman
2024-08-24  7:40 ` [PATCH net-next 3/8] net/ipv4: Use min() " Hongbo Li
2024-08-24  7:40 ` [PATCH net-next 4/8] net/core: Use min()/max() " Hongbo Li
2024-08-28  7:36   ` kernel test robot
2024-08-28  8:17   ` kernel test robot
2024-08-28 13:59   ` Simon Horman
2024-08-24  7:40 ` [PATCH net-next 5/8] net/dccp: " Hongbo Li
2024-08-28 14:04   ` Simon Horman
2024-08-24  7:40 ` [PATCH net-next 6/8] net/openvswitch: Use max() " Hongbo Li
2024-08-26  6:37   ` Eelco Chaudron
2024-08-26 17:58   ` [ovs-dev] " Aaron Conole
2024-08-28 14:10   ` Simon Horman
2024-08-24  7:40 ` [PATCH net-next 7/8] net/rxrpc: Use min() " Hongbo Li
2024-08-24 12:06   ` David Howells
2024-08-26  1:41     ` Hongbo Li
2024-08-26  2:50     ` Hongbo Li
2024-08-27 17:58       ` Simon Horman
2024-08-28  8:17       ` David Howells
2024-08-29 16:46         ` David Laight
2024-08-24  7:40 ` [PATCH net-next 8/8] net/ceph: " Hongbo Li
2024-08-28 14:11   ` Simon Horman
2024-08-26 21:44 ` [PATCH net-next 0/8] Use max/min " Jakub Kicinski
2024-08-27  2:57   ` Hongbo Li
2024-08-27  4:45     ` Kalle Valo
2024-08-27 14:03       ` Jakub Kicinski
2024-08-27 14:31         ` Kalle Valo
2024-08-30  8:40         ` David Laight

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).