freebsd-dev/sys/ofed
Hans Petter Selasky d7d833e20b ibcore: Fix unable to change lifespan entry for hw_counters.
This patch fixes the case where 'lifespan' entry of the hw_counters
is not writable. Currently write callback is not exposed for for
the hw_counters sysfs operation. Due to this, modifying lifespan
value results into permission denied error in below example.

echo 10 > /sys/class/infiniband/mlx5_0/ports/1/hw_counters/lifespan
-bash: /sys/class/infiniband/mlx5_0/ports/1/hw_counters/lifespan:
Permission denied

This patch adds the hook to modify any attribute which implements
store() operation.

Linux commit:
79c4d80b43b8e43684894574a508a871f0c196bf

MFC after:	1 week
Reviewed by:	kib
Sponsored by:	Mellanox Technologies // NVIDIA Networking
2021-07-12 14:22:30 +02:00
..
drivers/infiniband ibcore: Fix unable to change lifespan entry for hw_counters. 2021-07-12 14:22:30 +02:00
include ibcore: Add rdma_reject_msg() helper function. 2021-07-12 14:22:30 +02:00