summaryrefslogtreecommitdiffstats
path: root/kernel/arch/arm64/lib/Makefile
blob: 1a811ecf71da8a8032a1e8cda8cf686f8fc71189 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
lib-y		:= bitops.o clear_user.o delay.o copy_from_user.o	\
		   copy_to_user.o copy_in_user.o copy_page.o		\
		   clear_page.o memchr.o memcpy.o memmove.o memset.o	\
		   memcmp.o strcmp.o strncmp.o strlen.o strnlen.o	\
		   strchr.o strrchr.o

# Tell the compiler to treat all general purpose registers as
# callee-saved, which allows for efficient runtime patching of the bl
# instruction in the caller with an atomic instruction when supported by
# the CPU. Result and argument registers are handled correctly, based on
# the function prototype.
lib-$(CONFIG_ARM64_LSE_ATOMICS) += atomic_ll_sc.o
CFLAGS_atomic_ll_sc.o	:= -fcall-used-x0 -ffixed-x1 -ffixed-x2		\
		   -ffixed-x3 -ffixed-x4 -ffixed-x5 -ffixed-x6		\
		   -ffixed-x7 -fcall-saved-x8 -fcall-saved-x9		\
		   -fcall-saved-x10 -fcall-saved-x11 -fcall-saved-x12	\
		   -fcall-saved-x13 -fcall-saved-x14 -fcall-saved-x15	\
		   -fcall-saved-x16 -fcall-saved-x17 -fcall-saved-x18
ted "as is" WITHOUT ANY WARRANTY of any * kind, whether express or implied; without even the implied warranty * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. */ #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt #include <linux/cpufreq.h> #include <linux/module.h> #include <linux/platform_device.h> #include <linux/pm_opp.h> #include <linux/types.h> #include "arm_big_little.h" static int ve_spc_init_opp_table(struct device *cpu_dev) { /* * platform specific SPC code must initialise the opp table * so just check if the OPP count is non-zero */ return dev_pm_opp_get_opp_count(cpu_dev) <= 0; } static int ve_spc_get_transition_latency(struct device *cpu_dev) { return 1000000; /* 1 ms */ } static struct cpufreq_arm_bL_ops ve_spc_cpufreq_ops = { .name = "vexpress-spc", .get_transition_latency = ve_spc_get_transition_latency, .init_opp_table = ve_spc_init_opp_table, }; static int ve_spc_cpufreq_probe(struct platform_device *pdev) { return bL_cpufreq_register(&ve_spc_cpufreq_ops); } static int ve_spc_cpufreq_remove(struct platform_device *pdev) { bL_cpufreq_unregister(&ve_spc_cpufreq_ops); return 0; } static struct platform_driver ve_spc_cpufreq_platdrv = { .driver = { .name = "vexpress-spc-cpufreq", }, .probe = ve_spc_cpufreq_probe, .remove = ve_spc_cpufreq_remove, }; module_platform_driver(ve_spc_cpufreq_platdrv); MODULE_LICENSE("GPL");