Merge branches 'pm-core', 'pm-clk', 'pm-domains' and 'pm-pci'
[deliverable/linux.git] / arch / x86 / include / asm / current.h
CommitLineData
1965aae3
PA
1#ifndef _ASM_X86_CURRENT_H
2#define _ASM_X86_CURRENT_H
f0766440 3
f0766440
CL
4#include <linux/compiler.h>
5#include <asm/percpu.h>
6
c6f5e0ac 7#ifndef __ASSEMBLY__
f0766440
CL
8struct task_struct;
9
10DECLARE_PER_CPU(struct task_struct *, current_task);
f0766440
CL
11
12static __always_inline struct task_struct *get_current(void)
13{
c6ae41e7 14 return this_cpu_read_stable(current_task);
f0766440
CL
15}
16
c6f5e0ac 17#define current get_current()
f0766440
CL
18
19#endif /* __ASSEMBLY__ */
20
1965aae3 21#endif /* _ASM_X86_CURRENT_H */
This page took 0.480874 seconds and 5 git commands to generate.