sunrpc: Const-ify all instances of struct rpc_xprt_ops
After transport instance creation, these function pointers never change. Mark them as constant to prevent their use as an attack vector for code injections. Signed-off-by: Chuck Lever <chuck.lever@oracle.com> Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
This commit is contained in:

committed by
Anna Schumaker

parent
16f73eb02d
commit
d31ae25481
@@ -266,7 +266,7 @@ xprt_rdma_bc_put(struct rpc_xprt *xprt)
|
||||
module_put(THIS_MODULE);
|
||||
}
|
||||
|
||||
static struct rpc_xprt_ops xprt_rdma_bc_procs = {
|
||||
static const struct rpc_xprt_ops xprt_rdma_bc_procs = {
|
||||
.reserve_xprt = xprt_reserve_xprt_cong,
|
||||
.release_xprt = xprt_release_xprt_cong,
|
||||
.alloc_slot = xprt_alloc_slot,
|
||||
|
Reference in New Issue
Block a user