forked from ~ljy/RK356X_SDK_RELEASE

hc
2024-01-31 f9004dbfff8a3fbbd7e2a88c8a4327c7f2f8e5b2
kernel/arch/arm/mach-omap2/omap_hwmod.h
....@@ -1,3 +1,4 @@
1
+/* SPDX-License-Identifier: GPL-2.0-only */
12 /*
23 * omap_hwmod macros, structures
34 *
....@@ -8,10 +9,6 @@
89 * Created in collaboration with (alphabetical order): BenoƮt Cousson,
910 * Kevin Hilman, Tony Lindgren, Rajendra Nayak, Vikram Pandita, Sakari
1011 * Poussa, Anand Sawant, Santosh Shilimkar, Richard Woodruff
11
- *
12
- * This program is free software; you can redistribute it and/or modify
13
- * it under the terms of the GNU General Public License version 2 as
14
- * published by the Free Software Foundation.
1512 *
1613 * These headers and macros are used to define OMAP on-chip module
1714 * data and their integration with other OMAP modules and Linux.
....@@ -24,7 +21,6 @@
2421 * - init_conn_id_bit (CONNID_BIT_VECTOR)
2522 * - implement default hwmod SMS/SDRC flags?
2623 * - move Linux-specific data ("non-ROM data") out
27
- *
2824 */
2925 #ifndef __ARCH_ARM_PLAT_OMAP_INCLUDE_MACH_OMAP_HWMOD_H
3026 #define __ARCH_ARM_PLAT_OMAP_INCLUDE_MACH_OMAP_HWMOD_H
....@@ -493,14 +489,18 @@
493489 #define _HWMOD_STATE_IDLE 5
494490 #define _HWMOD_STATE_DISABLED 6
495491
492
+#ifdef CONFIG_PM
493
+#define _HWMOD_STATE_DEFAULT _HWMOD_STATE_IDLE
494
+#else
495
+#define _HWMOD_STATE_DEFAULT _HWMOD_STATE_ENABLED
496
+#endif
497
+
496498 /**
497499 * struct omap_hwmod_class - the type of an IP block
498500 * @name: name of the hwmod_class
499501 * @sysc: device SYSCONFIG/SYSSTATUS register data
500
- * @rev: revision of the IP class
501502 * @pre_shutdown: ptr to fn to be executed immediately prior to device shutdown
502503 * @reset: ptr to fn to be executed in place of the standard hwmod reset fn
503
- * @enable_preprogram: ptr to fn to be executed during device enable
504504 * @lock: ptr to fn to be executed to lock IP registers
505505 * @unlock: ptr to fn to be executed to unlock IP registers
506506 *
....@@ -523,10 +523,8 @@
523523 struct omap_hwmod_class {
524524 const char *name;
525525 struct omap_hwmod_class_sysconfig *sysc;
526
- u32 rev;
527526 int (*pre_shutdown)(struct omap_hwmod *oh);
528527 int (*reset)(struct omap_hwmod *oh);
529
- int (*enable_preprogram)(struct omap_hwmod *oh);
530528 void (*lock)(struct omap_hwmod *oh);
531529 void (*unlock)(struct omap_hwmod *oh);
532530 };
....@@ -646,9 +644,6 @@
646644 struct powerdomain *omap_hwmod_get_pwrdm(struct omap_hwmod *oh);
647645 void __iomem *omap_hwmod_get_mpu_rt_va(struct omap_hwmod *oh);
648646
649
-int omap_hwmod_enable_wakeup(struct omap_hwmod *oh);
650
-int omap_hwmod_disable_wakeup(struct omap_hwmod *oh);
651
-
652647 int omap_hwmod_for_each_by_class(const char *classname,
653648 int (*fn)(struct omap_hwmod *oh,
654649 void *user),
....@@ -665,7 +660,6 @@
665660 *
666661 */
667662
668
-extern int omap_hwmod_aess_preprogram(struct omap_hwmod *oh);
669663 void omap_hwmod_rtc_unlock(struct omap_hwmod *oh);
670664 void omap_hwmod_rtc_lock(struct omap_hwmod *oh);
671665