summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSamuel Holland <[email protected]>2024-10-25 11:59:48 -0700
committerAnup Patel <[email protected]>2024-11-11 18:21:04 +0530
commit86d2c1797a44975e628bcf77e30e687fd6738e81 (patch)
tree655d5be8fb89fadf22932bea881cd4c8f617d7dd /include
parent693afc818feecdbddb75f5c9ec4b436d56f64208 (diff)
platform: Drop IPI warm init and exit hooks
Now that the SBI IPI core clears IPIs at warm boot in a generic way, none of the drivers or platforms use these hooks, and we can remove them. Platforms need only to initialize the driver once during cold init. If other hooks are needed in the future, they can be added to struct sbi_ipi_device. Signed-off-by: Samuel Holland <[email protected]> Reviewed-by: Anup Patel <[email protected]>
Diffstat (limited to 'include')
-rw-r--r--include/sbi/sbi_platform.h25
-rw-r--r--include/sbi_utils/ipi/fdt_ipi.h9
2 files changed, 7 insertions, 27 deletions
diff --git a/include/sbi/sbi_platform.h b/include/sbi/sbi_platform.h
index 3e21a628..e94ab37c 100644
--- a/include/sbi/sbi_platform.h
+++ b/include/sbi/sbi_platform.h
@@ -116,10 +116,8 @@ struct sbi_platform_operations {
/** Exit the platform interrupt controller for current HART */
void (*irqchip_exit)(void);
- /** Initialize IPI for current HART */
- int (*ipi_init)(bool cold_boot);
- /** Exit IPI for current HART */
- void (*ipi_exit)(void);
+ /** Initialize IPI during cold boot */
+ int (*ipi_init)(void);
/** Get tlb flush limit value **/
u64 (*get_tlbr_flush_limit)(void);
@@ -572,33 +570,20 @@ static inline void sbi_platform_irqchip_exit(const struct sbi_platform *plat)
}
/**
- * Initialize the platform IPI support for current HART
+ * Initialize the platform IPI support during cold boot
*
* @param plat pointer to struct sbi_platform
- * @param cold_boot whether cold boot (true) or warm_boot (false)
*
* @return 0 on success and negative error code on failure
*/
-static inline int sbi_platform_ipi_init(const struct sbi_platform *plat,
- bool cold_boot)
+static inline int sbi_platform_ipi_init(const struct sbi_platform *plat)
{
if (plat && sbi_platform_ops(plat)->ipi_init)
- return sbi_platform_ops(plat)->ipi_init(cold_boot);
+ return sbi_platform_ops(plat)->ipi_init();
return 0;
}
/**
- * Exit the platform IPI support for current HART
- *
- * @param plat pointer to struct sbi_platform
- */
-static inline void sbi_platform_ipi_exit(const struct sbi_platform *plat)
-{
- if (plat && sbi_platform_ops(plat)->ipi_exit)
- sbi_platform_ops(plat)->ipi_exit();
-}
-
-/**
* Initialize the platform timer during cold boot
*
* @param plat pointer to struct sbi_platform
diff --git a/include/sbi_utils/ipi/fdt_ipi.h b/include/sbi_utils/ipi/fdt_ipi.h
index c6245201..161f7a2e 100644
--- a/include/sbi_utils/ipi/fdt_ipi.h
+++ b/include/sbi_utils/ipi/fdt_ipi.h
@@ -17,18 +17,13 @@
struct fdt_ipi {
const struct fdt_match *match_table;
int (*cold_init)(const void *fdt, int nodeoff, const struct fdt_match *match);
- int (*warm_init)(void);
- void (*exit)(void);
};
-void fdt_ipi_exit(void);
-
-int fdt_ipi_init(bool cold_boot);
+int fdt_ipi_init(void);
#else
-static inline void fdt_ipi_exit(void) { }
-static inline int fdt_ipi_init(bool cold_boot) { return 0; }
+static inline int fdt_ipi_init(void) { return 0; }
#endif