RDMA/bnxt_re: Delete unsupported modify_port function
Subsystems (2)
PATCH 1/1 RDMA/bnxt_re: Delete unsupported modify_port function
From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/[email protected]>
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.
--- drivers/infiniband/hw/bnxt_re/ib_verbs.c | 17 ----------------- drivers/infiniband/hw/bnxt_re/ib_verbs.h | 3 --- drivers/infiniband/hw/bnxt_re/main.c | 1 - 3 files changed, 21 deletions(-)
drivers/infiniband/hw/bnxt_re/ib_verbs.c +0 -17
@@ -271,23 +271,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) {
drivers/infiniband/hw/bnxt_re/ib_verbs.h +0 -3
@@ -129,9 +129,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,
drivers/infiniband/hw/bnxt_re/main.c +0 -1
@@ -473,7 +473,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;
--
2.12.2
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): 20170601062434.22566-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org
Dennis Dalessandro
Reviewed-byQuoted 7 lines · Leon Romanovsky
From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/[email protected]>
There is no need to return always zero for function which is not supported. The IB stack treats uninitialized
ib_device->functionsas not implemented.
If there are plans to actually do something here for-next I think the function could stay, but if not then I agree just remove it and:
-Denny
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Yuval Shaia
Reviewed-byQuoted 68 lines · Leon Romanovsky
From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/[email protected]>
There is no need to return always zero for function which is not supported. The IB stack treats uninitialized
ib_device->functionsas not implemented.--- drivers/infiniband/hw/bnxt_re/ib_verbs.c | 17 ----------------- drivers/infiniband/hw/bnxt_re/ib_verbs.h | 3 --- drivers/infiniband/hw/bnxt_re/main.c | 1 - 3 files changed, 21 deletions(-)drivers/infiniband/hw/bnxt_re/ib_verbs.c +0
-17@@ -271,23 +271,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) {drivers/infiniband/hw/bnxt_re/ib_verbs.h +0
-3@@ -129,9 +129,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,drivers/infiniband/hw/bnxt_re/main.c +0
-2@@ -473,7 +473,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; --
Quoted 1 line
2.12.2
Quoted 5 lines
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Selvin Xavier
Acked-byQuoted 7 lines · Leon Romanovsky
From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/[email protected]>
There is no need to return always zero for function which is not supported. The IB stack treats uninitialized
ib_device->functionsas not implemented.
Thanks
Selvin Xavier
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
A message that is not in the archive (sent off-list or not yet received): CA+sbYW3p-g1KgGDzc8XtVsQXb4ymqmK8QmPcdKiNsMdmp3e27g-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org
Doug Ledford
AppliedQuoted 9 lines · Selvin Xavier
Quoted 7 lines · Leon Romanovsky
From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/[email protected]>
There is no need to return always zero for function which is not supported. The IB stack treats uninitialized
ib_device->functionsas
not implemented.
Quoted 4 lines
Quoted 1 line
Thanks, applied.
Signature · 8 lines
Doug Ledford <[email protected]> GPG KeyID: B826A3330E572FDD Key fingerprint = AE6B 1BDA 122B 23B4 265B 1274 B826 A333 0E57 2FDD -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html