aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Gurtovoy <maxg@mellanox.com>2018-05-31 04:05:24 -0400
committerJason Gunthorpe <jgg@mellanox.com>2018-06-04 11:19:24 -0400
commitca24da008fd665db125aed889e857ccaa033de84 (patch)
treeb983d5c8e7f1991a78332ecf991b6b6c0de6b2aa
parent0e12af84cdd3056460f928adc164f9e87f4b303b (diff)
RDMA/core: introduce check masks for T10-PI offload
T10-PI offload capability is currently supported in iSER protocol only, and the definition of the HCA protection information checks are missing from the core layer. Add those definition to avoid code duplication in other drivers (such iSER target and NVMeoF). Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Sagi Grimberg <sagi@grimberg.me> Reviewed-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: Max Gurtovoy <maxg@mellanox.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
-rw-r--r--include/rdma/ib_verbs.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h
index 2cc04abb6df8..2043e1a8f851 100644
--- a/include/rdma/ib_verbs.h
+++ b/include/rdma/ib_verbs.h
@@ -861,6 +861,19 @@ enum ib_sig_err_type {
861}; 861};
862 862
863/** 863/**
864 * Signature check masks (8 bytes in total) according to the T10-PI standard:
865 * -------- -------- ------------
866 * | GUARD | APPTAG | REFTAG |
867 * | 2B | 2B | 4B |
868 * -------- -------- ------------
869 */
870enum {
871 IB_SIG_CHECK_GUARD = 0xc0,
872 IB_SIG_CHECK_APPTAG = 0x30,
873 IB_SIG_CHECK_REFTAG = 0x0f,
874};
875
876/**
864 * struct ib_sig_err - signature error descriptor 877 * struct ib_sig_err - signature error descriptor
865 */ 878 */
866struct ib_sig_err { 879struct ib_sig_err {