diff mbox series

[2/2] xive: minor cleanup of the interface

Message ID 20190619180058.8016-3-clg@kaod.org
State Accepted
Headers show
Series xive: driver and API cleanups | expand

Checks

Context Check Description
snowpatch_ozlabs/apply_patch success Successfully applied on branch master (b904cb733750de1bb0e04e5012c391a9c3094d11)
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot fail Test snowpatch/job/snowpatch-skiboot on branch master
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot-dco success Signed-off-by present

Commit Message

Cédric Le Goater June 19, 2019, 6 p.m. UTC
The XIVE driver exposes an API to the core OPAL layer and to other
OPAL drivers. This is a minor cleanup preparing ground for POWER10.

Signed-off-by: Cédric Le Goater <clg@kaod.org>
---
 include/interrupts.h | 1 -
 include/skiboot.h    | 1 -
 include/xive.h       | 5 ++---
 core/fast-reboot.c   | 2 +-
 hw/slw.c             | 1 +
 hw/xive.c            | 4 ++--
 6 files changed, 6 insertions(+), 8 deletions(-)
diff mbox series

Patch

diff --git a/include/interrupts.h b/include/interrupts.h
index 2c4fa7e92399..3a142dc67e71 100644
--- a/include/interrupts.h
+++ b/include/interrupts.h
@@ -319,7 +319,6 @@  extern uint32_t get_ics_phandle(void);
 struct cpu_thread;
 
 extern void reset_cpu_icp(void);
-extern void reset_cpu_xive(void);
 extern void icp_send_eoi(uint32_t interrupt);
 extern void icp_prep_for_pm(void);
 extern void icp_kick_cpu(struct cpu_thread *cpu);
diff --git a/include/skiboot.h b/include/skiboot.h
index e828b1584b93..1319895ef976 100644
--- a/include/skiboot.h
+++ b/include/skiboot.h
@@ -304,7 +304,6 @@  enum wakeup_engine_states {
 extern enum wakeup_engine_states wakeup_engine_state;
 extern bool has_deep_states;
 extern void nx_p9_rng_late_init(void);
-extern void xive_late_init(void);
 
 
 
diff --git a/include/xive.h b/include/xive.h
index 1ca0626478b5..abfc78f5a5f1 100644
--- a/include/xive.h
+++ b/include/xive.h
@@ -64,8 +64,7 @@  void xive_cpu_callin(struct cpu_thread *cpu);
  */
 void *xive_get_trigger_port(uint32_t girq);
 
-/* To be used by special EOI override in PSI */
-struct irq_source;
-void __xive_source_eoi(struct irq_source *is, uint32_t isn);
+extern void xive_cpu_reset(void);
+extern void xive_late_init(void);
 
 #endif /* __XIVE_H__ */
diff --git a/core/fast-reboot.c b/core/fast-reboot.c
index 22160b65d2ef..1f7ce09cacfb 100644
--- a/core/fast-reboot.c
+++ b/core/fast-reboot.c
@@ -328,7 +328,7 @@  void __noreturn fast_reboot_entry(void)
 	prlog(PR_DEBUG, "RESET: CPU 0x%04x reset in\n", this_cpu()->pir);
 
 	if (proc_gen == proc_gen_p9) {
-		reset_cpu_xive();
+		xive_cpu_reset();
 	} else if (proc_gen == proc_gen_p8) {
 		/* We reset our ICP first ! Otherwise we might get stray
 		 * interrupts when unsplitting
diff --git a/hw/slw.c b/hw/slw.c
index adbfdce95052..4778a0b42dd8 100644
--- a/hw/slw.c
+++ b/hw/slw.c
@@ -31,6 +31,7 @@ 
 #include <opal-api.h>
 #include <nvram.h>
 #include <sbe-p8.h>
+#include <xive.h>
 
 #include <p9_stop_api.H>
 #include <p8_pore_table_gen_api.H>
diff --git a/hw/xive.c b/hw/xive.c
index 3e2687f8b636..8fa42f7a4e75 100644
--- a/hw/xive.c
+++ b/hw/xive.c
@@ -2648,7 +2648,7 @@  static int64_t xive_source_set_xive(struct irq_source *is,
 	return __xive_set_irq_config(is, isn, server, prio, isn, true, true);
 }
 
-void __xive_source_eoi(struct irq_source *is, uint32_t isn)
+static void __xive_source_eoi(struct irq_source *is, uint32_t isn)
 {
 	struct xive_src *s = container_of(is, struct xive_src, is);
 	uint32_t idx = isn - s->esb_base;
@@ -4818,7 +4818,7 @@  static void xive_reset_mask_source_cb(struct irq_source *is,
 	}
 }
 
-void reset_cpu_xive(void)
+void xive_cpu_reset(void)
 {
 	struct cpu_thread *c = this_cpu();
 	struct xive_cpu_state *xs = c->xstate;