RDMA/ocrdma: Fix permissions for OCRDMA_RESET_STATS
authorAnton Vasilyev <vasilyev@ispras.ru>
Tue, 8 Aug 2017 15:56:37 +0000 (18:56 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 24 Mar 2018 10:01:27 +0000 (11:01 +0100)
commite434a6eaed8c942495bbca4f714b04f5a146cdfc
tree0a3c458775bd3cbf1d8bab65a90de485582718d4
parent7b7e076f8cad849b69715738018fcc5745025168
RDMA/ocrdma: Fix permissions for OCRDMA_RESET_STATS

[ Upstream commit 744820869166c8c78be891240cf5f66e8a333694 ]

Debugfs file reset_stats is created with S_IRUSR permissions,
but ocrdma_dbgfs_ops_read() doesn't support OCRDMA_RESET_STATS,
whereas ocrdma_dbgfs_ops_write() supports only OCRDMA_RESET_STATS.

The patch fixes misstype with permissions.

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Anton Vasilyev <vasilyev@ispras.ru>
Acked-by: Selvin Xavier <selvin.xavier@broadcom.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/infiniband/hw/ocrdma/ocrdma_stats.c