]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
IB/mlx4: Saturate RoCE port PMA counters in case of overflow
authorMajd Dibbiny <majd@mellanox.com>
Wed, 18 Mar 2015 14:51:37 +0000 (16:51 +0200)
committerJiri Slaby <jslaby@suse.cz>
Wed, 22 Apr 2015 06:58:48 +0000 (08:58 +0200)
commitc2b885aeb3b33fefd9ff2b46b5156cc65b7dbbe7
tree8a3d34091d2d05e5c2f2a47ca51e573b3667a0a4
parent553dd569ff29bc38cebbf9f9dd7c791863ee9113
IB/mlx4: Saturate RoCE port PMA counters in case of overflow

commit 61a3855bb726cbb062ef02a31a832dea455456e0 upstream.

For RoCE ports, we set the u32 PMA values based on u64 HCA counters. In case of
overflow, according to the IB spec, we have to saturate a counter to its
max value, do that.

Fixes: c37791349cc7 ('IB/mlx4: Support PMA counters for IBoE')
Signed-off-by: Majd Dibbiny <majd@mellanox.com>
Signed-off-by: Eran Ben Elisha <eranbe@mellanox.com>
Signed-off-by: Hadar Hen Zion <hadarh@mellanox.com>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/infiniband/hw/mlx4/mad.c