]> asedeno.scripts.mit.edu Git - linux.git/commit
RDMA/core: Get sum value of all counters when perform a sysfs stat read
authorMark Zhang <markz@mellanox.com>
Tue, 2 Jul 2019 10:02:42 +0000 (13:02 +0300)
committerJason Gunthorpe <jgg@mellanox.com>
Fri, 5 Jul 2019 13:22:55 +0000 (10:22 -0300)
commitf34a55e497e81347ffbdc6e828f123520d33ce5d
treefcce7e5fd3679bbb3870b10445a5f04da5d84304
parent18d422ce8ccf47c65b98c2ce9e1758d84c8434eb
RDMA/core: Get sum value of all counters when perform a sysfs stat read

Since a QP can only be bound to one counter, then if it is bound to a
separate counter, for backward compatibility purpose, the statistic value
must be:
* stat of default counter
+ stat of all running allocated counters
+ stat of all deallocated counters (history stats)

Signed-off-by: Mark Zhang <markz@mellanox.com>
Reviewed-by: Majd Dibbiny <majd@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/core/counters.c
drivers/infiniband/core/sysfs.c
include/rdma/rdma_counter.h