blob: e49830003be0a5fadd1dd9c1c42ddaf5023fd6c0 [file] [log] [blame]
The Android Open Source Project1dc9e472009-03-03 19:28:35 -08001/****************************************************************************
2 ****************************************************************************
3 ***
4 *** This header was automatically generated from a Linux kernel header
5 *** of the same name, to make information necessary for userspace to
6 *** call into the kernel available to libc. It contains only constants,
7 *** structures, and macros generated from the original header, and thus,
8 *** contains no copyrightable information.
9 ***
10 ****************************************************************************
11 ****************************************************************************/
12#ifndef _ASM_GENERIC_PERCPU_H_
13#define _ASM_GENERIC_PERCPU_H_
14#include <linux/compiler.h>
Ben Cheng4b29af02012-03-07 16:14:53 -080015
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080016#define __GENERIC_PER_CPU
Ben Cheng4b29af02012-03-07 16:14:53 -080017
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080018#define DEFINE_PER_CPU(type, name) __typeof__(type) per_cpu__##name
Ben Cheng4b29af02012-03-07 16:14:53 -080019
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080020#define per_cpu(var, cpu) (*((void)(cpu), &per_cpu__##var))
21#define __get_cpu_var(var) per_cpu__##var
22#define __raw_get_cpu_var(var) per_cpu__##var
Ben Cheng4b29af02012-03-07 16:14:53 -080023
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080024#define DECLARE_PER_CPU(type, name) extern __typeof__(type) per_cpu__##name
Ben Cheng4b29af02012-03-07 16:14:53 -080025
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080026#define EXPORT_PER_CPU_SYMBOL(var) EXPORT_SYMBOL(per_cpu__##var)
27#define EXPORT_PER_CPU_SYMBOL_GPL(var) EXPORT_SYMBOL_GPL(per_cpu__##var)
Ben Cheng4b29af02012-03-07 16:14:53 -080028
The Android Open Source Project1dc9e472009-03-03 19:28:35 -080029#endif