From 392e8802486cb573b916e746010e141a75f507e6 Mon Sep 17 00:00:00 2001 From: Kevin Date: Sat, 15 Nov 2014 09:58:27 +0800 Subject: init android origin source code --- ANDROID_3.4.5/arch/x86/include/asm/current.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 ANDROID_3.4.5/arch/x86/include/asm/current.h (limited to 'ANDROID_3.4.5/arch/x86/include/asm/current.h') diff --git a/ANDROID_3.4.5/arch/x86/include/asm/current.h b/ANDROID_3.4.5/arch/x86/include/asm/current.h new file mode 100644 index 00000000..4d447b73 --- /dev/null +++ b/ANDROID_3.4.5/arch/x86/include/asm/current.h @@ -0,0 +1,21 @@ +#ifndef _ASM_X86_CURRENT_H +#define _ASM_X86_CURRENT_H + +#include +#include + +#ifndef __ASSEMBLY__ +struct task_struct; + +DECLARE_PER_CPU(struct task_struct *, current_task); + +static __always_inline struct task_struct *get_current(void) +{ + return percpu_read_stable(current_task); +} + +#define current get_current() + +#endif /* __ASSEMBLY__ */ + +#endif /* _ASM_X86_CURRENT_H */ -- cgit