mbox series

[net-next,00/19] can: Convert to platform remove callback returning void

Message ID 20230512212725.143824-1-u.kleine-koenig@pengutronix.de (mailing list archive)
Headers show
Series can: Convert to platform remove callback returning void | expand

Message

Uwe Kleine-König May 12, 2023, 9:27 p.m. UTC
Hello,

this series convers the drivers below drivers/net/can to the
.remove_new() callback of struct platform_driver(). The motivation is to
make the remove callback less prone for errors and wrong assumptions.
See commit 5c5a7680e67b ("platform: Provide a remove callback that
returns no value") for a more detailed rationale.

All drivers already returned zero unconditionally in their
.remove() callback, so converting them to .remove_new() is trivial.

Best regards
Uwe

Uwe Kleine-König (19):
  can: at91_can: Convert to platform remove callback returning void
  can: bxcan: Convert to platform remove callback returning void
  can: c_can: Convert to platform remove callback returning void
  can: cc770_isa: Convert to platform remove callback returning void
  can: cc770_platform: Convert to platform remove callback returning void
  can: ctucanfd: Convert to platform remove callback returning void
  can: flexcan: Convert to platform remove callback returning void
  can: grcan: Convert to platform remove callback returning void
  can: ifi_canfd: Convert to platform remove callback returning void
  can: janz-ican3: Convert to platform remove callback returning void
  can: m_can: Convert to platform remove callback returning void
  can: mscan/mpc5xxx_can.c -- Convert to platform remove callback returning void
  can: rcar: Convert to platform remove callback returning void
  can: sja1000_isa: Convert to platform remove callback returning void
  can: sja1000_platform: Convert to platform remove callback returning void
  can: softing: Convert to platform remove callback returning void
  can: sun4i_can: Convert to platform remove callback returning void
  can: ti_hecc: Convert to platform remove callback returning void
  can: xilinx: Convert to platform remove callback returning void

 drivers/net/can/at91_can.c                   | 6 ++----
 drivers/net/can/bxcan.c                      | 5 ++---
 drivers/net/can/c_can/c_can_platform.c       | 6 ++----
 drivers/net/can/cc770/cc770_isa.c            | 6 ++----
 drivers/net/can/cc770/cc770_platform.c       | 6 ++----
 drivers/net/can/ctucanfd/ctucanfd_platform.c | 6 ++----
 drivers/net/can/flexcan/flexcan-core.c       | 6 ++----
 drivers/net/can/grcan.c                      | 6 ++----
 drivers/net/can/ifi_canfd/ifi_canfd.c        | 6 ++----
 drivers/net/can/janz-ican3.c                 | 6 ++----
 drivers/net/can/m_can/m_can_platform.c       | 6 ++----
 drivers/net/can/mscan/mpc5xxx_can.c          | 6 ++----
 drivers/net/can/rcar/rcar_can.c              | 5 ++---
 drivers/net/can/rcar/rcar_canfd.c            | 6 ++----
 drivers/net/can/sja1000/sja1000_isa.c        | 6 ++----
 drivers/net/can/sja1000/sja1000_platform.c   | 6 ++----
 drivers/net/can/softing/softing_main.c       | 5 ++---
 drivers/net/can/sun4i_can.c                  | 6 ++----
 drivers/net/can/ti_hecc.c                    | 6 ++----
 drivers/net/can/xilinx_can.c                 | 6 ++----
 20 files changed, 40 insertions(+), 77 deletions(-)


base-commit: ac9a78681b921877518763ba0e89202254349d1b

Comments

Simon Horman May 16, 2023, 7:31 a.m. UTC | #1
On Fri, May 12, 2023 at 11:27:06PM +0200, Uwe Kleine-König wrote:
> Hello,
> 
> this series convers the drivers below drivers/net/can to the
> .remove_new() callback of struct platform_driver(). The motivation is to
> make the remove callback less prone for errors and wrong assumptions.
> See commit 5c5a7680e67b ("platform: Provide a remove callback that
> returns no value") for a more detailed rationale.
> 
> All drivers already returned zero unconditionally in their
> .remove() callback, so converting them to .remove_new() is trivial.

Hi Uwe,

I like these changes and they all look good to me.
However, I have a question, perhaps more directed at the netdev
maintainers than yourself.

In principle patch-sets for netdev should not include more than 15 patches.
It's unclear to me if, on the basis of that, this patchset should
be split up. Or if, f.e. given the simple nature of the patches,
an exception applies in this case. Or something else.

I have no fixed opinion on this.
But I feel that the question should be asked.

Link: https://kernel.org/doc/html/v6.1/process/maintainer-netdev.html

...
Simon Horman May 16, 2023, 8:45 a.m. UTC | #2
On Tue, May 16, 2023 at 09:31:04AM +0200, Simon Horman wrote:
> On Fri, May 12, 2023 at 11:27:06PM +0200, Uwe Kleine-König wrote:
> > Hello,
> > 
> > this series convers the drivers below drivers/net/can to the
> > .remove_new() callback of struct platform_driver(). The motivation is to
> > make the remove callback less prone for errors and wrong assumptions.
> > See commit 5c5a7680e67b ("platform: Provide a remove callback that
> > returns no value") for a more detailed rationale.
> > 
> > All drivers already returned zero unconditionally in their
> > .remove() callback, so converting them to .remove_new() is trivial.
> 
> Hi Uwe,
> 
> I like these changes and they all look good to me.
> However, I have a question, perhaps more directed at the netdev
> maintainers than yourself.
> 
> In principle patch-sets for netdev should not include more than 15 patches.
> It's unclear to me if, on the basis of that, this patchset should
> be split up. Or if, f.e. given the simple nature of the patches,
> an exception applies in this case. Or something else.
> 
> I have no fixed opinion on this.
> But I feel that the question should be asked.
> 
> Link: https://kernel.org/doc/html/v6.1/process/maintainer-netdev.html
> 
> ...

I now realise this series is for can.
Which I assume means the guidance above doesn't apply.

Sorry for the noise.
Marc Kleine-Budde May 16, 2023, 8:54 a.m. UTC | #3
On 16.05.2023 10:45:23, Simon Horman wrote:
> On Tue, May 16, 2023 at 09:31:04AM +0200, Simon Horman wrote:
> > On Fri, May 12, 2023 at 11:27:06PM +0200, Uwe Kleine-König wrote:
> > > Hello,
> > > 
> > > this series convers the drivers below drivers/net/can to the
> > > .remove_new() callback of struct platform_driver(). The motivation is to
> > > make the remove callback less prone for errors and wrong assumptions.
> > > See commit 5c5a7680e67b ("platform: Provide a remove callback that
> > > returns no value") for a more detailed rationale.
> > > 
> > > All drivers already returned zero unconditionally in their
> > > .remove() callback, so converting them to .remove_new() is trivial.
> > 
> > Hi Uwe,
> > 
> > I like these changes and they all look good to me.
> > However, I have a question, perhaps more directed at the netdev
> > maintainers than yourself.
> > 
> > In principle patch-sets for netdev should not include more than 15 patches.
> > It's unclear to me if, on the basis of that, this patchset should
> > be split up. Or if, f.e. given the simple nature of the patches,
> > an exception applies in this case. Or something else.
> > 
> > I have no fixed opinion on this.
> > But I feel that the question should be asked.
> > 
> > Link: https://kernel.org/doc/html/v6.1/process/maintainer-netdev.html
> > 
> > ...
> 
> I now realise this series is for can.
> Which I assume means the guidance above doesn't apply.
> 
> Sorry for the noise.

That's still a good point, because sooner or later Uwe will probably
also convert the platform drivers to Driver/Network/Ethernet.

Marc
Marc Kleine-Budde May 16, 2023, 8:56 a.m. UTC | #4
On 16.05.2023 10:54:06, Marc Kleine-Budde wrote:
> On 16.05.2023 10:45:23, Simon Horman wrote:
> > On Tue, May 16, 2023 at 09:31:04AM +0200, Simon Horman wrote:
> > > On Fri, May 12, 2023 at 11:27:06PM +0200, Uwe Kleine-König wrote:
> > > > Hello,
> > > > 
> > > > this series convers the drivers below drivers/net/can to the
> > > > .remove_new() callback of struct platform_driver(). The motivation is to
> > > > make the remove callback less prone for errors and wrong assumptions.
> > > > See commit 5c5a7680e67b ("platform: Provide a remove callback that
> > > > returns no value") for a more detailed rationale.
> > > > 
> > > > All drivers already returned zero unconditionally in their
> > > > .remove() callback, so converting them to .remove_new() is trivial.
> > > 
> > > Hi Uwe,
> > > 
> > > I like these changes and they all look good to me.
> > > However, I have a question, perhaps more directed at the netdev
> > > maintainers than yourself.
> > > 
> > > In principle patch-sets for netdev should not include more than 15 patches.
> > > It's unclear to me if, on the basis of that, this patchset should
> > > be split up. Or if, f.e. given the simple nature of the patches,
> > > an exception applies in this case. Or something else.
> > > 
> > > I have no fixed opinion on this.
> > > But I feel that the question should be asked.
> > > 
> > > Link: https://kernel.org/doc/html/v6.1/process/maintainer-netdev.html
> > > 
> > > ...
> > 
> > I now realise this series is for can.
> > Which I assume means the guidance above doesn't apply.
> > 
> > Sorry for the noise.
> 
> That's still a good point, because sooner or later Uwe will probably
> also convert the platform drivers to Driver/Network/Ethernet.

...in driver/net/ethernet.

(damnyouautocorrect)

Marc