diff options
author | Andrew Donnellan <andrew.donnellan@au1.ibm.com> | 2018-06-20 13:49:36 +1000 |
---|---|---|
committer | Stewart Smith <stewart@linux.ibm.com> | 2018-06-27 17:19:01 +1000 |
commit | ef623f91e5c4719e65784fa976f9227a6926939d (patch) | |
tree | 18a6816fcca9ffa9d06ebbda22884802fdb75e52 /include | |
parent | 815417dcda2e87fc5f1aa087ae5374515cdd86df (diff) | |
download | skiboot-ef623f91e5c4719e65784fa976f9227a6926939d.zip skiboot-ef623f91e5c4719e65784fa976f9227a6926939d.tar.gz skiboot-ef623f91e5c4719e65784fa976f9227a6926939d.tar.bz2 |
occ: Move occ declarations into occ.h
OCC declarations are currently split between skiboot.h and occ-sensor.h.
Given the growing unwieldyness of skiboot.h it's probably time to move it
all into one header.
Rename occ-sensor.h to occ.h, move all OCC-related declarations out of
skiboot.h, and add #includes as necessary.
Signed-off-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Reviewed-by: Shilpasri G Bhat <shilpa.bhat@linux.vnet.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/occ.h (renamed from include/occ-sensor.h) | 32 | ||||
-rw-r--r-- | include/skiboot.h | 27 |
2 files changed, 32 insertions, 27 deletions
diff --git a/include/occ-sensor.h b/include/occ.h index 67ffae8..c9faef9 100644 --- a/include/occ-sensor.h +++ b/include/occ.h @@ -14,6 +14,38 @@ * limitations under the License. */ +/* OCC Functions */ + +extern void occ_pstates_init(void); +extern void occ_fsp_init(void); + +/* OCC interrupt for P8 */ +extern void occ_p8_interrupt(uint32_t chip_id); +extern void occ_send_dummy_interrupt(void); + +/* OCC interrupt for P9 */ +extern void occ_p9_interrupt(uint32_t chip_id); + +/* OCC load support */ +extern void occ_poke_load_queue(void); + +/* OCC/Host PNOR ownership */ +enum pnor_owner { + PNOR_OWNER_HOST, + PNOR_OWNER_EXTERNAL, +}; +extern void occ_pnor_set_owner(enum pnor_owner owner); + + +/* OCC Inband Sensors */ +extern bool occ_sensors_init(void); +extern int occ_sensor_read(u32 handle, u64 *data); +extern int occ_sensor_group_clear(u32 group_hndl, int token); +extern void occ_add_sensor_groups(struct dt_node *sg, u32 *phandles, + u32 *ptype, int nr_phandles, int chipid); + +extern int occ_sensor_group_enable(u32 group_hndl, int token, bool enable); + /* * OCC Sensor Data * diff --git a/include/skiboot.h b/include/skiboot.h index 989565c..bba76c1 100644 --- a/include/skiboot.h +++ b/include/skiboot.h @@ -206,10 +206,8 @@ extern void uart_init(void); extern void mbox_init(void); extern void early_uart_init(void); extern void homer_init(void); -extern void occ_pstates_init(void); extern void slw_init(void); extern void add_cpu_idle_state_properties(void); -extern void occ_fsp_init(void); extern void lpc_rtc_init(void); /* flash support */ @@ -242,23 +240,6 @@ enum { extern void uart_set_console_policy(int policy); extern bool uart_enabled(void); -/* OCC interrupt for P8 */ -extern void occ_p8_interrupt(uint32_t chip_id); -extern void occ_send_dummy_interrupt(void); - -/* OCC interrupt for P9 */ -extern void occ_p9_interrupt(uint32_t chip_id); - -/* OCC load support */ -extern void occ_poke_load_queue(void); - -/* OCC/Host PNOR ownership */ -enum pnor_owner { - PNOR_OWNER_HOST, - PNOR_OWNER_EXTERNAL, -}; -extern void occ_pnor_set_owner(enum pnor_owner owner); - /* PRD */ extern void prd_psi_interrupt(uint32_t proc); extern void prd_tmgt_interrupt(uint32_t proc); @@ -310,12 +291,4 @@ extern int fake_nvram_info(uint32_t *total_size); extern int fake_nvram_start_read(void *dst, uint32_t src, uint32_t len); extern int fake_nvram_write(uint32_t offset, void *src, uint32_t size); -/* OCC Inband Sensors */ -extern bool occ_sensors_init(void); -extern int occ_sensor_read(u32 handle, u64 *data); -extern int occ_sensor_group_clear(u32 group_hndl, int token); -extern void occ_add_sensor_groups(struct dt_node *sg, u32 *phandles, - u32 *ptype, int nr_phandles, int chipid); - -extern int occ_sensor_group_enable(u32 group_hndl, int token, bool enable); #endif /* __SKIBOOT_H */ |