diff options
author | Len Brown <len.brown@intel.com> | 2009-04-05 10:14:15 +0400 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2009-04-05 10:14:15 +0400 |
commit | 478c6a43fcbc6c11609f8cee7c7b57223907754f (patch) | |
tree | a7f7952099da60d33032aed6de9c0c56c9f8779e /drivers/scsi/mvme16x_scsi.c | |
parent | 8a3f257c704e02aee9869decd069a806b45be3f1 (diff) | |
parent | 6bb597507f9839b13498781e481f5458aea33620 (diff) | |
download | linux-478c6a43fcbc6c11609f8cee7c7b57223907754f.tar.xz |
Merge branch 'linus' into release
Conflicts:
arch/x86/kernel/cpu/cpufreq/longhaul.c
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/scsi/mvme16x_scsi.c')
-rw-r--r-- | drivers/scsi/mvme16x_scsi.c | 29 |
1 files changed, 16 insertions, 13 deletions
diff --git a/drivers/scsi/mvme16x_scsi.c b/drivers/scsi/mvme16x_scsi.c index b264b499d982..b5fbfd6ce870 100644 --- a/drivers/scsi/mvme16x_scsi.c +++ b/drivers/scsi/mvme16x_scsi.c @@ -34,7 +34,7 @@ static struct scsi_host_template mvme16x_scsi_driver_template = { static struct platform_device *mvme16x_scsi_device; static __devinit int -mvme16x_probe(struct device *dev) +mvme16x_probe(struct platform_device *dev) { struct Scsi_Host * host = NULL; struct NCR_700_Host_Parameters *hostdata; @@ -64,7 +64,8 @@ mvme16x_probe(struct device *dev) hostdata->ctest7_extra = CTEST7_TT1; /* and register the chip */ - host = NCR_700_detect(&mvme16x_scsi_driver_template, hostdata, dev); + host = NCR_700_detect(&mvme16x_scsi_driver_template, hostdata, + &dev->dev); if (!host) { printk(KERN_ERR "mvme16x-scsi: No host detected; " "board configuration problem?\n"); @@ -88,7 +89,7 @@ mvme16x_probe(struct device *dev) out_be32(0xfff4202c, v); } - dev_set_drvdata(dev, host); + platform_set_drvdata(dev, host); scsi_scan_host(host); return 0; @@ -102,9 +103,9 @@ mvme16x_probe(struct device *dev) } static __devexit int -mvme16x_device_remove(struct device *dev) +mvme16x_device_remove(struct platform_device *dev) { - struct Scsi_Host *host = dev_get_drvdata(dev); + struct Scsi_Host *host = platform_get_drvdata(dev); struct NCR_700_Host_Parameters *hostdata = shost_priv(host); /* Disable scsi chip ints */ @@ -123,25 +124,27 @@ mvme16x_device_remove(struct device *dev) return 0; } -static struct device_driver mvme16x_scsi_driver = { - .name = "mvme16x-scsi", - .bus = &platform_bus_type, - .probe = mvme16x_probe, - .remove = __devexit_p(mvme16x_device_remove), +static struct platform_driver mvme16x_scsi_driver = { + .driver = { + .name = "mvme16x-scsi", + .owner = THIS_MODULE, + }, + .probe = mvme16x_probe, + .remove = __devexit_p(mvme16x_device_remove), }; static int __init mvme16x_scsi_init(void) { int err; - err = driver_register(&mvme16x_scsi_driver); + err = platform_driver_register(&mvme16x_scsi_driver); if (err) return err; mvme16x_scsi_device = platform_device_register_simple("mvme16x-scsi", -1, NULL, 0); if (IS_ERR(mvme16x_scsi_device)) { - driver_unregister(&mvme16x_scsi_driver); + platform_driver_unregister(&mvme16x_scsi_driver); return PTR_ERR(mvme16x_scsi_device); } @@ -151,7 +154,7 @@ static int __init mvme16x_scsi_init(void) static void __exit mvme16x_scsi_exit(void) { platform_device_unregister(mvme16x_scsi_device); - driver_unregister(&mvme16x_scsi_driver); + platform_driver_unregister(&mvme16x_scsi_driver); } module_init(mvme16x_scsi_init); |