* [PATCH iwl-next] idpf: update idpf_up_complete() return type to void
@ 2025-11-26 17:02 Sreedevi Joshi
2025-11-29 10:54 ` Simon Horman
0 siblings, 1 reply; 2+ messages in thread
From: Sreedevi Joshi @ 2025-11-26 17:02 UTC (permalink / raw)
To: intel-wired-lan; +Cc: netdev, Sreedevi Joshi, Aleksandr Loktionov
idpf_up_complete() function always returns 0 and no callers use this return
value. Although idpf_vport_open() checks the return value, it only handles
error cases which never occur. Change the return type to void to simplify
the code.
Signed-off-by: Sreedevi Joshi <sreedevi.joshi@intel.com>
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
---
drivers/net/ethernet/intel/idpf/idpf_lib.c | 15 ++-------------
1 file changed, 2 insertions(+), 13 deletions(-)
diff --git a/drivers/net/ethernet/intel/idpf/idpf_lib.c b/drivers/net/ethernet/intel/idpf/idpf_lib.c
index 69eb72ed6b99..b9424cfb13c7 100644
--- a/drivers/net/ethernet/intel/idpf/idpf_lib.c
+++ b/drivers/net/ethernet/intel/idpf/idpf_lib.c
@@ -1444,10 +1444,8 @@ static int idpf_set_real_num_queues(struct idpf_vport *vport)
/**
* idpf_up_complete - Complete interface up sequence
* @vport: virtual port structure
- *
- * Returns 0 on success, negative on failure.
*/
-static int idpf_up_complete(struct idpf_vport *vport)
+static void idpf_up_complete(struct idpf_vport *vport)
{
struct idpf_netdev_priv *np = netdev_priv(vport->netdev);
@@ -1457,8 +1455,6 @@ static int idpf_up_complete(struct idpf_vport *vport)
}
set_bit(IDPF_VPORT_UP, np->state);
-
- return 0;
}
/**
@@ -1610,20 +1606,13 @@ static int idpf_vport_open(struct idpf_vport *vport, bool rtnl)
goto disable_vport;
}
- err = idpf_up_complete(vport);
- if (err) {
- dev_err(&adapter->pdev->dev, "Failed to complete interface up for vport %u: %d\n",
- vport->vport_id, err);
- goto deinit_rss;
- }
+ idpf_up_complete(vport);
if (rtnl)
rtnl_unlock();
return 0;
-deinit_rss:
- idpf_deinit_rss(rss_data);
disable_vport:
idpf_send_disable_vport_msg(adapter, vport_id);
disable_queues:
--
2.25.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH iwl-next] idpf: update idpf_up_complete() return type to void
2025-11-26 17:02 [PATCH iwl-next] idpf: update idpf_up_complete() return type to void Sreedevi Joshi
@ 2025-11-29 10:54 ` Simon Horman
0 siblings, 0 replies; 2+ messages in thread
From: Simon Horman @ 2025-11-29 10:54 UTC (permalink / raw)
To: Sreedevi Joshi; +Cc: intel-wired-lan, netdev, Aleksandr Loktionov
On Wed, Nov 26, 2025 at 11:02:16AM -0600, Sreedevi Joshi wrote:
> idpf_up_complete() function always returns 0 and no callers use this return
> value. Although idpf_vport_open() checks the return value, it only handles
> error cases which never occur. Change the return type to void to simplify
> the code.
>
> Signed-off-by: Sreedevi Joshi <sreedevi.joshi@intel.com>
> Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Reviewed-by: Simon Horman <horms@kernel.org>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2025-11-29 10:54 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-26 17:02 [PATCH iwl-next] idpf: update idpf_up_complete() return type to void Sreedevi Joshi
2025-11-29 10:54 ` Simon Horman
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).