IB/{core,hw}: Add constant for node_desc
[cascardo/linux.git] / drivers / infiniband / hw / cxgb3 / iwch_provider.c
index 3edb806..b47be87 100644 (file)
@@ -1396,6 +1396,7 @@ int iwch_register_device(struct iwch_dev *dev)
            (1ull << IB_USER_VERBS_CMD_POST_SEND) |
            (1ull << IB_USER_VERBS_CMD_POST_RECV);
        dev->ibdev.node_type = RDMA_NODE_RNIC;
+       BUILD_BUG_ON(sizeof(IWCH_NODE_DESC) > IB_DEVICE_NODE_DESC_MAX);
        memcpy(dev->ibdev.node_desc, IWCH_NODE_DESC, sizeof(IWCH_NODE_DESC));
        dev->ibdev.phys_port_cnt = dev->rdev.port_info.nports;
        dev->ibdev.num_comp_vectors = 1;