diff options
author | Dennis Dalessandro <dennis.dalessandro@intel.com> | 2017-04-09 20:17:18 +0300 |
---|---|---|
committer | Doug Ledford <dledford@redhat.com> | 2017-04-28 20:56:23 +0300 |
commit | ee495ada5c5681e66c20e9927fa35252bdf7fba0 (patch) | |
tree | 3f258e7af394f23993e63d3556e89e8a02c770e2 /drivers/infiniband/hw/hfi1/init.c | |
parent | 08af5916b3b0ace9c97e5bf5d89122a0c7aa5c58 (diff) | |
download | linux-ee495ada5c5681e66c20e9927fa35252bdf7fba0.tar.xz |
IB/hfi1: Fix unbalanced braces around else
Add missing braces around else blocks in a few places to make checkpatch
happy.
Fixes: 7724105686e7 ("IB/hfi1: add driver files")
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/hw/hfi1/init.c')
-rw-r--r-- | drivers/infiniband/hw/hfi1/init.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/infiniband/hw/hfi1/init.c b/drivers/infiniband/hw/hfi1/init.c index 51b760971e1e..4d6b9f82efa3 100644 --- a/drivers/infiniband/hw/hfi1/init.c +++ b/drivers/infiniband/hw/hfi1/init.c @@ -246,9 +246,10 @@ struct hfi1_ctxtdata *hfi1_create_ctxtdata(struct hfi1_pportdata *ppd, u32 ctxt, if (ctxt < kctxt_ngroups) { base = ctxt * (dd->rcv_entries.ngroups + 1); rcd->rcv_array_groups++; - } else + } else { base = kctxt_ngroups + (ctxt * dd->rcv_entries.ngroups); + } } else { u16 ct = ctxt - dd->first_dyn_alloc_ctxt; @@ -257,9 +258,10 @@ struct hfi1_ctxtdata *hfi1_create_ctxtdata(struct hfi1_pportdata *ppd, u32 ctxt, if (ct < dd->rcv_entries.nctxt_extra) { base += ct * (dd->rcv_entries.ngroups + 1); rcd->rcv_array_groups++; - } else + } else { base += dd->rcv_entries.nctxt_extra + (ct * dd->rcv_entries.ngroups); + } } rcd->eager_base = base * dd->rcv_entries.group_size; |