Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3fe4bae8 authored by Artem Bityutskiy's avatar Artem Bityutskiy Committed by David Woodhouse
Browse files

mtd: introduce mtd_suspend interface

parent e95e9786
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -191,7 +191,7 @@ static void physmap_flash_shutdown(struct platform_device *dev)

	for (i = 0; i < MAX_RESOURCES && info->mtd[i]; i++)
		if (info->mtd[i]->suspend && info->mtd[i]->resume)
			if (info->mtd[i]->suspend(info->mtd[i]) == 0)
			if (mtd_suspend(info->mtd[i]) == 0)
				info->mtd[i]->resume(info->mtd[i]);
}
#else
+1 −1
Original line number Diff line number Diff line
@@ -125,7 +125,7 @@ static void pxa2xx_flash_shutdown(struct platform_device *dev)
{
	struct pxa2xx_flash_info *info = platform_get_drvdata(dev);

	if (info && info->mtd->suspend(info->mtd) == 0)
	if (info && mtd_suspend(info->mtd) == 0)
		info->mtd->resume(info->mtd);
}
#else
+1 −1
Original line number Diff line number Diff line
@@ -120,7 +120,7 @@ static void rbtx4939_flash_shutdown(struct platform_device *dev)
	struct rbtx4939_flash_info *info = platform_get_drvdata(dev);

	if (info->mtd->suspend && info->mtd->resume)
		if (info->mtd->suspend(info->mtd) == 0)
		if (mtd_suspend(info->mtd) == 0)
			info->mtd->resume(info->mtd);
}
#else
+1 −1
Original line number Diff line number Diff line
@@ -377,7 +377,7 @@ static int __exit sa1100_mtd_remove(struct platform_device *pdev)
static void sa1100_mtd_shutdown(struct platform_device *dev)
{
	struct sa_info *info = platform_get_drvdata(dev);
	if (info && info->mtd->suspend(info->mtd) == 0)
	if (info && mtd_suspend(info->mtd) == 0)
		info->mtd->resume(info->mtd);
}
#else
+1 −1
Original line number Diff line number Diff line
@@ -631,7 +631,7 @@ static int concat_suspend(struct mtd_info *mtd)

	for (i = 0; i < concat->num_subdev; i++) {
		struct mtd_info *subdev = concat->subdev[i];
		if ((rc = subdev->suspend(subdev)) < 0)
		if ((rc = mtd_suspend(subdev)) < 0)
			return rc;
	}
	return rc;
Loading