]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx4_core: Add sink counter
authorEran Ben Elisha <eranbe@mellanox.com>
Mon, 15 Jun 2015 14:58:58 +0000 (17:58 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 16 Jun 2015 00:23:01 +0000 (17:23 -0700)
commit30d59b2ba062c1d5e5017471e2dc7215db45cae2
tree7be5039f8dcfde0e3efe72e3b967316c7d5f9a58
parentc44de48e57ff0c28327585d3c9568fa9da04d7c8
net/mlx4_core: Add sink counter

Reserve the last valid counter index for "sink" counter, when a
new counter cannot be allocated, the driver will use this counter.

In order to avoid allocating this counter on any other flow, fix the
indices bitmap allocation range, and reserve the sink counter index.

Add macro for the sink counter index and replace all appearences of the
index with the macro.

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>
drivers/infiniband/hw/mlx4/qp.c
drivers/net/ethernet/mellanox/mlx4/en_resources.c
drivers/net/ethernet/mellanox/mlx4/main.c
include/linux/mlx4/device.h