scsci: Convert to platform remove callback returning void
Subsystems (2)
cover scsci: Convert to platform remove callback returning void
Hello,
this series converts all drivers below drivers/scsi to struct platform_driver::remove_new(). See commit 5c5a7680e67b ("platform:
Provide a remove callback that returns no value") for an extended explanation and the eventual goal.
All conversations are trivial, because all .remove() callbacks returned zero unconditionally.
Best regards
Uwe
Uwe Kleine-König (14):
scsi: a3000: Convert to platform remove callback returning void
scsi: a4000t: Convert to platform remove callback returning void
scsi: atari: Convert to platform remove callback returning void
scsi: bvme6000: Convert to platform remove callback returning void
scsi: jazz_esp: Convert to platform remove callback returning void
scsi: mac_esp: Convert to platform remove callback returning void
scsi: mac: Convert to platform remove callback returning void
scsi: mvme16x: Convert to platform remove callback returning void
scsi: qlogicpti: Convert to platform remove callback returning void
scsi: sgiwd93: Convert to platform remove callback returning void
scsi: sni_53c710: Convert to platform remove callback returning void
scsi: sun3: Convert to platform remove callback returning void
scsi: sun3x_esp: Convert to platform remove callback returning void
scsi: sun_esp: Convert to platform remove callback returning void
drivers/scsi/a3000.c | 5 ++--- drivers/scsi/a4000t.c | 5 ++--- drivers/scsi/atari_scsi.c | 5 ++--- drivers/scsi/bvme6000_scsi.c | 6 ++---- drivers/scsi/jazz_esp.c | 6 ++---- drivers/scsi/mac_esp.c | 6 ++---- drivers/scsi/mac_scsi.c | 5 ++--- drivers/scsi/mvme16x_scsi.c | 6 ++---- drivers/scsi/qlogicpti.c | 6 ++---- drivers/scsi/sgiwd93.c | 5 ++--- drivers/scsi/sni_53c710.c | 6 ++---- drivers/scsi/sun3_scsi.c | 5 ++--- drivers/scsi/sun3x_esp.c | 6 ++---- drivers/scsi/sun_esp.c | 6 ++---- 14 files changed, 28 insertions(+), 50 deletions(-)
base-commit: 5eda217cee887e595ba2265435862d585d399769
Signature · 1 line
2.42.0
PATCH 1/14 scsi: a3000: Convert to platform remove callback returning void
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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/a3000.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/scsi/a3000.c +2 -3
@@ -282,7 +282,7 @@ static int __init amiga_a3000_scsi_probe(struct platform_device *pdev)return error; } -static int __exit amiga_a3000_scsi_remove(struct platform_device *pdev) +static void __exit amiga_a3000_scsi_remove(struct platform_device *pdev) {struct Scsi_Host *instance =platform_get_drvdata (pdev);struct a3000_hostdata *hdata =shost_priv (instance);
@@ -293,11 +293,10 @@ static int __exit amiga_a3000_scsi_remove(struct platform_device *pdev)free_irq (IRQ_AMIGA_PORTS , instance);scsi_host_put (instance);release_mem_region (res->start,resource_size (res)); -return 0 ; }static struct platform_driver amiga_a3000_scsi_driver = { - .remove =__exit_p (amiga_a3000_scsi_remove), + .remove_new =__exit_p (amiga_a3000_scsi_remove), .driver = { .name ="amiga-a3000-scsi" , },
Signature · 1 line
2.42.0
PATCH 2/14 scsi: a4000t: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/a4000t.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/scsi/a4000t.c +2 -3
@@ -95,7 +95,7 @@ static int __init amiga_a4000t_scsi_probe(struct platform_device *pdev)return -ENODEV ; } -static int __exit amiga_a4000t_scsi_remove(struct platform_device *pdev) +static void __exit amiga_a4000t_scsi_remove(struct platform_device *pdev) {struct Scsi_Host *host =platform_get_drvdata (pdev);struct NCR_700_Host_Parameters *hostdata =shost_priv (host);
@@ -106,11 +106,10 @@ static int __exit amiga_a4000t_scsi_remove(struct platform_device *pdev)kfree (hostdata);free_irq (host->irq, host);release_mem_region (res->start,resource_size (res)); -return 0 ; }static struct platform_driver amiga_a4000t_scsi_driver = { - .remove =__exit_p (amiga_a4000t_scsi_remove), + .remove_new =__exit_p (amiga_a4000t_scsi_remove), .driver = { .name ="amiga-a4000t-scsi" , },
Signature · 1 line
2.42.0
PATCH 3/14 scsi: atari: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/atari_scsi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/scsi/atari_scsi.c +2 -3
@@ -865,7 +865,7 @@ static int __init atari_scsi_probe(struct platform_device *pdev)return error; } -static int __exit atari_scsi_remove(struct platform_device *pdev) +static void __exit atari_scsi_remove(struct platform_device *pdev) {struct Scsi_Host *instance =platform_get_drvdata (pdev);
@@ -876,11 +876,10 @@ static int __exit atari_scsi_remove(struct platform_device *pdev)scsi_host_put (instance);if (atari_dma_buffer)atari_stram_free (atari_dma_buffer); -return 0 ; }static struct platform_driver atari_scsi_driver = { - .remove =__exit_p (atari_scsi_remove), + .remove_new =__exit_p (atari_scsi_remove), .driver = { .name =DRV_MODULE_NAME , },
Signature · 1 line
2.42.0
PATCH 4/14 scsi: bvme6000: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/bvme6000_scsi.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/scsi/bvme6000_scsi.c +2 -4
@@ -89,7 +89,7 @@ bvme6000_probe(struct platform_device *dev)return -ENODEV ; } -static int +static void bvme6000_device_remove (struct platform_device *dev) {struct Scsi_Host *host =platform_get_drvdata (dev);
@@ -99,8 +99,6 @@ bvme6000_device_remove(struct platform_device *dev)NCR_700_release (host);kfree (hostdata);free_irq (host->irq, host); - -return 0 ; }static struct platform_driver bvme6000_scsi_driver = {
@@ -108,7 +106,7 @@ static struct platform_driver bvme6000_scsi_driver = { .name = "bvme6000-scsi", }, .probe = bvme6000_probe, - .remove = bvme6000_device_remove, + .remove_new = bvme6000_device_remove, };static int __init bvme6000_scsi_init (void )
Signature · 1 line
2.42.0
PATCH 5/14 scsi: jazz_esp: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/jazz_esp.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/scsi/jazz_esp.c +2 -4
@@ -176,7 +176,7 @@ static int esp_jazz_probe(struct platform_device *dev)return err; } -static int esp_jazz_remove (struct platform_device *dev) +static void esp_jazz_remove (struct platform_device *dev) {struct esp *esp =dev_get_drvdata (&dev->dev);unsigned int irq = esp->host->irq;
@@ -189,8 +189,6 @@ static int esp_jazz_remove(struct platform_device *dev) esp->command_block_dma);scsi_host_put (esp->host); - -return 0 ; }/* work with hotplug and coldplug */
@@ -198,7 +196,7 @@ MODULE_ALIAS("platform:jazz_esp");static struct platform_driver esp_jazz_driver = { .probe = esp_jazz_probe, - .remove = esp_jazz_remove, + .remove_new = esp_jazz_remove, .driver = { .name ="jazz_esp" , },
Signature · 1 line
2.42.0
PATCH 6/14 scsi: mac_esp: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/mac_esp.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/scsi/mac_esp.c +2 -4
@@ -407,7 +407,7 @@ static int esp_mac_probe(struct platform_device *dev)return err; } -static int esp_mac_remove (struct platform_device *dev) +static void esp_mac_remove (struct platform_device *dev) {struct mac_esp_priv *mep =platform_get_drvdata (dev);struct esp *esp = mep->esp;
@@ -428,13 +428,11 @@ static int esp_mac_remove(struct platform_device *dev)kfree (esp->command_block);scsi_host_put (esp->host); - -return 0 ; }static struct platform_driver esp_mac_driver = { .probe = esp_mac_probe, - .remove = esp_mac_remove, + .remove_new = esp_mac_remove, .driver = { .name =DRV_MODULE_NAME , },
Signature · 1 line
2.42.0
PATCH 7/14 scsi: mac: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/mac_scsi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/scsi/mac_scsi.c +2 -3
@@ -523,7 +523,7 @@ static int __init mac_scsi_probe(struct platform_device *pdev)return error; } -static int __exit mac_scsi_remove(struct platform_device *pdev) +static void __exit mac_scsi_remove(struct platform_device *pdev) {struct Scsi_Host *instance =platform_get_drvdata (pdev);
@@ -532,11 +532,10 @@ static int __exit mac_scsi_remove(struct platform_device *pdev)free_irq (instance->irq, instance);NCR5380_exit (instance);scsi_host_put (instance); -return 0 ; }static struct platform_driver mac_scsi_driver = { - .remove =__exit_p (mac_scsi_remove), + .remove_new =__exit_p (mac_scsi_remove), .driver = { .name =DRV_MODULE_NAME , },
Signature · 1 line
2.42.0
PATCH 8/14 scsi: mvme16x: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/mvme16x_scsi.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/scsi/mvme16x_scsi.c +2 -4
@@ -103,7 +103,7 @@ static int mvme16x_probe(struct platform_device *dev)return -ENODEV ; } -static int mvme16x_device_remove (struct platform_device *dev) +static void mvme16x_device_remove (struct platform_device *dev) {struct Scsi_Host *host =platform_get_drvdata (dev);struct NCR_700_Host_Parameters *hostdata =shost_priv (host);
@@ -120,8 +120,6 @@ static int mvme16x_device_remove(struct platform_device *dev)NCR_700_release (host);kfree (hostdata);free_irq (host->irq, host); - -return 0 ; }static struct platform_driver mvme16x_scsi_driver = {
@@ -129,7 +127,7 @@ static struct platform_driver mvme16x_scsi_driver = { .name = "mvme16x-scsi", }, .probe = mvme16x_probe, - .remove = mvme16x_device_remove, + .remove_new = mvme16x_device_remove, };static int __init mvme16x_scsi_init (void )
Signature · 1 line
2.42.0
PATCH 9/14 scsi: qlogicpti: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/qlogicpti.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/scsi/qlogicpti.c +2 -4
@@ -1409,7 +1409,7 @@ static int qpti_sbus_probe(struct platform_device *op)return -ENODEV ; } -static int qpti_sbus_remove (struct platform_device *op) +static void qpti_sbus_remove (struct platform_device *op) {struct qlogicpti *qpti =dev_get_drvdata (&op->dev);
@@ -1438,8 +1438,6 @@ static int qpti_sbus_remove(struct platform_device *op)of_iounmap (&op->resource[0 ], qpti->sreg,sizeof (unsigned char ));scsi_host_put (qpti->qhost); - -return 0 ; }static const struct of_device_id qpti_match[] = {
@@ -1465,7 +1463,7 @@ static struct platform_driver qpti_sbus_driver = { .of_match_table = qpti_match, }, .probe = qpti_sbus_probe, - .remove = qpti_sbus_remove, + .remove_new = qpti_sbus_remove, };module_platform_driver (qpti_sbus_driver);
Signature · 1 line
2.42.0
PATCH 10/14 scsi: sgiwd93: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/sgiwd93.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/scsi/sgiwd93.c +2 -3
@@ -291,7 +291,7 @@ static int sgiwd93_probe(struct platform_device *pdev)return err; } -static int sgiwd93_remove (struct platform_device *pdev) +static void sgiwd93_remove (struct platform_device *pdev) {struct Scsi_Host *host =platform_get_drvdata (pdev);struct ip22_hostdata *hdata = (struct ip22_hostdata *) host->hostdata;
@@ -302,12 +302,11 @@ static int sgiwd93_remove(struct platform_device *pdev)dma_free_noncoherent (&pdev->dev,HPC_DMA_SIZE , hdata->cpu, hdata->dma,DMA_TO_DEVICE );scsi_host_put (host); -return 0 ; }static struct platform_driver sgiwd93_driver = { .probe = sgiwd93_probe, - .remove = sgiwd93_remove, + .remove_new = sgiwd93_remove, .driver = { .name ="sgiwd93" , }
Signature · 1 line
2.42.0
PATCH 11/14 scsi: sni_53c710: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/sni_53c710.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/scsi/sni_53c710.c +2 -4
@@ -104,7 +104,7 @@ static int snirm710_probe(struct platform_device *dev)return -ENODEV ; } -static int snirm710_driver_remove (struct platform_device *dev) +static void snirm710_driver_remove (struct platform_device *dev) {struct Scsi_Host *host =dev_get_drvdata (&dev->dev); struct NCR_700_Host_Parameters *hostdata =
@@ -115,13 +115,11 @@ static int snirm710_driver_remove(struct platform_device *dev)free_irq (host->irq, host);iounmap (hostdata->base);kfree (hostdata); - -return 0 ; }static struct platform_driver snirm710_driver = { .probe = snirm710_probe, - .remove = snirm710_driver_remove, + .remove_new = snirm710_driver_remove, .driver = { .name ="snirm_53c710" , },
Signature · 1 line
2.42.0
PATCH 12/14 scsi: sun3: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/sun3_scsi.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
drivers/scsi/sun3_scsi.c +2 -3
@@ -641,7 +641,7 @@ static int __init sun3_scsi_probe(struct platform_device *pdev)return error; } -static int __exit sun3_scsi_remove(struct platform_device *pdev) +static void __exit sun3_scsi_remove(struct platform_device *pdev) {struct Scsi_Host *instance =platform_get_drvdata (pdev);struct NCR5380_hostdata *hostdata =shost_priv (instance);
@@ -654,11 +654,10 @@ static int __exit sun3_scsi_remove(struct platform_device *pdev)if (udc_regs)dvma_free (udc_regs);iounmap (ioaddr); -return 0 ; }static struct platform_driver sun3_scsi_driver = { - .remove =__exit_p (sun3_scsi_remove), + .remove_new =__exit_p (sun3_scsi_remove), .driver = { .name =DRV_MODULE_NAME , },
Signature · 1 line
2.42.0
PATCH 13/14 scsi: sun3x_esp: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/sun3x_esp.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/scsi/sun3x_esp.c +2 -4
@@ -243,7 +243,7 @@ static int esp_sun3x_probe(struct platform_device *dev)return err; } -static int esp_sun3x_remove (struct platform_device *dev) +static void esp_sun3x_remove (struct platform_device *dev) {struct esp *esp =dev_get_drvdata (&dev->dev);unsigned int irq = esp->host->irq;
@@ -261,13 +261,11 @@ static int esp_sun3x_remove(struct platform_device *dev) esp->command_block_dma);scsi_host_put (esp->host); - -return 0 ; }static struct platform_driver esp_sun3x_driver = { .probe = esp_sun3x_probe, - .remove = esp_sun3x_remove, + .remove_new = esp_sun3x_remove, .driver = { .name ="sun3x_esp" , },
Signature · 1 line
2.42.0
PATCH 14/14 scsi: sun_esp: Convert to platform remove callback returning void
In reply to Uwe Kleine-KönigThe .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 ignored (apart from emitting a warning) 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. Eventually after all drivers are converted, .remove_new() will be renamed to .remove().
In the error path emit an error message replacing the (less useful) message by the core. Apart from the improved error message there is no change in behaviour.
Trivially convert this driver from always returning zero in the remove callback to the void returning variant.
--- drivers/scsi/sun_esp.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
drivers/scsi/sun_esp.c +2 -4
@@ -550,7 +550,7 @@ static int esp_sbus_probe(struct platform_device *op)return ret; } -static int esp_sbus_remove (struct platform_device *op) +static void esp_sbus_remove (struct platform_device *op) {struct esp *esp =dev_get_drvdata (&op->dev);struct platform_device *dma_of = esp->dma;
@@ -581,8 +581,6 @@ static int esp_sbus_remove(struct platform_device *op)dev_set_drvdata (&op->dev,NULL );put_device (&dma_of->dev); - -return 0 ; }static const struct of_device_id esp_match[] = {
@@ -605,7 +603,7 @@ static struct platform_driver esp_sbus_driver = { .of_match_table = esp_match, }, .probe = esp_sbus_probe, - .remove = esp_sbus_remove, + .remove_new = esp_sbus_remove, };module_platform_driver (esp_sbus_driver);
Signature · 1 line
2.42.0
Martin K. Petersen
AppliedUwe,
Quoted 7 lines
this series converts all drivers below
drivers/scsito structplatform_driver::remove_new(). See commit5c5a7680e67b("platform:
Provide a remove callback that returns no value") for an extended explanation and the eventual goal.All conversations are trivial, because all .remove() callbacks returned zero unconditionally.
Applied to 6.8/scsi-staging, thanks!
Signature · 1 line
Martin K. Petersen Oracle Linux Engineering
Martin K. Petersen
AppliedQuoted 9 lines · Uwe Kleine-König
this series converts all drivers below
drivers/scsito structplatform_driver::remove_new(). See commit5c5a7680e67b("platform:
Provide a remove callback that returns no value") for an extended explanation and the eventual goal.All conversations are trivial, because all .remove() callbacks returned zero unconditionally.
[...]
Applied to 6.8/scsi-queue, thanks!
[01/14] scsi: a3000: Convert to platform remove callback returning void
https://git.kernel.org/mkp/scsi/c/5854cdd04163 [02/14] scsi: a4000t: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/688bbe398ca6 [03/14] scsi: atari: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/3becb4cdf1c1 [04/14] scsi: bvme6000: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/51a41ec6d36e [05/14] scsi: jazz_esp: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/c71ef3d1fb39 [06/14] scsi: mac_esp: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/0b649224f712 [07/14] scsi: mac: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/69b43bf38b11 [08/14] scsi: mvme16x: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/f0baf76a2204 [09/14] scsi: qlogicpti: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/e26eec9a4d25 [10/14] scsi: sgiwd93: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/358987af1bda [11/14] scsi: sni_53c710: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/357a7fd2434e [12/14] scsi: sun3: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/15b016b2d023 [13/14] scsi: sun3x_esp: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/e84bd0bb3068 [14/14] scsi: sun_esp: Convert to platform remove callback returning void https://git.kernel.org/mkp/scsi/c/6ff482eeebe5
Signature · 1 line
Martin K. Petersen Oracle Linux Engineering