From: Leon Romanovsky <leon-2ukJVAZIZ/Y@public.gmane.org>
To: dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org,
saeedm-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org
Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
Subject: [PATCH rdma-next 6/8] IB/core: Add offload arithmetic operations support
Date: Sat, 20 Feb 2016 09:47:43 +0200 [thread overview]
Message-ID: <1455954465-15141-7-git-send-email-leon@leon.nu> (raw)
In-Reply-To: <1455954465-15141-1-git-send-email-leon-2ukJVAZIZ/Y@public.gmane.org>
From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
The offload arithmetic operations support allows to the user to
benefit from the parallel calculation of several input vectors of
equal length.
The newly added flag indicates this ability.
Signed-off-by: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
Reviewed-by: Matan Barak <matanb-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
---
drivers/infiniband/core/uverbs_cmd.c | 3 +++
include/rdma/ib_verbs.h | 8 +++++++-
include/uapi/rdma/ib_user_verbs.h | 5 +++++
3 files changed, 15 insertions(+), 1 deletion(-)
diff --git a/drivers/infiniband/core/uverbs_cmd.c b/drivers/infiniband/core/uverbs_cmd.c
index 6887252..3a3f573 100644
--- a/drivers/infiniband/core/uverbs_cmd.c
+++ b/drivers/infiniband/core/uverbs_cmd.c
@@ -3638,6 +3638,9 @@ int ib_uverbs_ex_query_device(struct ib_uverbs_file *file,
resp.hca_core_clock = attr.hca_core_clock;
resp.response_length += sizeof(resp.hca_core_clock);
+ resp.device_cap_flags2 = upper_32_bits(attr.device_cap_flags);
+ resp.response_length += sizeof(resp.device_cap_flags2);
+
end:
err = ib_copy_to_udata(ucore, &resp, resp.response_length);
return err;
diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h
index 2ff1fd1..51aabf8 100644
--- a/include/rdma/ib_verbs.h
+++ b/include/rdma/ib_verbs.h
@@ -208,10 +208,16 @@ enum ib_device_cap_flags {
* of I/O operations with single completion queue managed
* by hardware.
*/
- IB_DEVICE_CROSS_CHANNEL = (1 << 27),
+ IB_DEVICE_CROSS_CHANNEL = (1 << 27),
IB_DEVICE_MANAGED_FLOW_STEERING = (1 << 29),
IB_DEVICE_SIGNATURE_HANDOVER = (1 << 30),
IB_DEVICE_ON_DEMAND_PAGING = (1 << 31),
+ /*
+ * The offload arithmetic operations support allows to
+ * the user to benefit from the parallel calculation of
+ * several input vectors of equal length.
+ */
+ IB_DEVICE_VECTOR_CALC = (1ULL << 32),
};
enum ib_signature_prot_cap {
diff --git a/include/uapi/rdma/ib_user_verbs.h b/include/uapi/rdma/ib_user_verbs.h
index 8126c14..e024c82 100644
--- a/include/uapi/rdma/ib_user_verbs.h
+++ b/include/uapi/rdma/ib_user_verbs.h
@@ -226,6 +226,11 @@ struct ib_uverbs_ex_query_device_resp {
struct ib_uverbs_odp_caps odp_caps;
__u64 timestamp_mask;
__u64 hca_core_clock; /* in KHZ */
+ /*
+ * Original capability field is limited
+ * by __u32 variable. Need to increase this field
+ */
+ __u64 device_cap_flags2;
};
struct ib_uverbs_query_port {
--
2.1.4
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2016-02-20 7:47 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-20 7:47 [PATCH rdma-next 0/8] Introduce vector CALC support Leon Romanovsky
[not found] ` <1455954465-15141-1-git-send-email-leon-2ukJVAZIZ/Y@public.gmane.org>
2016-02-20 7:47 ` [PATCH rdma-next 1/8] net/mlx5_core: Fix caching ATOMIC endian mode capability Leon Romanovsky
2016-02-20 7:47 ` [PATCH rdma-next 2/8] net/mlx5_core: Refactor device capability function Leon Romanovsky
2016-02-20 7:47 ` [PATCH rdma-next 3/8] net/mlx5_core: Introduce offload arithmetic hardware capabilities Leon Romanovsky
[not found] ` <1455954465-15141-4-git-send-email-leon-2ukJVAZIZ/Y@public.gmane.org>
2016-02-20 15:13 ` Leon Romanovsky
2016-02-28 22:05 ` Max Gurtovoy
2016-02-20 7:47 ` [PATCH rdma-next 4/8] IB/core: Replace setting the zero values in ib_uverbs_ex_query_device Leon Romanovsky
2016-02-20 7:47 ` [PATCH rdma-next 5/8] IB/{core,ulp} Support above 32 possible device capability flags Leon Romanovsky
[not found] ` <1455954465-15141-6-git-send-email-leon-2ukJVAZIZ/Y@public.gmane.org>
2016-02-21 7:39 ` Haggai Eran
[not found] ` <56C969B5.5080802-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2016-02-21 8:00 ` Leon Romanovsky
[not found] ` <20160221080053.GL30450-2ukJVAZIZ/Y@public.gmane.org>
2016-02-22 20:02 ` Jason Gunthorpe
2016-02-20 7:47 ` Leon Romanovsky [this message]
[not found] ` <1455954465-15141-7-git-send-email-leon-2ukJVAZIZ/Y@public.gmane.org>
2016-02-28 22:22 ` [PATCH rdma-next 6/8] IB/core: Add offload arithmetic operations support Max Gurtovoy
2016-02-20 7:47 ` [PATCH rdma-next 7/8] IB/core: Exposure supported CALC capabilities Leon Romanovsky
[not found] ` <1455954465-15141-8-git-send-email-leon-2ukJVAZIZ/Y@public.gmane.org>
2016-02-22 20:04 ` Jason Gunthorpe
2016-02-20 7:47 ` [PATCH rdma-next 8/8] IB/mlx5: Exposure offload arithmetic operations Leon Romanovsky
[not found] ` <1455954465-15141-9-git-send-email-leon-2ukJVAZIZ/Y@public.gmane.org>
2016-02-28 22:40 ` Max Gurtovoy
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=1455954465-15141-7-git-send-email-leon@leon.nu \
--to=leon-2ukjvaziz/y@public.gmane.org \
--cc=dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
--cc=leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
--cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=saeedm-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org \
/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