mtd/drivers/mtd mtdcore.c,1.45,1.46
gleixner at infradead.org
gleixner at infradead.org
Thu Aug 11 13:13:46 EDT 2005
Update of /home/cvs/mtd/drivers/mtd
In directory phoenix.infradead.org:/tmp/cvs-serv21502
Modified Files:
mtdcore.c
Log Message:
[MTD] Remove deprecated power management functions
Index: mtdcore.c
===================================================================
RCS file: /home/cvs/mtd/drivers/mtd/mtdcore.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -r1.45 -r1.46
--- mtdcore.c 18 Feb 2005 14:34:50 -0000 1.45
+++ mtdcore.c 11 Aug 2005 17:13:43 -0000 1.46
@@ -297,39 +297,6 @@
EXPORT_SYMBOL(default_mtd_readv);
/*====================================================================*/
-/* Power management code */
-
-#ifdef CONFIG_PM
-
-#include <linux/pm.h>
-
-static struct pm_dev *mtd_pm_dev = NULL;
-
-static int mtd_pm_callback(struct pm_dev *dev, pm_request_t rqst, void *data)
-{
- int ret = 0, i;
-
- if (down_trylock(&mtd_table_mutex))
- return -EAGAIN;
- if (rqst == PM_SUSPEND) {
- for (i = 0; ret == 0 && i < MAX_MTD_DEVICES; i++) {
- if (mtd_table[i] && mtd_table[i]->suspend)
- ret = mtd_table[i]->suspend(mtd_table[i]);
- }
- } else i = MAX_MTD_DEVICES-1;
-
- if (rqst == PM_RESUME || ret) {
- for ( ; i >= 0; i--) {
- if (mtd_table[i] && mtd_table[i]->resume)
- mtd_table[i]->resume(mtd_table[i]);
- }
- }
- up(&mtd_table_mutex);
- return ret;
-}
-#endif
-
-/*====================================================================*/
/* Support for /proc/mtd */
#ifdef CONFIG_PROC_FS
@@ -388,22 +355,11 @@
if ((proc_mtd = create_proc_entry( "mtd", 0, NULL )))
proc_mtd->read_proc = mtd_read_proc;
#endif
-
-#ifdef CONFIG_PM
- mtd_pm_dev = pm_register(PM_UNKNOWN_DEV, 0, mtd_pm_callback);
-#endif
return 0;
}
static void __exit cleanup_mtd(void)
{
-#ifdef CONFIG_PM
- if (mtd_pm_dev) {
- pm_unregister(mtd_pm_dev);
- mtd_pm_dev = NULL;
- }
-#endif
-
#ifdef CONFIG_PROC_FS
if (proc_mtd)
remove_proc_entry( "mtd", NULL);
More information about the linux-mtd-cvs
mailing list