diff options
author | Ingo Molnar <mingo@kernel.org> | 2020-11-07 13:18:49 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2020-11-07 13:18:49 +0100 |
commit | 0a986ea81e1aa8ac17e82cda53cc95158217956e (patch) | |
tree | a054b0ef413b7f327c04137c5768b2da6488511d /drivers/infiniband/hw/bnxt_re/qplib_rcfw.h | |
parent | kprobes: Replace rp->free_instance with freelist (diff) | |
parent | kprobes: Init kprobes in early_initcall (diff) | |
download | linux-dev-0a986ea81e1aa8ac17e82cda53cc95158217956e.tar.xz linux-dev-0a986ea81e1aa8ac17e82cda53cc95158217956e.zip |
Merge branch 'linus' into perf/kprobes
Merge recent kprobes updates into perf/kprobes that came from -mm.
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'drivers/infiniband/hw/bnxt_re/qplib_rcfw.h')
-rw-r--r-- | drivers/infiniband/hw/bnxt_re/qplib_rcfw.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/bnxt_re/qplib_rcfw.h b/drivers/infiniband/hw/bnxt_re/qplib_rcfw.h index 157387636d00..5f2f0a5a3560 100644 --- a/drivers/infiniband/hw/bnxt_re/qplib_rcfw.h +++ b/drivers/infiniband/hw/bnxt_re/qplib_rcfw.h @@ -216,4 +216,9 @@ int bnxt_qplib_deinit_rcfw(struct bnxt_qplib_rcfw *rcfw); int bnxt_qplib_init_rcfw(struct bnxt_qplib_rcfw *rcfw, struct bnxt_qplib_ctx *ctx, int is_virtfn); void bnxt_qplib_mark_qp_error(void *qp_handle); +static inline u32 map_qp_id_to_tbl_indx(u32 qid, struct bnxt_qplib_rcfw *rcfw) +{ + /* Last index of the qp_tbl is for QP1 ie. qp_tbl_size - 1*/ + return (qid == 1) ? rcfw->qp_tbl_size - 1 : qid % rcfw->qp_tbl_size - 2; +} #endif /* __BNXT_QPLIB_RCFW_H__ */ |