diff options
author | Eli Cohen <eli@mellanox.co.il> | 2008-01-30 11:30:57 -0500 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2008-02-08 17:37:56 -0500 |
commit | e0605d9199b462454f2f2e5ca01810255a6d5cfa (patch) | |
tree | c822a9a89fb74b1768dae4c3660474bc6304a35e /include/rdma/ib_verbs.h | |
parent | 7143740d26098aca84ecc7376ccfe2c58fd0412e (diff) |
IB/core: Add IP checksum offload support
Add a device capability to show when it can handle checksum offload.
Also add a send flag for inserting checksums and a csum_ok field to
the completion record.
Signed-off-by: Eli Cohen <eli@mellanox.co.il>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'include/rdma/ib_verbs.h')
-rw-r--r-- | include/rdma/ib_verbs.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h index cfbd38fe2998..a5a7f9678ab8 100644 --- a/include/rdma/ib_verbs.h +++ b/include/rdma/ib_verbs.h | |||
@@ -95,7 +95,15 @@ enum ib_device_cap_flags { | |||
95 | IB_DEVICE_N_NOTIFY_CQ = (1<<14), | 95 | IB_DEVICE_N_NOTIFY_CQ = (1<<14), |
96 | IB_DEVICE_ZERO_STAG = (1<<15), | 96 | IB_DEVICE_ZERO_STAG = (1<<15), |
97 | IB_DEVICE_SEND_W_INV = (1<<16), | 97 | IB_DEVICE_SEND_W_INV = (1<<16), |
98 | IB_DEVICE_MEM_WINDOW = (1<<17) | 98 | IB_DEVICE_MEM_WINDOW = (1<<17), |
99 | /* | ||
100 | * Devices should set IB_DEVICE_UD_IP_SUM if they support | ||
101 | * insertion of UDP and TCP checksum on outgoing UD IPoIB | ||
102 | * messages and can verify the validity of checksum for | ||
103 | * incoming messages. Setting this flag implies that the | ||
104 | * IPoIB driver may set NETIF_F_IP_CSUM for datagram mode. | ||
105 | */ | ||
106 | IB_DEVICE_UD_IP_CSUM = (1<<18), | ||
99 | }; | 107 | }; |
100 | 108 | ||
101 | enum ib_atomic_cap { | 109 | enum ib_atomic_cap { |
@@ -431,6 +439,7 @@ struct ib_wc { | |||
431 | u8 sl; | 439 | u8 sl; |
432 | u8 dlid_path_bits; | 440 | u8 dlid_path_bits; |
433 | u8 port_num; /* valid only for DR SMPs on switches */ | 441 | u8 port_num; /* valid only for DR SMPs on switches */ |
442 | int csum_ok; | ||
434 | }; | 443 | }; |
435 | 444 | ||
436 | enum ib_cq_notify_flags { | 445 | enum ib_cq_notify_flags { |
@@ -615,7 +624,8 @@ enum ib_send_flags { | |||
615 | IB_SEND_FENCE = 1, | 624 | IB_SEND_FENCE = 1, |
616 | IB_SEND_SIGNALED = (1<<1), | 625 | IB_SEND_SIGNALED = (1<<1), |
617 | IB_SEND_SOLICITED = (1<<2), | 626 | IB_SEND_SOLICITED = (1<<2), |
618 | IB_SEND_INLINE = (1<<3) | 627 | IB_SEND_INLINE = (1<<3), |
628 | IB_SEND_IP_CSUM = (1<<4) | ||
619 | }; | 629 | }; |
620 | 630 | ||
621 | struct ib_sge { | 631 | struct ib_sge { |