aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/bnxt_re/qplib_sp.h
diff options
context:
space:
mode:
authorDevesh Sharma <devesh.sharma@broadcom.com>2017-06-29 12:28:16 -0700
committerDoug Ledford <dledford@redhat.com>2017-07-20 11:20:50 -0400
commit254cd2590d408f2c0375fbf73ef8250d47529e7b (patch)
tree48f0a0954f92d87fd841f71f122dd486537d0c1f /drivers/infiniband/hw/bnxt_re/qplib_sp.h
parentRDMA/bnxt_re: Specify RDMA component when allocating stats context (diff)
downloadlinux-dev-254cd2590d408f2c0375fbf73ef8250d47529e7b.tar.xz
linux-dev-254cd2590d408f2c0375fbf73ef8250d47529e7b.zip
RDMA/bnxt_re: Enable atomics only if host bios supports
Driver shall check if the host system bios has enabled Atomic operations capability in PCI Device Control 2 register of the pci-device. Expose the ATOMIC_HCA flag only if the Atomic operations capability is set. Signed-off-by: Devesh Sharma <devesh.sharma@broadcom.com> Signed-off-by: Selvin Xavier <selvin.xavier@broadcom.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to '')
-rw-r--r--drivers/infiniband/hw/bnxt_re/qplib_sp.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/bnxt_re/qplib_sp.h b/drivers/infiniband/hw/bnxt_re/qplib_sp.h
index a543f959098b..2ce7e2a32cf0 100644
--- a/drivers/infiniband/hw/bnxt_re/qplib_sp.h
+++ b/drivers/infiniband/hw/bnxt_re/qplib_sp.h
@@ -42,6 +42,8 @@
#define BNXT_QPLIB_RESERVED_QP_WRS 128
+#define PCI_EXP_DEVCTL2_ATOMIC_REQ 0x0040
+
struct bnxt_qplib_dev_attr {
char fw_ver[32];
u16 max_sgid;
@@ -70,6 +72,7 @@ struct bnxt_qplib_dev_attr {
u32 max_inline_data;
u32 l2_db_size;
u8 tqm_alloc_reqs[MAX_TQM_ALLOC_REQ];
+ bool is_atomic;
};
struct bnxt_qplib_pd {