diff options
| author | Thomas Gleixner <tglx@linutronix.de> | 2011-06-17 15:42:38 +0200 |
|---|---|---|
| committer | Clark Williams <williams@redhat.com> | 2012-02-15 10:32:41 -0600 |
| commit | d2ebdf54a190042e8b8c37df537f02e78556ce47 (patch) | |
| tree | 8ef6b9609ec23433963ffca2f4eb50cd97a76b24 /include | |
| parent | dafd7f83eac213b578f97f2bef9cda8c11f72a9b (diff) | |
cpu-rt-variants.patch
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/smp.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/linux/smp.h b/include/linux/smp.h index 8cc38d3bab0c..e6c58d8796b3 100644 --- a/include/linux/smp.h +++ b/include/linux/smp.h @@ -173,6 +173,14 @@ smp_call_function_any(const struct cpumask *mask, smp_call_func_t func, #define get_cpu() ({ preempt_disable(); smp_processor_id(); }) #define put_cpu() preempt_enable() +#ifndef CONFIG_PREEMPT_RT_FULL +# define get_cpu_light() get_cpu() +# define put_cpu_light() put_cpu() +#else +# define get_cpu_light() ({ migrate_disable(); smp_processor_id(); }) +# define put_cpu_light() migrate_enable() +#endif + /* * Callback to arch code if there's nosmp or maxcpus=0 on the * boot command line: |
