qed: iWARP CM add passive side connect
This patch implements the passive side connect. It addresses pre-allocating resources, creating a connection element upon valid SYN packet received. Calling upper layer and implementation of the accept/reject calls. Error handling is not part of this patch. Signed-off-by: Michal Kalderon <Michal.Kalderon@cavium.com> Signed-off-by: Yuval Mintz <Yuval.Mintz@cavium.com> Signed-off-by: Ariel Elior <Ariel.Elior@cavium.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
65a91a6cdb
commit
456a584947
@@ -38,6 +38,8 @@
|
||||
#include <linux/slab.h>
|
||||
|
||||
/* dma_addr_t manip */
|
||||
#define PTR_LO(x) ((u32)(((uintptr_t)(x)) & 0xffffffff))
|
||||
#define PTR_HI(x) ((u32)((((uintptr_t)(x)) >> 16) >> 16))
|
||||
#define DMA_LO_LE(x) cpu_to_le32(lower_32_bits(x))
|
||||
#define DMA_HI_LE(x) cpu_to_le32(upper_32_bits(x))
|
||||
#define DMA_REGPAIR_LE(x, val) do { \
|
||||
|
@@ -471,7 +471,8 @@ struct qed_rdma_counters_out_params {
|
||||
#define QED_ROCE_TX_FRAG_FAILURE (2)
|
||||
|
||||
enum qed_iwarp_event_type {
|
||||
QED_IWARP_EVENT_MPA_REQUEST, /* Passive side request received */
|
||||
QED_IWARP_EVENT_MPA_REQUEST, /* Passive side request received */
|
||||
QED_IWARP_EVENT_PASSIVE_COMPLETE, /* ack on mpa response */
|
||||
};
|
||||
|
||||
enum qed_tcp_ip_version {
|
||||
@@ -516,6 +517,23 @@ struct qed_iwarp_listen_out {
|
||||
void *handle;
|
||||
};
|
||||
|
||||
struct qed_iwarp_accept_in {
|
||||
void *ep_context;
|
||||
void *cb_context;
|
||||
struct qed_rdma_qp *qp;
|
||||
const void *private_data;
|
||||
u16 private_data_len;
|
||||
u8 ord;
|
||||
u8 ird;
|
||||
};
|
||||
|
||||
struct qed_iwarp_reject_in {
|
||||
void *ep_context;
|
||||
void *cb_context;
|
||||
const void *private_data;
|
||||
u16 private_data_len;
|
||||
};
|
||||
|
||||
struct qed_roce_ll2_header {
|
||||
void *vaddr;
|
||||
dma_addr_t baddr;
|
||||
@@ -626,6 +644,12 @@ struct qed_rdma_ops {
|
||||
struct qed_iwarp_listen_in *iparams,
|
||||
struct qed_iwarp_listen_out *oparams);
|
||||
|
||||
int (*iwarp_accept)(void *rdma_cxt,
|
||||
struct qed_iwarp_accept_in *iparams);
|
||||
|
||||
int (*iwarp_reject)(void *rdma_cxt,
|
||||
struct qed_iwarp_reject_in *iparams);
|
||||
|
||||
int (*iwarp_destroy_listen)(void *rdma_cxt, void *handle);
|
||||
|
||||
};
|
||||
|
Reference in New Issue
Block a user