diff options
author | Karsten Graul <kgraul@linux.ibm.com> | 2018-05-15 17:04:58 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-05-16 11:49:19 -0400 |
commit | b32cf4ab68c06619bacefc7157857a08e7fee695 (patch) | |
tree | 08df6ef756f93389adff249d3dedaac9d0d958af /net/smc/smc_core.c | |
parent | d97935faee4ba2cc37676afd955e9f519a5affbf (diff) | |
download | linux-b32cf4ab68c06619bacefc7157857a08e7fee695.tar.gz linux-b32cf4ab68c06619bacefc7157857a08e7fee695.tar.bz2 linux-b32cf4ab68c06619bacefc7157857a08e7fee695.zip |
net/smc: move link llc initialization to llc layer
Move the llc layer specific initialization and cleanup out of smc_core.c
into smc_llc.c (smc_llc_link_init and smc_llc_link_clear). Move all
initialization of a link into the new init function.
Signed-off-by: Karsten Graul <kgraul@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.c')
-rw-r--r-- | net/smc/smc_core.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/net/smc/smc_core.c b/net/smc/smc_core.c index 29ae077b0ec9..ba7dae819ac8 100644 --- a/net/smc/smc_core.c +++ b/net/smc/smc_core.c @@ -194,6 +194,7 @@ static int smc_lgr_create(struct smc_sock *smc, smc_ib_setup_per_ibdev(smcibdev); get_random_bytes(rndvec, sizeof(rndvec)); lnk->psn_initial = rndvec[0] + (rndvec[1] << 8) + (rndvec[2] << 16); + smc_llc_link_init(lnk); rc = smc_wr_alloc_link_mem(lnk); if (rc) goto free_lgr; @@ -206,11 +207,6 @@ static int smc_lgr_create(struct smc_sock *smc, rc = smc_wr_create_link(lnk); if (rc) goto destroy_qp; - init_completion(&lnk->llc_confirm); - init_completion(&lnk->llc_confirm_resp); - init_completion(&lnk->llc_add); - init_completion(&lnk->llc_add_resp); - init_completion(&lnk->llc_confirm_rkey); smc->conn.lgr = lgr; rwlock_init(&lgr->conns_lock); |