提交 a28c257c 编写于 作者: S Sowmini Varadhan 提交者: David S. Miller

net/rds: Declare SO_RDS_TRANSPORT and RDS_TRANS_* constants in uapi/linux/rds.h

User space applications that desire to explicitly select the
underlying transport for a PF_RDS socket may do so by using the
SO_RDS_TRANSPORT socket option at the SOL_RDS level before bind().
The integer argument provided to the socket option would be one
of the RDS_TRANS_* values, e.g., RDS_TRANS_TCP. This commit exports
the constant values need by such applications via <linux/rds.h>
Signed-off-by: NSowmini Varadhan <sowmini.varadhan@oracle.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 f16e9d86
...@@ -38,6 +38,8 @@ ...@@ -38,6 +38,8 @@
#define RDS_IB_ABI_VERSION 0x301 #define RDS_IB_ABI_VERSION 0x301
#define SOL_RDS 276
/* /*
* setsockopt/getsockopt for SOL_RDS * setsockopt/getsockopt for SOL_RDS
*/ */
...@@ -48,6 +50,14 @@ ...@@ -48,6 +50,14 @@
#define RDS_RECVERR 5 #define RDS_RECVERR 5
#define RDS_CONG_MONITOR 6 #define RDS_CONG_MONITOR 6
#define RDS_GET_MR_FOR_DEST 7 #define RDS_GET_MR_FOR_DEST 7
#define SO_RDS_TRANSPORT 8
/* supported values for SO_RDS_TRANSPORT */
#define RDS_TRANS_IB 0
#define RDS_TRANS_IWARP 1
#define RDS_TRANS_TCP 2
#define RDS_TRANS_COUNT 3
#define RDS_TRANS_NONE (~0)
/* /*
* Control message types for SOL_RDS. * Control message types for SOL_RDS.
......
...@@ -408,11 +408,6 @@ struct rds_notifier { ...@@ -408,11 +408,6 @@ struct rds_notifier {
* should try hard not to block. * should try hard not to block.
*/ */
#define RDS_TRANS_IB 0
#define RDS_TRANS_IWARP 1
#define RDS_TRANS_TCP 2
#define RDS_TRANS_COUNT 3
struct rds_transport { struct rds_transport {
char t_name[TRANSNAMSIZ]; char t_name[TRANSNAMSIZ];
struct list_head t_item; struct list_head t_item;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册