Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 */
0002 /*
0003  *  Shared Memory Communications over RDMA (SMC-R) and RoCE
0004  *
0005  *  smc_sysctl.c: sysctl interface to SMC subsystem.
0006  *
0007  *  Copyright (c) 2022, Alibaba Inc.
0008  *
0009  *  Author: Tony Lu <tonylu@linux.alibaba.com>
0010  *
0011  */
0012 
0013 #ifndef _SMC_SYSCTL_H
0014 #define _SMC_SYSCTL_H
0015 
0016 #ifdef CONFIG_SYSCTL
0017 
0018 int __net_init smc_sysctl_net_init(struct net *net);
0019 void __net_exit smc_sysctl_net_exit(struct net *net);
0020 
0021 #else
0022 
0023 static inline int smc_sysctl_net_init(struct net *net)
0024 {
0025     net->smc.sysctl_autocorking_size = SMC_AUTOCORKING_DEFAULT_SIZE;
0026     return 0;
0027 }
0028 
0029 static inline void smc_sysctl_net_exit(struct net *net) { }
0030 
0031 #endif /* CONFIG_SYSCTL */
0032 
0033 #endif /* _SMC_SYSCTL_H */