From: Simon Horman <simon.horman@corigine.com>
To: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Cc: netdev@vger.kernel.org, Li Yang <leoyang.li@nxp.com>,
Eric Dumazet <edumazet@google.com>,
Michal Kubiak <michal.kubiak@intel.com>,
kernel@pengutronix.de, Jakub Kicinski <kuba@kernel.org>,
Paolo Abeni <pabeni@redhat.com>,
linuxppc-dev@lists.ozlabs.org,
"David S. Miller" <davem@davemloft.net>
Subject: Re: [PATCH net-next v2 8/8] net: ucc_geth: Convert to platform remove callback returning void
Date: Wed, 7 Jun 2023 16:36:59 +0200 [thread overview]
Message-ID: <ZICWC3Wy6/0/C413@corigine.com> (raw)
In-Reply-To: <20230606162829.166226-9-u.kleine-koenig@pengutronix.de>
On Tue, Jun 06, 2023 at 06:28:29PM +0200, Uwe Kleine-König wrote:
> The .remove() callback for a platform driver returns an int which makes
> many driver authors wrongly assume it's possible to do error handling by
> returning an error code. However the value returned is (mostly) ignored
> and this typically results in resource leaks. To improve here there is a
> quest to make the remove callback return void. In the first step of this
> quest all drivers are converted to .remove_new() which already returns
> void.
>
> Trivially convert this driver from always returning zero in the remove
> callback to the void returning variant.
>
> Reviewed-by: Michal Kubiak <michal.kubiak@intel.com>
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
WARNING: multiple messages have this Message-ID (diff)
From: Simon Horman <simon.horman@corigine.com>
To: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
Cc: Li Yang <leoyang.li@nxp.com>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
netdev@vger.kernel.org, linuxppc-dev@lists.ozlabs.org,
kernel@pengutronix.de, Michal Kubiak <michal.kubiak@intel.com>
Subject: Re: [PATCH net-next v2 8/8] net: ucc_geth: Convert to platform remove callback returning void
Date: Wed, 7 Jun 2023 16:36:59 +0200 [thread overview]
Message-ID: <ZICWC3Wy6/0/C413@corigine.com> (raw)
In-Reply-To: <20230606162829.166226-9-u.kleine-koenig@pengutronix.de>
On Tue, Jun 06, 2023 at 06:28:29PM +0200, Uwe Kleine-König wrote:
> The .remove() callback for a platform driver returns an int which makes
> many driver authors wrongly assume it's possible to do error handling by
> returning an error code. However the value returned is (mostly) ignored
> and this typically results in resource leaks. To improve here there is a
> quest to make the remove callback return void. In the first step of this
> quest all drivers are converted to .remove_new() which already returns
> void.
>
> Trivially convert this driver from always returning zero in the remove
> callback to the void returning variant.
>
> Reviewed-by: Michal Kubiak <michal.kubiak@intel.com>
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
next prev parent reply other threads:[~2023-06-07 14:38 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-06 16:28 [PATCH net-next v2 0/8] net: freescale: Convert to platform remove callback returning void Uwe Kleine-König
2023-06-06 16:28 ` Uwe Kleine-König
2023-06-06 16:28 ` [PATCH net-next v2 1/8] net: dpaa: Improve error reporting Uwe Kleine-König
2023-06-06 17:03 ` Maciej Fijalkowski
2023-06-07 6:42 ` Uwe Kleine-König
2023-06-07 7:58 ` Russell King (Oracle)
2023-06-06 16:28 ` [PATCH net-next v2 2/8] net: dpaa: Convert to platform remove callback returning void Uwe Kleine-König
2023-06-07 14:37 ` Simon Horman
2023-06-06 16:28 ` [PATCH net-next v2 3/8] net: fec: " Uwe Kleine-König
2023-06-07 6:48 ` Wei Fang
2023-06-07 14:39 ` Simon Horman
2023-06-06 16:28 ` [PATCH net-next v2 4/8] net: fman: " Uwe Kleine-König
2023-06-07 14:38 ` Simon Horman
2023-06-06 16:28 ` [PATCH net-next v2 5/8] net: fs_enet: " Uwe Kleine-König
2023-06-06 16:28 ` Uwe Kleine-König
2023-06-07 14:38 ` Simon Horman
2023-06-07 14:38 ` Simon Horman
2023-06-06 16:28 ` [PATCH net-next v2 6/8] net: fsl_pq_mdio: " Uwe Kleine-König
2023-06-07 14:38 ` Simon Horman
2023-06-06 16:28 ` [PATCH net-next v2 7/8] net: gianfar: " Uwe Kleine-König
2023-06-06 16:28 ` [PATCH net-next v2 8/8] net: ucc_geth: " Uwe Kleine-König
2023-06-06 16:28 ` Uwe Kleine-König
2023-06-07 14:36 ` Simon Horman [this message]
2023-06-07 14:36 ` Simon Horman
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=ZICWC3Wy6/0/C413@corigine.com \
--to=simon.horman@corigine.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kernel@pengutronix.de \
--cc=kuba@kernel.org \
--cc=leoyang.li@nxp.com \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=michal.kubiak@intel.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=u.kleine-koenig@pengutronix.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.