diff options
author | Bryan O'Sullivan <bos@pathscale.com> | 2006-08-25 14:24:45 -0400 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2006-09-22 18:22:39 -0400 |
commit | d821f02a6ebed97e35e0bc7575452cfc6f9073cb (patch) | |
tree | a4457534d937843df8f15eb1a2f5c90ab3c46697 /drivers | |
parent | a78aa6fb156f9954562c9539aeb25dbec1ffca10 (diff) |
IB/ipath: allow SMA to be disabled
This is useful for testing purposes.
Signed-off-by: Bryan O'Sullivan <bryan.osullivan@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/infiniband/hw/ipath/ipath_verbs.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/ipath/ipath_verbs.c b/drivers/infiniband/hw/ipath/ipath_verbs.c index b9be0fd2ed36..fbda7739715f 100644 --- a/drivers/infiniband/hw/ipath/ipath_verbs.c +++ b/drivers/infiniband/hw/ipath/ipath_verbs.c | |||
@@ -107,6 +107,10 @@ module_param_named(max_srq_wrs, ib_ipath_max_srq_wrs, | |||
107 | uint, S_IWUSR | S_IRUGO); | 107 | uint, S_IWUSR | S_IRUGO); |
108 | MODULE_PARM_DESC(max_srq_wrs, "Maximum number of SRQ WRs support"); | 108 | MODULE_PARM_DESC(max_srq_wrs, "Maximum number of SRQ WRs support"); |
109 | 109 | ||
110 | static unsigned int ib_ipath_disable_sma; | ||
111 | module_param_named(disable_sma, ib_ipath_disable_sma, uint, S_IWUSR | S_IRUGO); | ||
112 | MODULE_PARM_DESC(ib_ipath_disable_sma, "Disable the SMA"); | ||
113 | |||
110 | const int ib_ipath_state_ops[IB_QPS_ERR + 1] = { | 114 | const int ib_ipath_state_ops[IB_QPS_ERR + 1] = { |
111 | [IB_QPS_RESET] = 0, | 115 | [IB_QPS_RESET] = 0, |
112 | [IB_QPS_INIT] = IPATH_POST_RECV_OK, | 116 | [IB_QPS_INIT] = IPATH_POST_RECV_OK, |
@@ -354,6 +358,9 @@ static void ipath_qp_rcv(struct ipath_ibdev *dev, | |||
354 | switch (qp->ibqp.qp_type) { | 358 | switch (qp->ibqp.qp_type) { |
355 | case IB_QPT_SMI: | 359 | case IB_QPT_SMI: |
356 | case IB_QPT_GSI: | 360 | case IB_QPT_GSI: |
361 | if (ib_ipath_disable_sma) | ||
362 | break; | ||
363 | /* FALLTHROUGH */ | ||
357 | case IB_QPT_UD: | 364 | case IB_QPT_UD: |
358 | ipath_ud_rcv(dev, hdr, has_grh, data, tlen, qp); | 365 | ipath_ud_rcv(dev, hdr, has_grh, data, tlen, qp); |
359 | break; | 366 | break; |