Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=d5476689afd48e71395602698409e9f48cbba413
Commit:     d5476689afd48e71395602698409e9f48cbba413
Parent:     6c77fd649fab4bea1b44cb534381a22e37650bc3
Author:     [EMAIL PROTECTED] <[EMAIL PROTECTED]>
AuthorDate: Sun Feb 3 12:56:03 2008 -0800
Committer:  David Woodhouse <[EMAIL PROTECTED]>
CommitDate: Thu Feb 7 10:33:40 2008 +0000

    [MTD] Fix maps/physmap.c compilation with CONFIG_PM
    
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: David Woodhouse <[EMAIL PROTECTED]>
---
 drivers/mtd/maps/physmap.c |   14 ++++++++------
 1 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/drivers/mtd/maps/physmap.c b/drivers/mtd/maps/physmap.c
index 5a83ae7..f00e04e 100644
--- a/drivers/mtd/maps/physmap.c
+++ b/drivers/mtd/maps/physmap.c
@@ -204,7 +204,7 @@ static int physmap_flash_suspend(struct platform_device 
*dev, pm_message_t state
 
        if (info)
                for (i = 0; i < MAX_RESOURCES; i++)
-                       ret |= info->mtd[i].suspend(info->mtd[i]);
+                       ret |= info->mtd[i]->suspend(info->mtd[i]);
 
        return ret;
 }
@@ -216,7 +216,7 @@ static int physmap_flash_resume(struct platform_device *dev)
 
        if (info)
                for (i = 0; i < MAX_RESOURCES; i++)
-                       info->mtd[i].resume(info->mtd[i]);
+                       info->mtd[i]->resume(info->mtd[i]);
        return 0;
 }
 
@@ -226,19 +226,21 @@ static void physmap_flash_shutdown(struct platform_device 
*dev)
        int i;
 
        for (i = 0; i < MAX_RESOURCES; i++)
-               if (info && info->mtd[i].suspend(info->mtd[i]) == 0)
-                       info->mtd[i].resume(info->mtd[i]);
+               if (info && info->mtd[i]->suspend(info->mtd[i]) == 0)
+                       info->mtd[i]->resume(info->mtd[i]);
 }
+#else
+#define physmap_flash_suspend NULL
+#define physmap_flash_resume NULL
+#define physmap_flash_shutdown NULL
 #endif
 
 static struct platform_driver physmap_flash_driver = {
        .probe          = physmap_flash_probe,
        .remove         = physmap_flash_remove,
-#ifdef CONFIG_PM
        .suspend        = physmap_flash_suspend,
        .resume         = physmap_flash_resume,
        .shutdown       = physmap_flash_shutdown,
-#endif
        .driver         = {
                .name   = "physmap-flash",
        },
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to