RDMA/core: Fix comment for hw stats init for port == 0
When add_port() is done for port == 0, it indicates that ports hardware counters initialization should be skipped. Reflect so in the comment. Signed-off-by: Parav Pandit <parav@mellanox.com> Signed-off-by: Leon Romanovsky <leonro@mellanox.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
This commit is contained in:
parent
548cb4fbe8
commit
76d865b87c
|
@ -1120,9 +1120,9 @@ static int add_port(struct ib_device *device, int port_num,
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If port == 0, it means we have only one port and the parent
|
* If port == 0, it means hw_counters are per device and not per
|
||||||
* device, not this port device, should be the holder of the
|
* port, so holder should be device. Therefore skip per port conunter
|
||||||
* hw_counters
|
* initialization.
|
||||||
*/
|
*/
|
||||||
if (device->alloc_hw_stats && port_num)
|
if (device->alloc_hw_stats && port_num)
|
||||||
setup_hw_stats(device, p, port_num);
|
setup_hw_stats(device, p, port_num);
|
||||||
|
|
Loading…
Reference in New Issue