On 5/17/2018 1:39 PM, Yishai Hadas wrote:
This series from Raed comes to allow user space applications to monitor real time traffic activity and events of the verbs objects it manages, e.g.: ibv_qp, ibv_wq, ibv_flow. This API enables generic counters creation and defines mapping to association with a verbs object, current mlx5 driver using this API for flow counters. With this API, an application can monitor the entire life cycle of object activity, defined here as a static counters attachment. This API also allows dynamic counters monitoring of measurement points for a partial period in the verbs object life cycle. The static counters attachment for flow counters is achieved by extending flow creation by adding a new flow count specification type which allows the user to associate a previously created flow counters using the generic verbs counters interface to the created flow, once associated the user could read statistics by using the read function of the generic counters interface. A detailed description of the API appears as part the man pages of the series. The API follows a detailed RFC and discussion that was in the mailing list. The matching kernel series was already sent into rdma-next for 4.18. PR was sent: https://github.com/linux-rdma/rdma-core/pull/330 Yishai Raed Salem (10): verbs: Use ccan bitmap instead of u64 bit mask for unsupported IOCTLs verbs: Introduce counters object and its create/destroy verbs verbs: Introduce counters attach point flow verbs: Introduce counters read verb Expand create flow to take provider internal data verbs: Add counters flow_spec mlx5: Add support for counters create/destroy mlx5: Add support for counters attach point flow mlx5: Add support for counters read mlx5: Add flow counters support Yishai Hadas (1): Update kernel headers kernel-headers/CMakeLists.txt | 1 + kernel-headers/rdma/cxgb3-abi.h | 2 +- kernel-headers/rdma/cxgb4-abi.h | 2 +- kernel-headers/rdma/hns-abi.h | 2 +- kernel-headers/rdma/ib_user.h | 69 ++++++ kernel-headers/rdma/ib_user_cm.h | 2 +- kernel-headers/rdma/ib_user_ioctl_cmds.h | 21 ++ kernel-headers/rdma/ib_user_ioctl_verbs.h | 2 +- kernel-headers/rdma/ib_user_mad.h | 2 +- kernel-headers/rdma/ib_user_sa.h | 2 +- kernel-headers/rdma/ib_user_verbs.h | 68 +++++- kernel-headers/rdma/mlx4-abi.h | 2 +- kernel-headers/rdma/mlx5-abi.h | 23 +- kernel-headers/rdma/mlx5_user_ioctl_cmds.h | 73 ++++++ kernel-headers/rdma/mthca-abi.h | 2 +- kernel-headers/rdma/nes-abi.h | 2 +- kernel-headers/rdma/qedr-abi.h | 2 +- kernel-headers/rdma/rdma_netlink.h | 26 +++ kernel-headers/rdma/rdma_user_cm.h | 2 +- kernel-headers/rdma/rdma_user_ioctl.h | 2 +- kernel-headers/rdma/rdma_user_rxe.h | 2 +- libibverbs/CMakeLists.txt | 1 + libibverbs/cmd.c | 25 +- libibverbs/cmd_counters.c | 90 ++++++++ libibverbs/cmd_fallback.c | 10 +- libibverbs/driver.h | 29 ++- libibverbs/dummy_ops.c | 35 +++ libibverbs/ibverbs.h | 5 +- libibverbs/kern-abi.h | 1 + libibverbs/libibverbs.map.in | 3 + libibverbs/man/CMakeLists.txt | 4 + libibverbs/man/ibv_attach_counters_point_flow.3.md | 134 +++++++++++ libibverbs/man/ibv_create_counters.3.md | 97 ++++++++ libibverbs/man/ibv_create_flow.3 | 1 + libibverbs/man/ibv_read_counters.3.md | 186 +++++++++++++++ libibverbs/verbs.h | 93 ++++++++ providers/mlx4/verbs.c | 3 +- providers/mlx5/mlx5.c | 4 + providers/mlx5/mlx5.h | 42 ++++ providers/mlx5/verbs.c | 252 ++++++++++++++++++++- 40 files changed, 1284 insertions(+), 40 deletions(-) create mode 100644 kernel-headers/rdma/ib_user.h create mode 100644 libibverbs/cmd_counters.c create mode 100644 libibverbs/man/ibv_attach_counters_point_flow.3.md create mode 100644 libibverbs/man/ibv_create_counters.3.md create mode 100644 libibverbs/man/ibv_read_counters.3.md
The PR is ready according to the latest comments, series was merged. -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html