blob: a06a08a9afc68396c0c92bf45302caf88c24f963 [file] [log] [blame]
Paul Burton0ee958e2014-01-15 10:31:53 +00001/*
2 * Copyright (C) 2013 Imagination Technologies
3 * Author: Paul Burton <paul.burton@imgtec.com>
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License as published by the
7 * Free Software Foundation; either version 2 of the License, or (at your
8 * option) any later version.
9 */
10
11#ifndef __MIPS_ASM_SMP_CPS_H__
12#define __MIPS_ASM_SMP_CPS_H__
13
14#ifndef __ASSEMBLY__
15
Paul Burton245a7862014-04-14 12:04:27 +010016struct vpe_boot_config {
Paul Burton0ee958e2014-01-15 10:31:53 +000017 unsigned long pc;
18 unsigned long sp;
19 unsigned long gp;
20};
21
Paul Burton245a7862014-04-14 12:04:27 +010022struct core_boot_config {
23 atomic_t vpe_mask;
24 struct vpe_boot_config *vpe_config;
25};
26
27extern struct core_boot_config *mips_cps_core_bootcfg;
Paul Burton0ee958e2014-01-15 10:31:53 +000028
29extern void mips_cps_core_entry(void);
Paul Burton245a7862014-04-14 12:04:27 +010030extern void mips_cps_core_init(void);
31
32extern struct vpe_boot_config *mips_cps_boot_vpes(void);
Paul Burton0ee958e2014-01-15 10:31:53 +000033
Paul Burton68c12322014-03-14 16:06:16 +000034extern bool mips_cps_smp_in_use(void);
35
Paul Burton3179d372014-04-14 11:00:56 +010036extern void mips_cps_pm_save(void);
37extern void mips_cps_pm_restore(void);
38
Paul Burton0ee958e2014-01-15 10:31:53 +000039#else /* __ASSEMBLY__ */
40
41.extern mips_cps_bootcfg;
42
43#endif /* __ASSEMBLY__ */
44#endif /* __MIPS_ASM_SMP_CPS_H__ */