net/mlx4_core: Remove counters table allocation from VF flow
authorEran Ben Elisha <eranbe@mellanox.com>
Mon, 15 Jun 2015 14:58:59 +0000 (17:58 +0300)
committerDavid S. Miller <davem@davemloft.net>
Tue, 16 Jun 2015 00:23:01 +0000 (17:23 -0700)
commit2632d18d3ae75f6bdb79550134d1087fbd809e5f
tree66d27c4bf46a5758d341f39866fc50517b1999e2
parent47d8417f5914012c794684f651213ffae1b91619
net/mlx4_core: Remove counters table allocation from VF flow

Since virtual functions get their counters indices allocation from the PF,
allocate counters indices bitmap only in case the function isn't virtual.

Also, check that the device has counters to allocate before creating the
indices bitmap table.

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/net/ethernet/mellanox/mlx4/main.c