Merge patch series "scsi: Convert to platform remove callback returning" void
Uwe Kleine-König <u.kleine-koenig@pengutronix.de> says: 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 Link: https://lore.kernel.org/r/cover.1701619134.git.u.kleine-koenig@pengutronix.de Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:
commit
e78e59acfb
@ -282,7 +282,7 @@ fail_alloc:
|
||||
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",
|
||||
},
|
||||
|
@ -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",
|
||||
},
|
||||
|
@ -865,7 +865,7 @@ fail_alloc:
|
||||
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,
|
||||
},
|
||||
|
@ -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)
|
||||
|
@ -176,7 +176,7 @@ fail:
|
||||
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",
|
||||
},
|
||||
|
@ -407,7 +407,7 @@ fail:
|
||||
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,
|
||||
},
|
||||
|
@ -523,7 +523,7 @@ fail_init:
|
||||
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,
|
||||
},
|
||||
|
@ -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)
|
||||
|
@ -1409,7 +1409,7 @@ fail_unlink:
|
||||
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);
|
||||
|
||||
|
@ -291,7 +291,7 @@ out:
|
||||
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",
|
||||
}
|
||||
|
@ -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",
|
||||
},
|
||||
|
@ -641,7 +641,7 @@ fail_alloc:
|
||||
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,
|
||||
},
|
||||
|
@ -243,7 +243,7 @@ fail:
|
||||
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",
|
||||
},
|
||||
|
@ -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);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user