diff options
author | Or Gerlitz <ogerlitz@mellanox.com> | 2013-12-12 18:03:17 +0200 |
---|---|---|
committer | Roland Dreier <roland@purestorage.com> | 2014-01-19 15:14:04 -0800 |
commit | ed4c54e5b4baf55a7a67a80fa766334855c94854 (patch) | |
tree | 24ee1fc584c644b7d74956be0994f0f4abd36df9 /drivers/infiniband/core/uverbs_cmd.c | |
parent | 37721d8501a9a1fbe87527c24d127a914b29fd7f (diff) | |
download | op-kernel-dev-ed4c54e5b4baf55a7a67a80fa766334855c94854.zip op-kernel-dev-ed4c54e5b4baf55a7a67a80fa766334855c94854.tar.gz |
IB/core: Resolve Ethernet L2 addresses when modifying QP
Existing user space applications provide only IBoE L3 address
attributes to the kernel when they issue a modify QP modify. To work
with them and let such apps (plus kernel consumers which don't use the
RDMA-CM) keep working transparently under the IBoE GID IP addressing
changes, add an Eth L2 address resolution helper.
Signed-off-by: Moni Shoua <monis@mellanox.co.il>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'drivers/infiniband/core/uverbs_cmd.c')
-rw-r--r-- | drivers/infiniband/core/uverbs_cmd.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/infiniband/core/uverbs_cmd.c b/drivers/infiniband/core/uverbs_cmd.c index f1cc838..ea6203e 100644 --- a/drivers/infiniband/core/uverbs_cmd.c +++ b/drivers/infiniband/core/uverbs_cmd.c @@ -40,6 +40,7 @@ #include <asm/uaccess.h> #include "uverbs.h" +#include "core_priv.h" struct uverbs_lock_class { struct lock_class_key key; @@ -1961,6 +1962,9 @@ ssize_t ib_uverbs_modify_qp(struct ib_uverbs_file *file, attr->alt_ah_attr.port_num = cmd.alt_dest.port_num; if (qp->real_qp == qp) { + ret = ib_resolve_eth_l2_attrs(qp, attr, &cmd.attr_mask); + if (ret) + goto out; ret = qp->device->modify_qp(qp, attr, modify_qp_mask(qp->qp_type, cmd.attr_mask), &udata); } else { |