cregit-Linux how code gets into the kernel

Release 4.14 arch/mips/include/asm/smp-ops.h

/*
 * This file is subject to the terms and conditions of the GNU General
 * Public License.  See the file "COPYING" in the main directory of this
 * archive for more details.
 *
 * Copyright (C) 2000 - 2001 by Kanoj Sarcar (kanoj@sgi.com)
 * Copyright (C) 2000 - 2001 by Silicon Graphics, Inc.
 * Copyright (C) 2000, 2001, 2002 Ralf Baechle
 * Copyright (C) 2000, 2001 Broadcom Corporation
 */
#ifndef __ASM_SMP_OPS_H

#define __ASM_SMP_OPS_H

#include <linux/errno.h>

#include <asm/mips-cps.h>

#ifdef CONFIG_SMP

#include <linux/cpumask.h>

struct task_struct;


struct plat_smp_ops {
	
void (*send_ipi_single)(int cpu, unsigned int action);
	
void (*send_ipi_mask)(const struct cpumask *mask, unsigned int action);
	
void (*init_secondary)(void);
	
void (*smp_finish)(void);
	
int (*boot_secondary)(int cpu, struct task_struct *idle);
	
void (*smp_setup)(void);
	
void (*prepare_cpus)(unsigned int max_cpus);
#ifdef CONFIG_HOTPLUG_CPU
	
int (*cpu_disable)(void);
	
void (*cpu_die)(unsigned int cpu);
#endif
};

extern void register_smp_ops(const struct plat_smp_ops *ops);


static inline void plat_smp_setup(void) { extern const struct plat_smp_ops *mp_ops; /* private */ mp_ops->smp_setup(); }

Contributors

PersonTokensPropCommitsCommitProp
Ralf Bächle2195.45%150.00%
Matt Redfearn14.55%150.00%
Total22100.00%2100.00%

extern void mips_smp_send_ipi_single(int cpu, unsigned int action); extern void mips_smp_send_ipi_mask(const struct cpumask *mask, unsigned int action); #else /* !CONFIG_SMP */ struct plat_smp_ops;
static inline void plat_smp_setup(void) { /* UP, nothing to do ... */ }

Contributors

PersonTokensPropCommitsCommitProp
Ralf Bächle10100.00%1100.00%
Total10100.00%1100.00%


static inline void register_smp_ops(const struct plat_smp_ops *ops) { }

Contributors

PersonTokensPropCommitsCommitProp
Ralf Bächle1191.67%150.00%
Matt Redfearn18.33%150.00%
Total12100.00%2100.00%

#endif /* !CONFIG_SMP */
static inline int register_up_smp_ops(void) { #ifdef CONFIG_SMP_UP extern const struct plat_smp_ops up_smp_ops; register_smp_ops(&up_smp_ops); return 0; #else return -ENODEV; #endif }

Contributors

PersonTokensPropCommitsCommitProp
Ralf Bächle3497.14%266.67%
Matt Redfearn12.86%133.33%
Total35100.00%3100.00%


static inline int register_cmp_smp_ops(void) { #ifdef CONFIG_MIPS_CMP extern const struct plat_smp_ops cmp_smp_ops; if (!mips_cm_present()) return -ENODEV; register_smp_ops(&cmp_smp_ops); return 0; #else return -ENODEV; #endif }

Contributors

PersonTokensPropCommitsCommitProp
Ralf Bächle3475.56%360.00%
Paul Burton1022.22%120.00%
Matt Redfearn12.22%120.00%
Total45100.00%5100.00%


static inline int register_vsmp_smp_ops(void) { #ifdef CONFIG_MIPS_MT_SMP extern const struct plat_smp_ops vsmp_smp_ops; register_smp_ops(&vsmp_smp_ops); return 0; #else return -ENODEV; #endif }

Contributors

PersonTokensPropCommitsCommitProp
Ralf Bächle3497.14%375.00%
Matt Redfearn12.86%125.00%
Total35100.00%4100.00%

#ifdef CONFIG_MIPS_CPS extern int register_cps_smp_ops(void); #else
static inline int register_cps_smp_ops(void) { return -ENODEV; }

Contributors

PersonTokensPropCommitsCommitProp
Paul Burton13100.00%1100.00%
Total13100.00%1100.00%

#endif #endif /* __ASM_SMP_OPS_H */

Overall Contributors

PersonTokensPropCommitsCommitProp
Ralf Bächle29479.03%642.86%
Paul Burton6617.74%535.71%
Matt Redfearn61.61%17.14%
Rusty Russell41.08%17.14%
Qais Yousef20.54%17.14%
Total372100.00%14100.00%
Information contained on this website is for historical information purposes only and does not indicate or represent copyright ownership.
Created with cregit.