From: Ophir Munk <ophirmu@mellanox.com>
To: dev@dpdk.org, Matan Azrad <matan@mellanox.com>,
Raslan Darawsheh <rasland@mellanox.com>
Cc: Ophir Munk <ophirmu@mellanox.com>
Subject: [dpdk-dev] [PATCH v1 6/8] common/mlx5: exclude ibv dependent calls in devx commands
Date: Wed, 10 Jun 2020 09:32:31 +0000 [thread overview]
Message-ID: <20200610093233.23902-7-ophirmu@mellanox.com> (raw)
In-Reply-To: <20200610093233.23902-1-ophirmu@mellanox.com>
Function mlx5_devx_cmd_qp_query_tis_td() receives as parameter a pointer
to verbs QP returned by ibv_create_qp. Therefore support it only if
HAVE_IBV_FLOW_DV_SUPPORT is defined. Otherwise return an error ENOTSUP.
Signed-off-by: Ophir Munk <ophirmu@mellanox.com>
---
drivers/common/mlx5/mlx5_devx_cmds.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/drivers/common/mlx5/mlx5_devx_cmds.c b/drivers/common/mlx5/mlx5_devx_cmds.c
index fba485e..091a825 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.c
+++ b/drivers/common/mlx5/mlx5_devx_cmds.c
@@ -577,6 +577,7 @@ int
mlx5_devx_cmd_qp_query_tis_td(void *qp, uint32_t tis_num,
uint32_t *tis_td)
{
+#ifdef HAVE_IBV_FLOW_DV_SUPPORT
uint32_t in[MLX5_ST_SZ_DW(query_tis_in)] = {0};
uint32_t out[MLX5_ST_SZ_DW(query_tis_out)] = {0};
int rc;
@@ -592,6 +593,12 @@ mlx5_devx_cmd_qp_query_tis_td(void *qp, uint32_t tis_num,
tis_ctx = MLX5_ADDR_OF(query_tis_out, out, tis_context);
*tis_td = MLX5_GET(tisc, tis_ctx, transport_domain);
return 0;
+#else
+ (void)qp;
+ (void)tis_num;
+ (void)tis_td;
+ return -ENOTSUP;
+#endif
}
/**
--
2.8.4
next prev parent reply other threads:[~2020-06-10 9:34 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-10 9:32 [dpdk-dev] [PATCH v1 0/8] mlx5 PMD multi OS support - part #2 Ophir Munk
2020-06-10 9:32 ` [dpdk-dev] [PATCH v1 1/8] net/mlx5: remove dv dependency in mlx5_dev_ctx_shared struct Ophir Munk
2020-06-10 9:32 ` [dpdk-dev] [PATCH v1 2/8] net/mlx5: rename ib in names Ophir Munk
2020-06-10 9:32 ` [dpdk-dev] [PATCH v1 3/8] net/mlx5: move socket files under Linux directory Ophir Munk
2020-06-10 9:32 ` [dpdk-dev] [PATCH v1 4/8] net/mlx5: split mlx5 ethdev " Ophir Munk
2020-06-10 9:32 ` [dpdk-dev] [PATCH v1 5/8] net/mlx5: refactor eth dev ops for Linux Ophir Munk
2020-06-10 9:32 ` Ophir Munk [this message]
2020-06-10 9:32 ` [dpdk-dev] [PATCH v1 7/8] common/mlx5: exclude OS dependency in devx commands Ophir Munk
2020-06-18 22:47 ` Thomas Monjalon
2020-06-18 22:48 ` Thomas Monjalon
2020-06-10 9:32 ` [dpdk-dev] [PATCH v1 8/8] net/mlx5: refactor statistics Ophir Munk
2020-06-14 8:21 ` [dpdk-dev] [PATCH v1 0/8] mlx5 PMD multi OS support - part #2 Matan Azrad
2020-06-15 6:58 ` Raslan Darawsheh
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200610093233.23902-7-ophirmu@mellanox.com \
--to=ophirmu@mellanox.com \
--cc=dev@dpdk.org \
--cc=matan@mellanox.com \
--cc=rasland@mellanox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).