diff options
author | Ursula Braun <ubraun@linux.vnet.ibm.com> | 2017-01-09 16:55:23 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-01-09 16:07:40 -0500 |
commit | e6727f39004bd95725342b3b343a14c7d59df07f (patch) | |
tree | 376bebbead3f9f2cabaddd75cfd34c32fe16ffda /net/smc/smc_cdc.c | |
parent | 5f08318f617b05b6ee389d8bd174c7af921ebf19 (diff) | |
download | linux-e6727f39004bd95725342b3b343a14c7d59df07f.tar.bz2 |
smc: send data (through RDMA)
copy data to kernel send buffer, and trigger RDMA write
Signed-off-by: Ursula Braun <ubraun@linux.vnet.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 | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/net/smc/smc_cdc.c b/net/smc/smc_cdc.c index 111d23ff9e17..77fe16967376 100644 --- a/net/smc/smc_cdc.c +++ b/net/smc/smc_cdc.c @@ -14,6 +14,7 @@ #include "smc.h" #include "smc_wr.h" #include "smc_cdc.h" +#include "smc_tx.h" /********************************** send *************************************/ @@ -52,7 +53,7 @@ static void smc_cdc_tx_handler(struct smc_wr_tx_pend_priv *pnd_snd, smc_curs_read(&cdcpend->cursor, cdcpend->conn), cdcpend->conn); } - /* subsequent patch: wake if send buffer space available */ + smc_tx_sndbuf_nonfull(smc); bh_unlock_sock(&smc->sk); } @@ -204,7 +205,9 @@ static void smc_cdc_msg_recv_action(struct smc_sock *smc, /* subsequent patch: terminate connection */ /* piggy backed tx info */ - /* subsequent patch: wake receivers if receive buffer space available */ + /* trigger sndbuf consumer: RDMA write into peer RMBE and CDC */ + if (diff_cons && smc_tx_prepared_sends(conn)) + smc_tx_sndbuf_nonempty(conn); /* subsequent patch: trigger socket release if connection closed */ |