diff options
author | Sumit Singh <sumsingh@nvidia.com> | 2014-03-14 11:57:24 +0530 |
---|---|---|
committer | Bharat Nihalani <bnihalani@nvidia.com> | 2014-03-21 03:58:56 -0700 |
commit | 14ad62abbcc1b2a331ff08a2fb874e5eb3c17a01 (patch) | |
tree | 2d18b1465b7dcc9576efc8ece666102f055ab097 /include/asm-generic | |
parent | 055ac86ef17f8bf53a4fcdcda5a501163d17125f (diff) |
asm-generic: processor.h: adding new header file
Defining a new header file and adding architecture
independent macros. Using these macros we are optimizing
power usage on ARM64.
bug 1440421
Change-Id: I7393d35703d0b0a504331653d70f109a50a197c7
Signed-off-by: Sumit Singh <sumsingh@nvidia.com>
Reviewed-on: http://git-master/r/381905
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Alexander Van Brunt <avanbrunt@nvidia.com>
Reviewed-by: Sri Krishna Chowdary <schowdary@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
Diffstat (limited to 'include/asm-generic')
-rw-r--r-- | include/asm-generic/processor.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/include/asm-generic/processor.h b/include/asm-generic/processor.h new file mode 100644 index 000000000000..cba2d9edf736 --- /dev/null +++ b/include/asm-generic/processor.h @@ -0,0 +1,30 @@ +/* + * include/asm-generic/processor.h + * + * Copyright (c) 2014 NVIDIA Corporation. All rights reserved. + * This software is licensed under the terms of the GNU General Public + * License version 2, as published by the Free Software Foundation, and + * may be copied, distributed, and modified under those terms. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ + +#ifndef _ASM_GENERIC_PROCESSOR_H_ +#define _ASM_GENERIC_PROCESSOR_H_ + +#ifndef cpu_relaxed_read +#define cpu_relaxed_read(p) (*(p)) +#endif + +#ifndef cpu_relaxed_read_long +#define cpu_relaxed_read_long(p) (*(p)) +#endif + +#ifndef cpu_read_relax +#define cpu_read_relax() cpu_relax() +#endif + +#endif /*_ASM_GENERIC_PROCESSOR_H_*/ |