1f08c3bdfSopenharmony_ci#ifndef CPUINFO_H 2f08c3bdfSopenharmony_ci# define CPUINFO_H 3f08c3bdfSopenharmony_ci 4f08c3bdfSopenharmony_cistruct cpuinfo { 5f08c3bdfSopenharmony_ci int nodeid; /* which node is this CPU on */ 6f08c3bdfSopenharmony_ci int online; /* is this CPU online */ 7f08c3bdfSopenharmony_ci 8f08c3bdfSopenharmony_ci /* sched domains in each sched level of this CPU */ 9f08c3bdfSopenharmony_ci struct bitmask *sched_domain; 10f08c3bdfSopenharmony_ci}; 11f08c3bdfSopenharmony_ci 12f08c3bdfSopenharmony_ciextern struct cpuinfo *cpus; 13f08c3bdfSopenharmony_ciextern int ncpus; 14f08c3bdfSopenharmony_ciextern int cpus_nbits; 15f08c3bdfSopenharmony_ciextern struct bitmask **domains; 16f08c3bdfSopenharmony_ciextern int ndomains; 17f08c3bdfSopenharmony_ci 18f08c3bdfSopenharmony_ciextern int online_cpumask(struct bitmask *cpumask); 19f08c3bdfSopenharmony_ciextern int present_cpumask(struct bitmask *cpumask); 20f08c3bdfSopenharmony_ciextern int get_ncpus(void); 21f08c3bdfSopenharmony_ciextern int getcpuinfo(void); 22f08c3bdfSopenharmony_ciextern int partition_domains(void); 23f08c3bdfSopenharmony_ci 24f08c3bdfSopenharmony_ci#endif 25