ata: use CONFIG_PM_SLEEP instead of CONFIG_PM where applicable in host drivers
authorBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Wed, 7 May 2014 15:17:44 +0000 (17:17 +0200)
committerTejun Heo <tj@kernel.org>
Sat, 10 May 2014 02:37:49 +0000 (22:37 -0400)
This patch fixes host drivers to use CONFIG_PM_SLEEP instead of CONFIG_PM
where applicable.  Benefits of this change:

* unused code is not being compiled in for CONFIG_PM=y, CONFIG_PM_SLEEP=n
  and CONFIG_PM_RUNTIME=y configurations

* easier transition to use struct dev_pm_ops and SIMPLE_DEV_PM_OPS() in
  the future

* more consistent code (there are host drivers which are using the correct
  CONFIG_PM_SLEEP checks already)

The patch leaves the core libata code and ->port_[suspend,resume] support
in sata_[inic162x,nv,sil24].c alone for now.

Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Signed-off-by: Tejun Heo <tj@kernel.org>
60 files changed:
drivers/ata/acard-ahci.c
drivers/ata/ata_generic.c
drivers/ata/ata_piix.c
drivers/ata/pata_acpi.c
drivers/ata/pata_ali.c
drivers/ata/pata_amd.c
drivers/ata/pata_artop.c
drivers/ata/pata_atiixp.c
drivers/ata/pata_atp867x.c
drivers/ata/pata_bf54x.c
drivers/ata/pata_cmd640.c
drivers/ata/pata_cmd64x.c
drivers/ata/pata_cs5520.c
drivers/ata/pata_cs5530.c
drivers/ata/pata_cs5535.c
drivers/ata/pata_cs5536.c
drivers/ata/pata_cypress.c
drivers/ata/pata_efar.c
drivers/ata/pata_hpt366.c
drivers/ata/pata_hpt3x3.c
drivers/ata/pata_imx.c
drivers/ata/pata_it8213.c
drivers/ata/pata_it821x.c
drivers/ata/pata_jmicron.c
drivers/ata/pata_macio.c
drivers/ata/pata_marvell.c
drivers/ata/pata_mpc52xx.c
drivers/ata/pata_mpiix.c
drivers/ata/pata_netcell.c
drivers/ata/pata_ninja32.c
drivers/ata/pata_ns87410.c
drivers/ata/pata_ns87415.c
drivers/ata/pata_oldpiix.c
drivers/ata/pata_opti.c
drivers/ata/pata_optidma.c
drivers/ata/pata_pdc2027x.c
drivers/ata/pata_pdc202xx_old.c
drivers/ata/pata_piccolo.c
drivers/ata/pata_radisys.c
drivers/ata/pata_rdc.c
drivers/ata/pata_rz1000.c
drivers/ata/pata_samsung_cf.c
drivers/ata/pata_sc1200.c
drivers/ata/pata_scc.c
drivers/ata/pata_sch.c
drivers/ata/pata_serverworks.c
drivers/ata/pata_sil680.c
drivers/ata/pata_sis.c
drivers/ata/pata_sl82c105.c
drivers/ata/pata_triflex.c
drivers/ata/pata_via.c
drivers/ata/sata_fsl.c
drivers/ata/sata_inic162x.c
drivers/ata/sata_mv.c
drivers/ata/sata_nv.c
drivers/ata/sata_rcar.c
drivers/ata/sata_sil.c
drivers/ata/sata_sil24.c
drivers/ata/sata_sis.c
drivers/ata/sata_via.c

index b51605ac597418f7aa352789dc9aeeb1b8ca015b..0cd7c7a39e5bf3571b2fc1ab145d8c2b2c3dab17 100644 (file)
@@ -77,7 +77,7 @@ static bool acard_ahci_qc_fill_rtf(struct ata_queued_cmd *qc);
 static int acard_ahci_port_start(struct ata_port *ap);
 static int acard_ahci_init_one(struct pci_dev *pdev, const struct pci_device_id *ent);
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int acard_ahci_pci_device_suspend(struct pci_dev *pdev, pm_message_t mesg);
 static int acard_ahci_pci_device_resume(struct pci_dev *pdev);
 #endif
@@ -118,13 +118,13 @@ static struct pci_driver acard_ahci_pci_driver = {
        .id_table               = acard_ahci_pci_tbl,
        .probe                  = acard_ahci_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = acard_ahci_pci_device_suspend,
        .resume                 = acard_ahci_pci_device_resume,
 #endif
 };
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int acard_ahci_pci_device_suspend(struct pci_dev *pdev, pm_message_t mesg)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
index 9498a7d3846fef6e2c88bdd8596d3f2080e0349e..9ff545ce8da3e922cd8770f464eb7b8b6311a36e 100644 (file)
@@ -241,7 +241,7 @@ static struct pci_driver ata_generic_pci_driver = {
        .id_table       = ata_generic,
        .probe          = ata_generic_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index 6334c8d7c3f1e6a437b90af78e585e50698f5fc8..893e30e9a9efab5662d5361e83051f9ac1c650c0 100644 (file)
@@ -830,7 +830,7 @@ static bool piix_irq_check(struct ata_port *ap)
        return ap->ops->bmdma_status(ap) & ATA_DMA_INTR;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int piix_broken_suspend(void)
 {
        static const struct dmi_system_id sysids[] = {
@@ -1767,7 +1767,7 @@ static struct pci_driver piix_pci_driver = {
        .id_table               = piix_pci_tbl,
        .probe                  = piix_init_one,
        .remove                 = piix_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = piix_pci_device_suspend,
        .resume                 = piix_pci_device_resume,
 #endif
index 5108b8744dce4c70d37d913fbf5b916984b36f6c..b70fce2a38eb6079ca8a25e86d0f1219df726d0c 100644 (file)
@@ -265,7 +265,7 @@ static struct pci_driver pacpi_pci_driver = {
        .id_table               = pacpi_pci_tbl,
        .probe                  = pacpi_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index 1b7b2ccabcff2e906fe603eb3c96cea136b70c9b..d19cd88ed2d3749313dbc36f6c99c113df8cd766 100644 (file)
@@ -589,7 +589,7 @@ static int ali_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
                return ata_pci_bmdma_init_one(pdev, ppi, &ali_sht, NULL, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int ali_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -616,7 +616,7 @@ static struct pci_driver ali_pci_driver = {
        .id_table       = ali,
        .probe          = ali_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ali_reinit_one,
 #endif
index 1206fa6b62cae199a00302729565915ed931509a..8d4d959a821cab1a356dfde38226caf69ab5129f 100644 (file)
@@ -574,7 +574,7 @@ static int amd_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
        return ata_pci_bmdma_init_one(pdev, ppi, &amd_sht, hpriv, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int amd_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -625,7 +625,7 @@ static struct pci_driver amd_pci_driver = {
        .id_table       = amd,
        .probe          = amd_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = amd_reinit_one,
 #endif
index 3aa4e655e3c64cb5a81f3759f5638e2eb003c5df..96c05c9494fa0ca6be4b7c96ee985761cc0d56b9 100644 (file)
@@ -422,7 +422,7 @@ static const struct pci_device_id artop_pci_tbl[] = {
        { }     /* terminate list */
 };
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int atp8xx_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -444,7 +444,7 @@ static struct pci_driver artop_pci_driver = {
        .id_table               = artop_pci_tbl,
        .probe                  = artop_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = atp8xx_reinit_one,
 #endif
index 30fa4ca4cef65607493a1e8fd1e5fe6bf13b5bbb..970f7767e5fdd7efc8caa1f1ed68836401d4cef5 100644 (file)
@@ -298,7 +298,7 @@ static struct pci_driver atiixp_pci_driver = {
        .id_table       = atiixp,
        .probe          = atiixp_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .resume         = ata_pci_device_resume,
        .suspend        = ata_pci_device_suspend,
 #endif
index 7e73a0f1e3237698b2b7afcd70207655e53dc2d3..a705cfca90f7210806f7d61e4897aaec738a0f8f 100644 (file)
@@ -530,7 +530,7 @@ err_out:
        return rc;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int atp867x_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -558,7 +558,7 @@ static struct pci_driver atp867x_driver = {
        .id_table       = atp867x_pci_tbl,
        .probe          = atp867x_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = atp867x_reinit_one,
 #endif
index ba0d8a29dc235ab33de62e5e9eb233afcba47a83..03f2f2bc83bdc19384e2d508cdcb5aecedee08de 100644 (file)
@@ -1619,7 +1619,7 @@ static int bfin_atapi_remove(struct platform_device *pdev)
        return 0;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int bfin_atapi_suspend(struct platform_device *pdev, pm_message_t state)
 {
        struct ata_host *host = platform_get_drvdata(pdev);
index 57f1be64dbf239e8c631687ea5b5c28f1c1b5577..c47caa807fa933d370e91720ca99df253216c803 100644 (file)
@@ -231,7 +231,7 @@ static int cmd640_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
        return ata_pci_sff_init_one(pdev, ppi, &cmd640_sht, NULL, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int cmd640_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -256,7 +256,7 @@ static struct pci_driver cmd640_pci_driver = {
        .id_table       = cmd640,
        .probe          = cmd640_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = cmd640_reinit_one,
 #endif
index 6bca3505b9e9d5431d537e2fdf2fbcae917e76c6..13ca5883285b6705b33d1ef9622821dbce8a93f7 100644 (file)
@@ -487,7 +487,7 @@ static int cmd64x_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
        return ata_pci_bmdma_init_one(pdev, ppi, &cmd64x_sht, NULL, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int cmd64x_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -518,7 +518,7 @@ static struct pci_driver cmd64x_pci_driver = {
        .id_table       = cmd64x,
        .probe          = cmd64x_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = cmd64x_reinit_one,
 #endif
index bcde4b786807079126aed18744edbbf972a86d3c..d65cb9d2fa8c1966dc8c33c1a535a580b7bea3d2 100644 (file)
@@ -229,7 +229,7 @@ static int cs5520_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
        return ata_host_register(host, &cs5520_sht);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 /**
  *     cs5520_reinit_one       -       device resume
  *     @pdev: PCI device
@@ -278,7 +278,7 @@ static int cs5520_pci_device_suspend(struct pci_dev *pdev, pm_message_t mesg)
        pci_save_state(pdev);
        return 0;
 }
-#endif /* CONFIG_PM */
+#endif /* CONFIG_PM_SLEEP */
 
 /* For now keep DMA off. We can set it for all but A rev CS5510 once the
    core ATA code can handle it */
@@ -295,7 +295,7 @@ static struct pci_driver cs5520_pci_driver = {
        .id_table       = pata_cs5520,
        .probe          = cs5520_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = cs5520_pci_device_suspend,
        .resume         = cs5520_reinit_one,
 #endif
index 8afe854a5a50c24abeb2c9f96966264d09c0f8bc..48ae4b43447450e221a8f016418f087df0f2d421 100644 (file)
@@ -326,7 +326,7 @@ static int cs5530_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
        return ata_pci_bmdma_init_one(pdev, ppi, &cs5530_sht, NULL, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int cs5530_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -343,7 +343,7 @@ static int cs5530_reinit_one(struct pci_dev *pdev)
        ata_host_resume(host);
        return 0;
 }
-#endif /* CONFIG_PM */
+#endif /* CONFIG_PM_SLEEP */
 
 static const struct pci_device_id cs5530[] = {
        { PCI_VDEVICE(CYRIX, PCI_DEVICE_ID_CYRIX_5530_IDE), },
@@ -356,7 +356,7 @@ static struct pci_driver cs5530_pci_driver = {
        .id_table       = cs5530,
        .probe          = cs5530_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = cs5530_reinit_one,
 #endif
index 2c0986fa4bb2ccd8efc1d2ead606c05e6d734ae1..97584e8456d9a8f91b279e358392dd55490650b9 100644 (file)
@@ -200,7 +200,7 @@ static struct pci_driver cs5535_pci_driver = {
        .id_table       = cs5535,
        .probe          = cs5535_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index 32ddcae5a360a387b010db88cf951287ab219bd6..6c15a554efbe1945f79a12aa7588c25cd10be024 100644 (file)
@@ -297,7 +297,7 @@ static struct pci_driver cs5536_pci_driver = {
        .id_table       = cs5536,
        .probe          = cs5536_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index 3435bd6a5cc918984ba7aee85cfc8e4435e7106c..793018460d8200b74da64f6b84f052ed07ddb325 100644 (file)
@@ -151,7 +151,7 @@ static struct pci_driver cy82c693_pci_driver = {
        .id_table       = cy82c693,
        .probe          = cy82c693_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index f440892225f4d220603759f196cd2b5ca155a87f..4a57a6f032d9af262d01da9ba0421fe412d33a5e 100644 (file)
@@ -288,7 +288,7 @@ static struct pci_driver efar_pci_driver = {
        .id_table               = efar_pci_tbl,
        .probe                  = efar_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index 8e76f79689d371bd96fbd2f276d53ab265edc026..cbc3de793d1d61a494cb82fe76e6a16ebfb8ab5b 100644 (file)
@@ -386,7 +386,7 @@ static int hpt36x_init_one(struct pci_dev *dev, const struct pci_device_id *id)
        return ata_pci_bmdma_init_one(dev, ppi, &hpt36x_sht, hpriv, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int hpt36x_reinit_one(struct pci_dev *dev)
 {
        struct ata_host *host = pci_get_drvdata(dev);
@@ -411,7 +411,7 @@ static struct pci_driver hpt36x_pci_driver = {
        .id_table       = hpt36x,
        .probe          = hpt36x_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = hpt36x_reinit_one,
 #endif
index 255c5aaff3a81e8c3ddce32dca7ba49a6dd0cf1d..d019cdd5bc9f3deb0e1f6a70000c0fb9b7c89090 100644 (file)
@@ -249,7 +249,7 @@ static int hpt3x3_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
                                 IRQF_SHARED, &hpt3x3_sht);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int hpt3x3_reinit_one(struct pci_dev *dev)
 {
        struct ata_host *host = pci_get_drvdata(dev);
@@ -277,7 +277,7 @@ static struct pci_driver hpt3x3_pci_driver = {
        .id_table       = hpt3x3,
        .probe          = hpt3x3_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = hpt3x3_reinit_one,
 #endif
index e0872db913d65d1f120a753ac2f313162add41dd..af424573c2ff1700777415f1c95c1b43582d2a2b 100644 (file)
@@ -185,7 +185,7 @@ static int pata_imx_remove(struct platform_device *pdev)
        return 0;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int pata_imx_suspend(struct device *dev)
 {
        struct ata_host *host = dev_get_drvdata(dev);
@@ -244,7 +244,7 @@ static struct platform_driver pata_imx_driver = {
                .name           = DRV_NAME,
                .of_match_table = imx_pata_dt_ids,
                .owner          = THIS_MODULE,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
                .pm             = &pata_imx_pm_ops,
 #endif
        },
index 81369d187a5cb8f9e8e7d40158741533486d19a5..4f97d1e52f85721230a752d7a6a2bc4a218e3839 100644 (file)
@@ -283,7 +283,7 @@ static struct pci_driver it8213_pci_driver = {
        .id_table               = it8213_pci_tbl,
        .probe                  = it8213_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index dc3d7877f29d7898a11780595e27cabb01d53a7e..a5088ecb349f963dee15c89a607e62561558b2d3 100644 (file)
@@ -935,7 +935,7 @@ static int it821x_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
        return ata_pci_bmdma_init_one(pdev, ppi, &it821x_sht, NULL, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int it821x_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -965,7 +965,7 @@ static struct pci_driver it821x_pci_driver = {
        .id_table       = it821x,
        .probe          = it821x_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = it821x_reinit_one,
 #endif
index b1cfa0258fd38017337e345b5095677a50567133..4d1a5d2c4287f2979c34a2913c0cb4018f573776 100644 (file)
@@ -157,7 +157,7 @@ static struct pci_driver jmicron_pci_driver = {
        .id_table               = jmicron_pci_tbl,
        .probe                  = jmicron_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index c28d0645e8514c1cb8785bf30529e90c6f0b81a4..a02f76fdcfcd37df9062880424a68d94d9970bc1 100644 (file)
@@ -845,8 +845,7 @@ static int pata_macio_slave_config(struct scsi_device *sdev)
        return 0;
 }
 
-#ifdef CONFIG_PM
-
+#ifdef CONFIG_PM_SLEEP
 static int pata_macio_do_suspend(struct pata_macio_priv *priv, pm_message_t mesg)
 {
        int rc;
@@ -907,8 +906,7 @@ static int pata_macio_do_resume(struct pata_macio_priv *priv)
 
        return 0;
 }
-
-#endif /* CONFIG_PM */
+#endif /* CONFIG_PM_SLEEP */
 
 static struct scsi_host_template pata_macio_sht = {
        ATA_BASE_SHT(DRV_NAME),
@@ -1208,8 +1206,7 @@ static int pata_macio_detach(struct macio_dev *mdev)
        return 0;
 }
 
-#ifdef CONFIG_PM
-
+#ifdef CONFIG_PM_SLEEP
 static int pata_macio_suspend(struct macio_dev *mdev, pm_message_t mesg)
 {
        struct ata_host *host = macio_get_drvdata(mdev);
@@ -1223,8 +1220,7 @@ static int pata_macio_resume(struct macio_dev *mdev)
 
        return pata_macio_do_resume(host->private_data);
 }
-
-#endif /* CONFIG_PM */
+#endif /* CONFIG_PM_SLEEP */
 
 #ifdef CONFIG_PMAC_MEDIABAY
 static void pata_macio_mb_event(struct macio_dev* mdev, int mb_state)
@@ -1316,8 +1312,7 @@ static void pata_macio_pci_detach(struct pci_dev *pdev)
        ata_host_detach(host);
 }
 
-#ifdef CONFIG_PM
-
+#ifdef CONFIG_PM_SLEEP
 static int pata_macio_pci_suspend(struct pci_dev *pdev, pm_message_t mesg)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -1331,8 +1326,7 @@ static int pata_macio_pci_resume(struct pci_dev *pdev)
 
        return pata_macio_do_resume(host->private_data);
 }
-
-#endif /* CONFIG_PM */
+#endif /* CONFIG_PM_SLEEP */
 
 static struct of_device_id pata_macio_match[] =
 {
@@ -1360,7 +1354,7 @@ static struct macio_driver pata_macio_driver =
        },
        .probe          = pata_macio_attach,
        .remove         = pata_macio_detach,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = pata_macio_suspend,
        .resume         = pata_macio_resume,
 #endif
@@ -1383,7 +1377,7 @@ static struct pci_driver pata_macio_pci_driver = {
        .id_table       = pata_macio_pci_match,
        .probe          = pata_macio_pci_attach,
        .remove         = pata_macio_pci_detach,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = pata_macio_pci_suspend,
        .resume         = pata_macio_pci_resume,
 #endif
index 6bad3df3a13c7741095ac7e88c80d7d7e75d98c4..ae9feb1ba8f74284ed33828bad85476c3b13623f 100644 (file)
@@ -171,7 +171,7 @@ static struct pci_driver marvell_pci_driver = {
        .id_table               = marvell_pci_tbl,
        .probe                  = marvell_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index 0024ced3e2008e7a2e38b6a8715ee95fee405b2b..ccd1c83a05cc3ecbda025c4910676f2436984630 100644 (file)
@@ -819,9 +819,7 @@ mpc52xx_ata_remove(struct platform_device *op)
        return 0;
 }
 
-
-#ifdef CONFIG_PM
-
+#ifdef CONFIG_PM_SLEEP
 static int
 mpc52xx_ata_suspend(struct platform_device *op, pm_message_t state)
 {
@@ -847,10 +845,8 @@ mpc52xx_ata_resume(struct platform_device *op)
 
        return 0;
 }
-
 #endif
 
-
 static struct of_device_id mpc52xx_ata_of_match[] = {
        { .compatible = "fsl,mpc5200-ata", },
        { .compatible = "mpc5200-ata", },
@@ -861,7 +857,7 @@ static struct of_device_id mpc52xx_ata_of_match[] = {
 static struct platform_driver mpc52xx_ata_of_platform_driver = {
        .probe          = mpc52xx_ata_probe,
        .remove         = mpc52xx_ata_remove,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = mpc52xx_ata_suspend,
        .resume         = mpc52xx_ata_resume,
 #endif
index f39a5379e8165a0adf8e59f3fa34412822724289..202b4d601393c918cb5154e674fbfad46f59ac83 100644 (file)
@@ -223,7 +223,7 @@ static struct pci_driver mpiix_pci_driver = {
        .id_table       = mpiix,
        .probe          = mpiix_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index e3b97093ef9a3cc60aa5a904bc39e7c31f2546b7..0ea18331d4669cf8bad844f64f6a8070880abf1d 100644 (file)
@@ -92,7 +92,7 @@ static struct pci_driver netcell_pci_driver = {
        .id_table               = netcell_pci_tbl,
        .probe                  = netcell_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index 56201a69af127322e0070b3f4b18c8a0d0355cec..efb272da8567e9c5c8b4605f5d38df6f25591a01 100644 (file)
@@ -152,8 +152,7 @@ static int ninja32_init_one(struct pci_dev *dev, const struct pci_device_id *id)
                                 IRQF_SHARED, &ninja32_sht);
 }
 
-#ifdef CONFIG_PM
-
+#ifdef CONFIG_PM_SLEEP
 static int ninja32_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -183,7 +182,7 @@ static struct pci_driver ninja32_pci_driver = {
        .id_table       = ninja32,
        .probe          = ninja32_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ninja32_reinit_one,
 #endif
index 6154c3ee11a5b32d94fd065e0b5abbf8c0109c79..200e1eb23a2014a3822a66f675db5dbaa130613b 100644 (file)
@@ -161,7 +161,7 @@ static struct pci_driver ns87410_pci_driver = {
        .id_table       = ns87410,
        .probe          = ns87410_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index d44df7ccfe43930fa51354ce4dab57545bb381f9..84c6b225b56e941a3f000e7d083700bae9dacf62 100644 (file)
@@ -385,7 +385,7 @@ static const struct pci_device_id ns87415_pci_tbl[] = {
        { }     /* terminate list */
 };
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int ns87415_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -407,7 +407,7 @@ static struct pci_driver ns87415_pci_driver = {
        .id_table               = ns87415_pci_tbl,
        .probe                  = ns87415_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ns87415_reinit_one,
 #endif
index 319b64491b7b504fd1fb67350d16e8374fd6cecf..b9bf78b7d48df0a4405eeffb11a06c3dea6aa31b 100644 (file)
@@ -258,7 +258,7 @@ static struct pci_driver oldpiix_pci_driver = {
        .id_table               = oldpiix_pci_tbl,
        .probe                  = oldpiix_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index fb042e0519d00f780d4a642e4b8a3e27bdec0d11..3a944a029264a4d224bd93e1ca9cc1a16491fe67 100644 (file)
@@ -184,7 +184,7 @@ static struct pci_driver opti_pci_driver = {
        .id_table       = opti,
        .probe          = opti_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index bb71ea214b9902ee63258acefaefc795bf18bbc8..bdec7efa46432fac1a1d64d18a75c016854ef42f 100644 (file)
@@ -440,7 +440,7 @@ static struct pci_driver optidma_pci_driver = {
        .id_table       = optidma,
        .probe          = optidma_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index 1151f23177bb803df56a20fbc30be6032e382598..4d06a5cda987a7e5233d37d094957ef8369afc96 100644 (file)
@@ -62,7 +62,7 @@ enum {
 };
 
 static int pdc2027x_init_one(struct pci_dev *pdev, const struct pci_device_id *ent);
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int pdc2027x_reinit_one(struct pci_dev *pdev);
 #endif
 static int pdc2027x_prereset(struct ata_link *link, unsigned long deadline);
@@ -128,7 +128,7 @@ static struct pci_driver pdc2027x_pci_driver = {
        .id_table               = pdc2027x_pci_tbl,
        .probe                  = pdc2027x_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = pdc2027x_reinit_one,
 #endif
@@ -761,7 +761,7 @@ static int pdc2027x_init_one(struct pci_dev *pdev,
                                 IRQF_SHARED, &pdc2027x_sht);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int pdc2027x_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
index defa050e17843d26db5ef685e8c4263fc64eb23b..9001991d2830d7e2b8cb46f7b40e8db89f0091c1 100644 (file)
@@ -377,7 +377,7 @@ static struct pci_driver pdc202xx_pci_driver = {
        .id_table       = pdc202xx,
        .probe          = pdc202xx_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index 0b46be11705169b0cb8150d2a3792be72caae3c2..35cb0e2632379e8f0ca8c11fde4f8ab2a7d41790 100644 (file)
@@ -110,7 +110,7 @@ static struct pci_driver ata_tosh_pci_driver = {
        .id_table       = ata_tosh,
        .probe          = ata_tosh_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index be3f10240dca4961f80d34437acaac78298dbea1..a3f1123d17aa8d5b3c3b63b4e7b891b9b7543a91 100644 (file)
@@ -237,7 +237,7 @@ static struct pci_driver radisys_pci_driver = {
        .id_table               = radisys_pci_tbl,
        .probe                  = radisys_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index 521b2137ea3e39ccccb35cb78810316bebc26b72..9ce5952216bc6e661da18bbba9b7db6730febd6e 100644 (file)
@@ -382,7 +382,7 @@ static struct pci_driver rdc_pci_driver = {
        .id_table               = rdc_pci_tbl,
        .probe                  = rdc_init_one,
        .remove                 = rdc_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index caedc90855b2fdb931f39018b31f3d9f7b0effff..b3ec18c6bcc6166b1499dec89469a301fa62bd2d 100644 (file)
@@ -101,7 +101,7 @@ static int rz1000_init_one (struct pci_dev *pdev, const struct pci_device_id *en
        return -ENODEV;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int rz1000_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -133,7 +133,7 @@ static struct pci_driver rz1000_pci_driver = {
        .id_table       = pata_rz1000,
        .probe          = rz1000_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = rz1000_reinit_one,
 #endif
index a79566d056666f0d0449785856b679492d71456b..cab8e6024b427ada44f4b80dc99de04f2148be5a 100644 (file)
@@ -615,7 +615,7 @@ static int __exit pata_s3c_remove(struct platform_device *pdev)
        return 0;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int pata_s3c_suspend(struct device *dev)
 {
        struct platform_device *pdev = to_platform_device(dev);
@@ -666,7 +666,7 @@ static struct platform_driver pata_s3c_driver = {
        .driver         = {
                .name   = DRV_NAME,
                .owner  = THIS_MODULE,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
                .pm     = &pata_s3c_pm_ops,
 #endif
        },
index 96a232fffae6089ddfa77b8981e04115700e872a..c71de5d680d1a6c6923afdbcf0a12e8c9d8127d4 100644 (file)
@@ -254,7 +254,7 @@ static struct pci_driver sc1200_pci_driver = {
        .id_table       = sc1200,
        .probe          = sc1200_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index f1f5b5ae33826356230f2689996c34065afb3f7a..4e006d74bef8c0599e11ddda98c8f37a90c839bb 100644 (file)
@@ -1096,7 +1096,7 @@ static struct pci_driver scc_pci_driver = {
        .id_table               = scc_pci_tbl,
        .probe                  = scc_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index 5a1cde0ea3601818456b44b51c0cc059ece726e0..b920c3407f8b26c8c10f73d9b7c58fc9fd056a2f 100644 (file)
@@ -64,7 +64,7 @@ static struct pci_driver sch_pci_driver = {
        .id_table               = sch_pci_tbl,
        .probe                  = sch_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index e27f31fe1b67b93a3c6c326be0d434a26d8d056a..fc5f31d4828e4ab5c27ec4463a1dc4423da53678 100644 (file)
@@ -436,7 +436,7 @@ static int serverworks_init_one(struct pci_dev *pdev, const struct pci_device_id
        return ata_pci_bmdma_init_one(pdev, ppi, &serverworks_sht, NULL, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int serverworks_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -468,7 +468,7 @@ static struct pci_driver serverworks_pci_driver = {
        .id_table       = serverworks,
        .probe          = serverworks_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = serverworks_reinit_one,
 #endif
index 73fe362d97161dffcb75a514c41b65fb9a5baf0b..f597edccedecd1ab952d95fd0dd178e4c1be8c4c 100644 (file)
@@ -403,7 +403,7 @@ use_ioports:
        return ata_pci_bmdma_init_one(pdev, ppi, &sil680_sht, NULL, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sil680_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -429,7 +429,7 @@ static struct pci_driver sil680_pci_driver = {
        .id_table       = sil680,
        .probe          = sil680_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = sil680_reinit_one,
 #endif
index 78d913aa93c812f8eae1ccd572ad1c7ea1dfd22a..626f989d5c6a7f30994d56128332251310d625b5 100644 (file)
@@ -869,7 +869,7 @@ static int sis_init_one (struct pci_dev *pdev, const struct pci_device_id *ent)
        return ata_pci_bmdma_init_one(pdev, ppi, &sis_sht, chipset, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sis_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -899,7 +899,7 @@ static struct pci_driver sis_pci_driver = {
        .id_table               = sis_pci_tbl,
        .probe                  = sis_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = sis_reinit_one,
 #endif
index 900f0e4a1faf61462b20f37b8b29176d194a17e0..4935f61f629cf8a837f5c28eaa6dedf2e5b536a8 100644 (file)
@@ -337,7 +337,7 @@ static int sl82c105_init_one(struct pci_dev *dev, const struct pci_device_id *id
        return ata_pci_bmdma_init_one(dev, ppi, &sl82c105_sht, NULL, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sl82c105_reinit_one(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -365,7 +365,7 @@ static struct pci_driver sl82c105_pci_driver = {
        .id_table       = sl82c105,
        .probe          = sl82c105_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = sl82c105_reinit_one,
 #endif
index 7bc78e264f9eda5cd4cd7eabc4a2acf6dae9bb7e..d9364af8eb63dc89c504187a7c56c5bd4b945067 100644 (file)
@@ -207,7 +207,7 @@ static const struct pci_device_id triflex[] = {
        { },
 };
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int triflex_ata_pci_device_suspend(struct pci_dev *pdev, pm_message_t mesg)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -233,7 +233,7 @@ static struct pci_driver triflex_pci_driver = {
        .id_table       = triflex,
        .probe          = triflex_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = triflex_ata_pci_device_suspend,
        .resume         = ata_pci_device_resume,
 #endif
index f6c9632bdff6a11c6fbdcc18d7ff703d1c4b20cc..1ca6bcab369f015dffc43718b985d58717eabce5 100644 (file)
@@ -659,7 +659,7 @@ static int via_init_one(struct pci_dev *pdev, const struct pci_device_id *id)
        return ata_pci_bmdma_init_one(pdev, ppi, &via_sht, (void *)config, 0);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 /**
  *     via_reinit_one          -       reinit after resume
  *     @pdev; PCI device
@@ -704,7 +704,7 @@ static struct pci_driver via_pci_driver = {
        .id_table       = via,
        .probe          = via_init_one,
        .remove         = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = via_reinit_one,
 #endif
index fb0b40a191c217e47202d252aff5a36d21cf6f6b..e8f150e45446649e5a626f628bf18ed29490da4b 100644 (file)
@@ -1588,7 +1588,7 @@ static int sata_fsl_remove(struct platform_device *ofdev)
        return 0;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sata_fsl_suspend(struct platform_device *op, pm_message_t state)
 {
        struct ata_host *host = platform_get_drvdata(op);
@@ -1644,7 +1644,7 @@ static struct platform_driver fsl_sata_driver = {
        },
        .probe          = sata_fsl_probe,
        .remove         = sata_fsl_remove,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = sata_fsl_suspend,
        .resume         = sata_fsl_resume,
 #endif
index 5c54d957370afcaf9cf6c0d1962d87cc1b98eaac..069827826b20ea9c0ec6a9d13e61dee850ccd524 100644 (file)
@@ -785,7 +785,7 @@ static int init_controller(void __iomem *mmio_base, u16 hctl)
        return 0;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int inic_pci_device_resume(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -898,7 +898,7 @@ static const struct pci_device_id inic_pci_tbl[] = {
 static struct pci_driver inic_pci_driver = {
        .name           = DRV_NAME,
        .id_table       = inic_pci_tbl,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend        = ata_pci_device_suspend,
        .resume         = inic_pci_device_resume,
 #endif
index 05c8a44adf8edea590ec983a7f843c1f5b6b1b55..391cfda1e83fc5a9ae86ead1f3dee1d2427570ec 100644 (file)
@@ -4222,7 +4222,7 @@ static int mv_platform_remove(struct platform_device *pdev)
        return 0;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int mv_platform_suspend(struct platform_device *pdev, pm_message_t state)
 {
        struct ata_host *host = platform_get_drvdata(pdev);
@@ -4289,7 +4289,7 @@ static struct platform_driver mv_platform_driver = {
 #ifdef CONFIG_PCI
 static int mv_pci_init_one(struct pci_dev *pdev,
                           const struct pci_device_id *ent);
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int mv_pci_device_resume(struct pci_dev *pdev);
 #endif
 
@@ -4299,7 +4299,7 @@ static struct pci_driver mv_pci_driver = {
        .id_table               = mv_pci_tbl,
        .probe                  = mv_pci_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = mv_pci_device_resume,
 #endif
@@ -4457,7 +4457,7 @@ static int mv_pci_init_one(struct pci_dev *pdev,
                                 IS_GEN_I(hpriv) ? &mv5_sht : &mv6_sht);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int mv_pci_device_resume(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
index ba5f27120332fe5b2e15d553cb7a7bc25aaa7a44..cdf99fac139a1c2bc5e4f77df39ec2d3be32f400 100644 (file)
@@ -295,7 +295,7 @@ struct nv_swncq_port_priv {
 #define NV_ADMA_CHECK_INTR(GCTL, PORT) ((GCTL) & (1 << (19 + (12 * (PORT)))))
 
 static int nv_init_one(struct pci_dev *pdev, const struct pci_device_id *ent);
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int nv_pci_device_resume(struct pci_dev *pdev);
 #endif
 static void nv_ck804_host_stop(struct ata_host *host);
@@ -379,7 +379,7 @@ static struct pci_driver nv_pci_driver = {
        .name                   = DRV_NAME,
        .id_table               = nv_pci_tbl,
        .probe                  = nv_init_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = nv_pci_device_resume,
 #endif
@@ -2431,7 +2431,7 @@ static int nv_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
        return ata_pci_sff_activate_host(host, ipriv->irq_handler, ipriv->sht);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int nv_pci_device_resume(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
index 2b25bd83fc9d46a2682a0affb409ccf7488abe3d..61eb6d77dac7f507403578a283eade305378f566 100644 (file)
@@ -937,7 +937,7 @@ static int sata_rcar_remove(struct platform_device *pdev)
        return 0;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sata_rcar_suspend(struct device *dev)
 {
        struct ata_host *host = dev_get_drvdata(dev);
@@ -991,7 +991,7 @@ static struct platform_driver sata_rcar_driver = {
                .name           = DRV_NAME,
                .owner          = THIS_MODULE,
                .of_match_table = sata_rcar_match,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
                .pm             = &sata_rcar_pm_ops,
 #endif
        },
index 3062f8605b2955956bff191d6034530ce7fbd636..40b76b2d18c6968af8e977e6c8f94b080a65649e 100644 (file)
@@ -112,7 +112,7 @@ enum {
 };
 
 static int sil_init_one(struct pci_dev *pdev, const struct pci_device_id *ent);
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sil_pci_device_resume(struct pci_dev *pdev);
 #endif
 static void sil_dev_config(struct ata_device *dev);
@@ -166,7 +166,7 @@ static struct pci_driver sil_pci_driver = {
        .id_table               = sil_pci_tbl,
        .probe                  = sil_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = sil_pci_device_resume,
 #endif
@@ -802,7 +802,7 @@ static int sil_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
                                 &sil_sht);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sil_pci_device_resume(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
index aa1051ba6d1334885c9ac5272164e50a364dd6d8..0534890f118a30e05ac1ed5fe1a113992892f534 100644 (file)
@@ -353,8 +353,10 @@ static void sil24_error_handler(struct ata_port *ap);
 static void sil24_post_internal_cmd(struct ata_queued_cmd *qc);
 static int sil24_port_start(struct ata_port *ap);
 static int sil24_init_one(struct pci_dev *pdev, const struct pci_device_id *ent);
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sil24_pci_device_resume(struct pci_dev *pdev);
+#endif
+#ifdef CONFIG_PM
 static int sil24_port_resume(struct ata_port *ap);
 #endif
 
@@ -375,7 +377,7 @@ static struct pci_driver sil24_pci_driver = {
        .id_table               = sil24_pci_tbl,
        .probe                  = sil24_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = sil24_pci_device_resume,
 #endif
@@ -1350,7 +1352,7 @@ static int sil24_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
                                 &sil24_sht);
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int sil24_pci_device_resume(struct pci_dev *pdev)
 {
        struct ata_host *host = pci_get_drvdata(pdev);
@@ -1370,7 +1372,9 @@ static int sil24_pci_device_resume(struct pci_dev *pdev)
 
        return 0;
 }
+#endif
 
+#ifdef CONFIG_PM
 static int sil24_port_resume(struct ata_port *ap)
 {
        sil24_config_pmp(ap, ap->nr_pmp_links);
index b513428171b3592a4033e597ec593a7e4189ab21..d1637ac40a73a84af8497c1c181c08179f96c28a 100644 (file)
@@ -82,7 +82,7 @@ static struct pci_driver sis_pci_driver = {
        .id_table               = sis_pci_tbl,
        .probe                  = sis_init_one,
        .remove                 = ata_pci_remove_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif
index f72e84228c5c10e05db80755df5a64efd5606b38..47bf89464cef80d57e490187d37b23d4656ca299 100644 (file)
@@ -103,7 +103,7 @@ static struct pci_driver svia_pci_driver = {
        .name                   = DRV_NAME,
        .id_table               = svia_pci_tbl,
        .probe                  = svia_init_one,
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
        .suspend                = ata_pci_device_suspend,
        .resume                 = ata_pci_device_resume,
 #endif