diff options
author | Hans Wippel <hwippel@linux.ibm.com> | 2018-05-18 09:34:11 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-05-18 13:15:01 -0400 |
commit | 9fda3510ab6002a9c77cc21de0d6d8c48cf1abba (patch) | |
tree | 13d4cdf035ef2e6c4c2d7eaa03a0220908d416dc /net/smc/smc_core.h | |
parent | 69cb7dc0218b2c54416722eddf181e720f24c305 (diff) | |
download | lwn-9fda3510ab6002a9c77cc21de0d6d8c48cf1abba.tar.gz lwn-9fda3510ab6002a9c77cc21de0d6d8c48cf1abba.zip |
net/smc: move link group list to smc_core
This patch moves the global link group list to smc_core where the link
group functions are. To make this work, it moves code in af_smc and
smc_ib that operates on the link group list to smc_core as well.
While at it, the link group counter is integrated into the list
structure and initialized to zero.
Signed-off-by: Hans Wippel <hwippel@linux.ibm.com>
Signed-off-by: Ursula Braun <ubraun@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/smc/smc_core.h')
-rw-r--r-- | net/smc/smc_core.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/net/smc/smc_core.h b/net/smc/smc_core.h index 4885a7efa84f..3d4bd7011ab3 100644 --- a/net/smc/smc_core.h +++ b/net/smc/smc_core.h @@ -23,10 +23,9 @@ struct smc_lgr_list { /* list of link group definition */ struct list_head list; spinlock_t lock; /* protects list of link groups */ + u32 num; /* unique link group number */ }; -extern struct smc_lgr_list smc_lgr_list; /* list of link groups */ - enum smc_lgr_role { /* possible roles of a link group */ SMC_CLNT, /* client */ SMC_SERV /* server */ @@ -210,6 +209,7 @@ struct smc_clc_msg_accept_confirm; void smc_lgr_free(struct smc_link_group *lgr); void smc_lgr_forget(struct smc_link_group *lgr); void smc_lgr_terminate(struct smc_link_group *lgr); +void smc_port_terminate(struct smc_ib_device *smcibdev, u8 ibport); int smc_buf_create(struct smc_sock *smc); int smc_rmb_rtoken_handling(struct smc_connection *conn, struct smc_clc_msg_accept_confirm *clc); @@ -219,4 +219,5 @@ void smc_sndbuf_sync_sg_for_cpu(struct smc_connection *conn); void smc_sndbuf_sync_sg_for_device(struct smc_connection *conn); void smc_rmb_sync_sg_for_cpu(struct smc_connection *conn); void smc_rmb_sync_sg_for_device(struct smc_connection *conn); +void smc_core_exit(void); #endif |