diff options
author | Stefan Raspl <raspl@linux.ibm.com> | 2018-07-23 13:53:10 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-07-23 10:57:14 -0700 |
commit | 00e5fb263f9f5f2af60754b79b7dcec0d5e88154 (patch) | |
tree | bc20d7d57cf070dfe0736eb8fad4ed855304210e /net/smc/smc_cdc.c | |
parent | bac6de7b637018f4caacfdf2b4ad8c8749de7420 (diff) | |
download | talos-obmc-linux-00e5fb263f9f5f2af60754b79b7dcec0d5e88154.tar.gz talos-obmc-linux-00e5fb263f9f5f2af60754b79b7dcec0d5e88154.zip |
net/smc: add function to get link group from link
Replace a frequently used construct with a more readable variant,
reducing the code. Also might come handy when we start to support
more than a single per link group.
Signed-off-by: Stefan Raspl <raspl@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_cdc.c')
-rw-r--r-- | net/smc/smc_cdc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/smc/smc_cdc.c b/net/smc/smc_cdc.c index f3a1497953ee..a7af2289cdff 100644 --- a/net/smc/smc_cdc.c +++ b/net/smc/smc_cdc.c @@ -365,7 +365,7 @@ static void smc_cdc_rx_handler(struct ib_wc *wc, void *buf) return; /* invalid message */ /* lookup connection */ - lgr = container_of(link, struct smc_link_group, lnk[SMC_SINGLE_LINK]); + lgr = smc_get_lgr(link); read_lock_bh(&lgr->conns_lock); conn = smc_lgr_find_conn(ntohl(cdc->token), lgr); read_unlock_bh(&lgr->conns_lock); |