RDMA/bnxt_re: Delete unsupported modify_port function
authorLeon Romanovsky <leonro@mellanox.com>
Thu, 1 Jun 2017 06:24:34 +0000 (09:24 +0300)
committerDoug Ledford <dledford@redhat.com>
Mon, 24 Jul 2017 12:44:46 +0000 (08:44 -0400)
There is no need to return always zero for function which is not
supported. The IB stack treats uninitialized ib_device->functions as
not implemented.

Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com>
Acked-by: Selvin Xavier <selvin.xavier@broadcom.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/bnxt_re/ib_verbs.c
drivers/infiniband/hw/bnxt_re/ib_verbs.h
drivers/infiniband/hw/bnxt_re/main.c

index f0e01b3ac7116f582575bfc5f95f1ed15d68d47c..5dc6e7ce3ab91a34ce4c68705e9f34cd3b64eb60 100644 (file)
@@ -313,23 +313,6 @@ int bnxt_re_query_port(struct ib_device *ibdev, u8 port_num,
        return 0;
 }
 
-int bnxt_re_modify_port(struct ib_device *ibdev, u8 port_num,
-                       int port_modify_mask,
-                       struct ib_port_modify *port_modify)
-{
-       switch (port_modify_mask) {
-       case IB_PORT_SHUTDOWN:
-               break;
-       case IB_PORT_INIT_TYPE:
-               break;
-       case IB_PORT_RESET_QKEY_CNTR:
-               break;
-       default:
-               break;
-       }
-       return 0;
-}
-
 int bnxt_re_get_port_immutable(struct ib_device *ibdev, u8 port_num,
                               struct ib_port_immutable *immutable)
 {
index a0bb7e33d7ca4c2460713915fdda1b5a9ca57f5e..1df11ed272ea39671164b4c8f872144819d17c71 100644 (file)
@@ -141,9 +141,6 @@ int bnxt_re_modify_device(struct ib_device *ibdev,
                          struct ib_device_modify *device_modify);
 int bnxt_re_query_port(struct ib_device *ibdev, u8 port_num,
                       struct ib_port_attr *port_attr);
-int bnxt_re_modify_port(struct ib_device *ibdev, u8 port_num,
-                       int port_modify_mask,
-                       struct ib_port_modify *port_modify);
 int bnxt_re_get_port_immutable(struct ib_device *ibdev, u8 port_num,
                               struct ib_port_immutable *immutable);
 int bnxt_re_query_pkey(struct ib_device *ibdev, u8 port_num,
index ceae2d92fb08b9c4591d387db8228fafe16b48f8..deec8002dd3664fd30e3aa72b6ee535ccb3881d8 100644 (file)
@@ -474,7 +474,6 @@ static int bnxt_re_register_ib(struct bnxt_re_dev *rdev)
        ibdev->modify_device            = bnxt_re_modify_device;
 
        ibdev->query_port               = bnxt_re_query_port;
-       ibdev->modify_port              = bnxt_re_modify_port;
        ibdev->get_port_immutable       = bnxt_re_get_port_immutable;
        ibdev->query_pkey               = bnxt_re_query_pkey;
        ibdev->query_gid                = bnxt_re_query_gid;