Skip to content
Commit 6230bb23 authored by Jack Morgenstein's avatar Jack Morgenstein Committed by David S. Miller
Browse files

net/mlx4_core: Check port out-of-range before using in mlx4_slave_cap



The range check was performed after using the port number.

Reverse this to prevent a potential array overflow.

Signed-off-by: default avatarJack Morgenstein <jackm@dev.mellanox.co.il>
Reviewed-by: default avatarOr Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent b91cb3eb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment