Commit 0e23570a authored by Amey Narkhede's avatar Amey Narkhede Committed by Greg Kroah-Hartman
Browse files

staging: qlge/qlge_main: Use min_t instead of min



Use min_t instead of min function in qlge/qlge_main.c
Fixes following checkpatch.pl warning:
WARNING: min() should probably be min_t(int, MAX_CPUS, num_online_cpus())

Signed-off-by: default avatarAmey Narkhede <ameynarkhede02@gmail.com>
Link: https://lore.kernel.org/r/20210205092433.4131-1-ameynarkhede02@gmail.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 18a2615c
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -3924,7 +3924,7 @@ static int qlge_configure_rings(struct qlge_adapter *qdev)
	int i;
	struct rx_ring *rx_ring;
	struct tx_ring *tx_ring;
	int cpu_cnt = min(MAX_CPUS, (int)num_online_cpus());
	int cpu_cnt = min_t(int, MAX_CPUS, num_online_cpus());

	/* In a perfect world we have one RSS ring for each CPU
	 * and each has it's own vector.  To do that we ask for