Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 106446
b: refs/heads/master
c: 7b24919
h: refs/heads/master
v: v3
  • Loading branch information
Robert Jarzmik authored and David Woodhouse committed Jul 25, 2008
1 parent e04b2ff commit cce9b1a
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 998453fbf2e0709bf65ac419718ad284401b2b4f
refs/heads/master: 7b2491911540e4904498622fbee2e1a9e3120d2f
11 changes: 7 additions & 4 deletions trunk/drivers/mtd/maps/physmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,8 @@ static int physmap_flash_suspend(struct platform_device *dev, pm_message_t state
int i;

for (i = 0; i < MAX_RESOURCES && info->mtd[i]; i++)
ret |= info->mtd[i]->suspend(info->mtd[i]);
if (info->mtd[i]->suspend)
ret |= info->mtd[i]->suspend(info->mtd[i]);

return ret;
}
Expand All @@ -212,7 +213,8 @@ static int physmap_flash_resume(struct platform_device *dev)
int i;

for (i = 0; i < MAX_RESOURCES && info->mtd[i]; i++)
info->mtd[i]->resume(info->mtd[i]);
if (info->mtd[i]->resume)
info->mtd[i]->resume(info->mtd[i]);

return 0;
}
Expand All @@ -223,8 +225,9 @@ static void physmap_flash_shutdown(struct platform_device *dev)
int i;

for (i = 0; i < MAX_RESOURCES && info->mtd[i]; i++)
if (info->mtd[i]->suspend(info->mtd[i]) == 0)
info->mtd[i]->resume(info->mtd[i]);
if (info->mtd[i]->suspend && info->mtd[i]->resume)
if (info->mtd[i]->suspend(info->mtd[i]) == 0)
info->mtd[i]->resume(info->mtd[i]);
}
#else
#define physmap_flash_suspend NULL
Expand Down

0 comments on commit cce9b1a

Please sign in to comment.