* [PATCH] cpuidle: governor: export cpuidle_register_governor
@ 2020-06-30 19:13 Lina Iyer
2020-06-30 20:26 ` Lina Iyer
2020-07-01 8:19 ` kernel test robot
0 siblings, 2 replies; 8+ messages in thread
From: Lina Iyer @ 2020-06-30 19:13 UTC (permalink / raw)
To: rjw, daniel.lezcano; +Cc: linux-pm, linux-arm-msm, Lina Iyer
Commit 83788c0caed3 ("cpuidle: remove unused exports") removed
capability of registering cpuidle governors. With this change, let's
bring the capability back to allow cpuidle governors to be registered
from a module.
Signed-off-by: Lina Iyer <ilina@codeaurora.org>
---
drivers/cpuidle/governor.c | 1 +
include/linux/cpuidle.h | 1 +
2 files changed, 2 insertions(+)
diff --git a/drivers/cpuidle/governor.c b/drivers/cpuidle/governor.c
index 29acaf48e575..480ec58cffa9 100644
--- a/drivers/cpuidle/governor.c
+++ b/drivers/cpuidle/governor.c
@@ -102,6 +102,7 @@ int cpuidle_register_governor(struct cpuidle_governor *gov)
return ret;
}
+EXPORT_SYMBOL_GPL(cpuidle_register_governor);
/**
* cpuidle_governor_latency_req - Compute a latency constraint for CPU
diff --git a/include/linux/cpuidle.h b/include/linux/cpuidle.h
index ec2ef63771f0..cc02ce7eab6c 100644
--- a/include/linux/cpuidle.h
+++ b/include/linux/cpuidle.h
@@ -264,6 +264,7 @@ struct cpuidle_governor {
bool *stop_tick);
void (*reflect) (struct cpuidle_device *dev, int index);
};
+EXPORT_SYMBOL_GPL(cpuidle_governor);
#ifdef CONFIG_CPU_IDLE
extern int cpuidle_register_governor(struct cpuidle_governor *gov);
--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project
^ permalink raw reply related [flat|nested] 8+ messages in thread* Re: [PATCH] cpuidle: governor: export cpuidle_register_governor 2020-06-30 19:13 [PATCH] cpuidle: governor: export cpuidle_register_governor Lina Iyer @ 2020-06-30 20:26 ` Lina Iyer 2020-07-01 8:19 ` kernel test robot 1 sibling, 0 replies; 8+ messages in thread From: Lina Iyer @ 2020-06-30 20:26 UTC (permalink / raw) To: rjw, daniel.lezcano; +Cc: linux-pm, linux-arm-msm Please ignore this patch. Will re-send. Thanks, Lina On Tue, Jun 30 2020 at 13:13 -0600, Lina Iyer wrote: >Commit 83788c0caed3 ("cpuidle: remove unused exports") removed >capability of registering cpuidle governors. With this change, let's >bring the capability back to allow cpuidle governors to be registered >from a module. > >Signed-off-by: Lina Iyer <ilina@codeaurora.org> >--- > drivers/cpuidle/governor.c | 1 + > include/linux/cpuidle.h | 1 + > 2 files changed, 2 insertions(+) > >diff --git a/drivers/cpuidle/governor.c b/drivers/cpuidle/governor.c >index 29acaf48e575..480ec58cffa9 100644 >--- a/drivers/cpuidle/governor.c >+++ b/drivers/cpuidle/governor.c >@@ -102,6 +102,7 @@ int cpuidle_register_governor(struct cpuidle_governor *gov) > > return ret; > } >+EXPORT_SYMBOL_GPL(cpuidle_register_governor); > > /** > * cpuidle_governor_latency_req - Compute a latency constraint for CPU >diff --git a/include/linux/cpuidle.h b/include/linux/cpuidle.h >index ec2ef63771f0..cc02ce7eab6c 100644 >--- a/include/linux/cpuidle.h >+++ b/include/linux/cpuidle.h >@@ -264,6 +264,7 @@ struct cpuidle_governor { > bool *stop_tick); > void (*reflect) (struct cpuidle_device *dev, int index); > }; >+EXPORT_SYMBOL_GPL(cpuidle_governor); > > #ifdef CONFIG_CPU_IDLE > extern int cpuidle_register_governor(struct cpuidle_governor *gov); >-- >The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, >a Linux Foundation Collaborative Project > ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] cpuidle: governor: export cpuidle_register_governor 2020-06-30 19:13 [PATCH] cpuidle: governor: export cpuidle_register_governor Lina Iyer @ 2020-07-01 8:19 ` kernel test robot 2020-07-01 8:19 ` kernel test robot 1 sibling, 0 replies; 8+ messages in thread From: kernel test robot @ 2020-07-01 8:19 UTC (permalink / raw) To: Lina Iyer, rjw, daniel.lezcano Cc: kbuild-all, linux-pm, linux-arm-msm, Lina Iyer [-- Attachment #1: Type: text/plain, Size: 30621 bytes --] Hi Lina, Thank you for the patch! Yet something to improve: [auto build test ERROR on pm/linux-next] [also build test ERROR on daniel.lezcano/clockevents/next v5.8-rc3 next-20200701] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Lina-Iyer/cpuidle-governor-export-cpuidle_register_governor/20200701-031538 base: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git linux-next config: i386-randconfig-s002-20200630 (attached as .config) compiler: gcc-9 (Debian 9.3.0-13) 9.3.0 reproduce: # apt-get install sparse # sparse version: v0.6.2-3-gfa153962-dirty # save the attached .config to linux build tree make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=i386 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@intel.com> All error/warnings (new ones prefixed by >>): In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/fair.c:23: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/core.c:9: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from kernel/rcu/update.c:587: kernel/rcu/tasks.h:405:6: warning: no previous prototype for 'rcu_tasks_postscan' [-Wmissing-prototypes] 405 | void rcu_tasks_postscan(struct list_head *hop) | ^~~~~~~~~~~~~~~~~~ kernel/rcu/tasks.h:757:6: warning: no previous prototype for 'rcu_read_unlock_trace_special' [-Wmissing-prototypes] 757 | void rcu_read_unlock_trace_special(struct task_struct *t, int nesting) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ kernel/rcu/tasks.h:1135:6: warning: no previous prototype for 'synchronize_rcu_tasks_trace' [-Wmissing-prototypes] 1135 | void synchronize_rcu_tasks_trace(void) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from kernel/rcu/update.c:587: kernel/rcu/tasks.h:1148:6: warning: no previous prototype for 'rcu_barrier_tasks_trace' [-Wmissing-prototypes] 1148 | void rcu_barrier_tasks_trace(void) | ^~~~~~~~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:305:5: warning: no previous prototype for '__register_ftrace_function' [-Wmissing-prototypes] 305 | int __register_ftrace_function(struct ftrace_ops *ops) | ^~~~~~~~~~~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:348:5: warning: no previous prototype for '__unregister_ftrace_function' [-Wmissing-prototypes] 348 | int __unregister_ftrace_function(struct ftrace_ops *ops) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ kernel/bpf/core.c:1353:12: warning: no previous prototype for 'bpf_probe_read_kernel' [-Wmissing-prototypes] 1353 | u64 __weak bpf_probe_read_kernel(void *dst, u32 size, const void *unsafe_ptr) | ^~~~~~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/wait.c:7: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from kernel/bpf/core.c:21: kernel/bpf/core.c: In function '___bpf_prog_run': include/linux/filter.h:879:3: warning: cast between incompatible function types from 'u64 (*)(u64, u64, u64, u64, u64)' {aka 'long long unsigned int (*)(long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int)'} to 'u64 (*)(u64, u64, u64, u64, u64, const struct bpf_insn *)' {aka 'long long unsigned int (*)(long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, const struct bpf_insn *)'} [-Wcast-function-type] 879 | ((u64 (*)(u64, u64, u64, u64, u64, const struct bpf_insn *)) \ | ^ kernel/bpf/core.c:1521:13: note: in expansion of macro '__bpf_call_base_args' 1521 | BPF_R0 = (__bpf_call_base_args + insn->imm)(BPF_R1, BPF_R2, | ^~~~~~~~~~~~~~~~~~~~ kernel/bpf/core.c: In function 'bpf_patch_call_args': include/linux/filter.h:879:3: warning: cast between incompatible function types from 'u64 (*)(u64, u64, u64, u64, u64)' {aka 'long long unsigned int (*)(long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int)'} to 'u64 (*)(u64, u64, u64, u64, u64, const struct bpf_insn *)' {aka 'long long unsigned int (*)(long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, const struct bpf_insn *)'} [-Wcast-function-type] 879 | ((u64 (*)(u64, u64, u64, u64, u64, const struct bpf_insn *)) \ | ^ kernel/bpf/core.c:1712:3: note: in expansion of macro '__bpf_call_base_args' 1712 | __bpf_call_base_args; | ^~~~~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/loadavg.c:9: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:3801:15: warning: no previous prototype for 'arch_ftrace_match_adjust' [-Wmissing-prototypes] 3801 | char * __weak arch_ftrace_match_adjust(char *str, const char *search) | ^~~~~~~~~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c: In function 'process_mod_list': kernel/trace/ftrace.c:4112:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] 4112 | int ret; | ^~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/clock.c:56: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c: In function 'ftrace_regex_release': kernel/trace/ftrace.c:5517:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] 5517 | int ret; | ^~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/rt.c:6: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/cputime.c:5: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/deadline.c:18: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/panic.c:85:13: warning: no previous prototype for 'panic_smp_self_stop' [-Wmissing-prototypes] 85 | void __weak panic_smp_self_stop(void) | ^~~~~~~~~~~~~~~~~~~ kernel/panic.c:95:13: warning: no previous prototype for 'nmi_panic_self_stop' [-Wmissing-prototypes] 95 | void __weak nmi_panic_self_stop(struct pt_regs *regs) | ^~~~~~~~~~~~~~~~~~~ kernel/panic.c:106:13: warning: no previous prototype for 'crash_smp_send_stop' [-Wmissing-prototypes] 106 | void __weak crash_smp_send_stop(void) | ^~~~~~~~~~~~~~~~~~~ kernel/panic.c: In function '__warn': kernel/panic.c:590:3: warning: function '__warn' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format] 590 | vprintk(args->fmt, args->args); | ^~~~~~~ kernel/panic.c: At top level: kernel/panic.c:683:24: warning: no previous prototype for '__stack_chk_fail' [-Wmissing-prototypes] 683 | __visible noinstr void __stack_chk_fail(void) | ^~~~~~~~~~~~~~~~ kernel/sched/fair.c:5352:6: warning: no previous prototype for 'init_cfs_bandwidth' [-Wmissing-prototypes] 5352 | void init_cfs_bandwidth(struct cfs_bandwidth *cfs_b) {} | ^~~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/clock.o] Error 1 make[3]: *** [scripts/Makefile.build:281: kernel/sched/wait.o] Error 1 kernel/sched/fair.c:11078:6: warning: no previous prototype for 'free_fair_sched_group' [-Wmissing-prototypes] 11078 | void free_fair_sched_group(struct task_group *tg) { } | ^~~~~~~~~~~~~~~~~~~~~ kernel/sched/fair.c:11080:5: warning: no previous prototype for 'alloc_fair_sched_group' [-Wmissing-prototypes] 11080 | int alloc_fair_sched_group(struct task_group *tg, struct task_group *parent) | ^~~~~~~~~~~~~~~~~~~~~~ kernel/sched/fair.c:11085:6: warning: no previous prototype for 'online_fair_sched_group' [-Wmissing-prototypes] 11085 | void online_fair_sched_group(struct task_group *tg) { } | ^~~~~~~~~~~~~~~~~~~~~~~ kernel/sched/fair.c:11087:6: warning: no previous prototype for 'unregister_fair_sched_group' [-Wmissing-prototypes] 11087 | void unregister_fair_sched_group(struct task_group *tg) { } | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/cputime.o] Error 1 In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/idle.c:9: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/fair.o] Error 1 make[3]: *** [scripts/Makefile.build:281: kernel/sched/deadline.o] Error 1 kernel/sched/core.c:2117:6: warning: no previous prototype for 'sched_set_stop_task' [-Wmissing-prototypes] 2117 | void sched_set_stop_task(int cpu, struct task_struct *stop) | ^~~~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/loadavg.o] Error 1 kernel/sched/rt.c:253:6: warning: no previous prototype for 'free_rt_sched_group' [-Wmissing-prototypes] 253 | void free_rt_sched_group(struct task_group *tg) { } | ^~~~~~~~~~~~~~~~~~~ kernel/sched/rt.c:255:5: warning: no previous prototype for 'alloc_rt_sched_group' [-Wmissing-prototypes] 255 | int alloc_rt_sched_group(struct task_group *tg, struct task_group *parent) | ^~~~~~~~~~~~~~~~~~~~ kernel/sched/rt.c:668:6: warning: no previous prototype for 'sched_rt_bandwidth_account' [-Wmissing-prototypes] 668 | bool sched_rt_bandwidth_account(struct rt_rq *rt_rq) | ^~~~~~~~~~~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/core.o] Error 1 make[3]: *** [scripts/Makefile.build:281: kernel/sched/rt.o] Error 1 kernel/trace/trace_seq.c:142: warning: Function parameter or member 'args' not described in 'trace_seq_vprintf' kernel/trace/trace_output.c: In function 'trace_output_raw': kernel/trace/trace_output.c:321:2: warning: function 'trace_output_raw' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format] 321 | trace_seq_vprintf(s, fmt, ap); | ^~~~~~~~~~~~~~~~~ kernel/events/core.c:6490:6: warning: no previous prototype for 'perf_pmu_snapshot_aux' [-Wmissing-prototypes] 6490 | long perf_pmu_snapshot_aux(struct perf_buffer *rb, | ^~~~~~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/wait_bit.c:5: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/swait.c:5: include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/wait_bit.o] Error 1 make[3]: *** [scripts/Makefile.build:281: kernel/sched/idle.o] Error 1 In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/completion.c:14: include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:5306: warning: Function parameter or member 'ops' not described in 'ftrace_set_filter_ip' kernel/trace/ftrace.c:5306: warning: Function parameter or member 'ip' not described in 'ftrace_set_filter_ip' kernel/trace/ftrace.c:5306: warning: Function parameter or member 'remove' not described in 'ftrace_set_filter_ip' kernel/trace/ftrace.c:5306: warning: Function parameter or member 'reset' not described in 'ftrace_set_filter_ip' kernel/trace/ftrace.c:5320: warning: Function parameter or member 'ops' not described in 'ftrace_ops_set_global_filter' kernel/trace/ftrace.c:5348: warning: Function parameter or member 'ops' not described in 'ftrace_set_filter' kernel/trace/ftrace.c:5348: warning: Function parameter or member 'buf' not described in 'ftrace_set_filter' kernel/trace/ftrace.c:5348: warning: Function parameter or member 'len' not described in 'ftrace_set_filter' kernel/trace/ftrace.c:5348: warning: Function parameter or member 'reset' not described in 'ftrace_set_filter' kernel/trace/ftrace.c:5367: warning: Function parameter or member 'ops' not described in 'ftrace_set_notrace' kernel/trace/ftrace.c:5367: warning: Function parameter or member 'buf' not described in 'ftrace_set_notrace' kernel/trace/ftrace.c:5367: warning: Function parameter or member 'len' not described in 'ftrace_set_notrace' kernel/trace/ftrace.c:5367: warning: Function parameter or member 'reset' not described in 'ftrace_set_notrace' kernel/trace/ftrace.c:5382: warning: Function parameter or member 'buf' not described in 'ftrace_set_global_filter' kernel/trace/ftrace.c:5382: warning: Function parameter or member 'len' not described in 'ftrace_set_global_filter' kernel/trace/ftrace.c:5382: warning: Function parameter or member 'reset' not described in 'ftrace_set_global_filter' kernel/trace/ftrace.c:5398: warning: Function parameter or member 'buf' not described in 'ftrace_set_global_notrace' kernel/trace/ftrace.c:5398: warning: Function parameter or member 'len' not described in 'ftrace_set_global_notrace' kernel/trace/ftrace.c:5398: warning: Function parameter or member 'reset' not described in 'ftrace_set_global_notrace' kernel/trace/ftrace.c:7374: warning: Function parameter or member 'ops' not described in 'register_ftrace_function' kernel/trace/ftrace.c:7396: warning: Function parameter or member 'ops' not described in 'unregister_ftrace_function' kernel/exit.c:1714:13: warning: no previous prototype for 'abort' [-Wmissing-prototypes] 1714 | __weak void abort(void) | ^~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/cpupri.c:25: include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/trace/ring_buffer.c:1141: warning: Function parameter or member 'cpu_buffer' not described in 'rb_check_list' kernel/trace/ring_buffer.c:1141: warning: Function parameter or member 'list' not described in 'rb_check_list' make[3]: *** [scripts/Makefile.build:281: kernel/sched/swait.o] Error 1 kernel/rcu/tree.c:969: warning: Excess function parameter 'irq' description in 'rcu_nmi_enter' kernel/rcu/tree.c:3024: warning: Function parameter or member 'count' not described in 'kfree_rcu_cpu' In file included from include/linux/linkage.h:7, .. vim +/cpuidle_governor +267 include/linux/cpuidle.h 247 248 /****************************** 249 * CPUIDLE GOVERNOR INTERFACE * 250 ******************************/ 251 252 struct cpuidle_governor { 253 char name[CPUIDLE_NAME_LEN]; 254 struct list_head governor_list; 255 unsigned int rating; 256 257 int (*enable) (struct cpuidle_driver *drv, 258 struct cpuidle_device *dev); 259 void (*disable) (struct cpuidle_driver *drv, 260 struct cpuidle_device *dev); 261 262 int (*select) (struct cpuidle_driver *drv, 263 struct cpuidle_device *dev, 264 bool *stop_tick); 265 void (*reflect) (struct cpuidle_device *dev, int index); 266 }; > 267 EXPORT_SYMBOL_GPL(cpuidle_governor); 268 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org [-- Attachment #2: .config.gz --] [-- Type: application/gzip, Size: 34643 bytes --] ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] cpuidle: governor: export cpuidle_register_governor @ 2020-07-01 8:19 ` kernel test robot 0 siblings, 0 replies; 8+ messages in thread From: kernel test robot @ 2020-07-01 8:19 UTC (permalink / raw) To: kbuild-all [-- Attachment #1: Type: text/plain, Size: 31105 bytes --] Hi Lina, Thank you for the patch! Yet something to improve: [auto build test ERROR on pm/linux-next] [also build test ERROR on daniel.lezcano/clockevents/next v5.8-rc3 next-20200701] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Lina-Iyer/cpuidle-governor-export-cpuidle_register_governor/20200701-031538 base: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git linux-next config: i386-randconfig-s002-20200630 (attached as .config) compiler: gcc-9 (Debian 9.3.0-13) 9.3.0 reproduce: # apt-get install sparse # sparse version: v0.6.2-3-gfa153962-dirty # save the attached .config to linux build tree make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=i386 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@intel.com> All error/warnings (new ones prefixed by >>): In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/fair.c:23: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/core.c:9: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from kernel/rcu/update.c:587: kernel/rcu/tasks.h:405:6: warning: no previous prototype for 'rcu_tasks_postscan' [-Wmissing-prototypes] 405 | void rcu_tasks_postscan(struct list_head *hop) | ^~~~~~~~~~~~~~~~~~ kernel/rcu/tasks.h:757:6: warning: no previous prototype for 'rcu_read_unlock_trace_special' [-Wmissing-prototypes] 757 | void rcu_read_unlock_trace_special(struct task_struct *t, int nesting) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ kernel/rcu/tasks.h:1135:6: warning: no previous prototype for 'synchronize_rcu_tasks_trace' [-Wmissing-prototypes] 1135 | void synchronize_rcu_tasks_trace(void) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ In file included from kernel/rcu/update.c:587: kernel/rcu/tasks.h:1148:6: warning: no previous prototype for 'rcu_barrier_tasks_trace' [-Wmissing-prototypes] 1148 | void rcu_barrier_tasks_trace(void) | ^~~~~~~~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:305:5: warning: no previous prototype for '__register_ftrace_function' [-Wmissing-prototypes] 305 | int __register_ftrace_function(struct ftrace_ops *ops) | ^~~~~~~~~~~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:348:5: warning: no previous prototype for '__unregister_ftrace_function' [-Wmissing-prototypes] 348 | int __unregister_ftrace_function(struct ftrace_ops *ops) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ kernel/bpf/core.c:1353:12: warning: no previous prototype for 'bpf_probe_read_kernel' [-Wmissing-prototypes] 1353 | u64 __weak bpf_probe_read_kernel(void *dst, u32 size, const void *unsafe_ptr) | ^~~~~~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/wait.c:7: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from kernel/bpf/core.c:21: kernel/bpf/core.c: In function '___bpf_prog_run': include/linux/filter.h:879:3: warning: cast between incompatible function types from 'u64 (*)(u64, u64, u64, u64, u64)' {aka 'long long unsigned int (*)(long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int)'} to 'u64 (*)(u64, u64, u64, u64, u64, const struct bpf_insn *)' {aka 'long long unsigned int (*)(long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, const struct bpf_insn *)'} [-Wcast-function-type] 879 | ((u64 (*)(u64, u64, u64, u64, u64, const struct bpf_insn *)) \ | ^ kernel/bpf/core.c:1521:13: note: in expansion of macro '__bpf_call_base_args' 1521 | BPF_R0 = (__bpf_call_base_args + insn->imm)(BPF_R1, BPF_R2, | ^~~~~~~~~~~~~~~~~~~~ kernel/bpf/core.c: In function 'bpf_patch_call_args': include/linux/filter.h:879:3: warning: cast between incompatible function types from 'u64 (*)(u64, u64, u64, u64, u64)' {aka 'long long unsigned int (*)(long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int)'} to 'u64 (*)(u64, u64, u64, u64, u64, const struct bpf_insn *)' {aka 'long long unsigned int (*)(long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, long long unsigned int, const struct bpf_insn *)'} [-Wcast-function-type] 879 | ((u64 (*)(u64, u64, u64, u64, u64, const struct bpf_insn *)) \ | ^ kernel/bpf/core.c:1712:3: note: in expansion of macro '__bpf_call_base_args' 1712 | __bpf_call_base_args; | ^~~~~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/loadavg.c:9: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:3801:15: warning: no previous prototype for 'arch_ftrace_match_adjust' [-Wmissing-prototypes] 3801 | char * __weak arch_ftrace_match_adjust(char *str, const char *search) | ^~~~~~~~~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c: In function 'process_mod_list': kernel/trace/ftrace.c:4112:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] 4112 | int ret; | ^~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/clock.c:56: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c: In function 'ftrace_regex_release': kernel/trace/ftrace.c:5517:6: warning: variable 'ret' set but not used [-Wunused-but-set-variable] 5517 | int ret; | ^~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/rt.c:6: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/cputime.c:5: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/deadline.c:18: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/panic.c:85:13: warning: no previous prototype for 'panic_smp_self_stop' [-Wmissing-prototypes] 85 | void __weak panic_smp_self_stop(void) | ^~~~~~~~~~~~~~~~~~~ kernel/panic.c:95:13: warning: no previous prototype for 'nmi_panic_self_stop' [-Wmissing-prototypes] 95 | void __weak nmi_panic_self_stop(struct pt_regs *regs) | ^~~~~~~~~~~~~~~~~~~ kernel/panic.c:106:13: warning: no previous prototype for 'crash_smp_send_stop' [-Wmissing-prototypes] 106 | void __weak crash_smp_send_stop(void) | ^~~~~~~~~~~~~~~~~~~ kernel/panic.c: In function '__warn': kernel/panic.c:590:3: warning: function '__warn' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format] 590 | vprintk(args->fmt, args->args); | ^~~~~~~ kernel/panic.c: At top level: kernel/panic.c:683:24: warning: no previous prototype for '__stack_chk_fail' [-Wmissing-prototypes] 683 | __visible noinstr void __stack_chk_fail(void) | ^~~~~~~~~~~~~~~~ kernel/sched/fair.c:5352:6: warning: no previous prototype for 'init_cfs_bandwidth' [-Wmissing-prototypes] 5352 | void init_cfs_bandwidth(struct cfs_bandwidth *cfs_b) {} | ^~~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/clock.o] Error 1 make[3]: *** [scripts/Makefile.build:281: kernel/sched/wait.o] Error 1 kernel/sched/fair.c:11078:6: warning: no previous prototype for 'free_fair_sched_group' [-Wmissing-prototypes] 11078 | void free_fair_sched_group(struct task_group *tg) { } | ^~~~~~~~~~~~~~~~~~~~~ kernel/sched/fair.c:11080:5: warning: no previous prototype for 'alloc_fair_sched_group' [-Wmissing-prototypes] 11080 | int alloc_fair_sched_group(struct task_group *tg, struct task_group *parent) | ^~~~~~~~~~~~~~~~~~~~~~ kernel/sched/fair.c:11085:6: warning: no previous prototype for 'online_fair_sched_group' [-Wmissing-prototypes] 11085 | void online_fair_sched_group(struct task_group *tg) { } | ^~~~~~~~~~~~~~~~~~~~~~~ kernel/sched/fair.c:11087:6: warning: no previous prototype for 'unregister_fair_sched_group' [-Wmissing-prototypes] 11087 | void unregister_fair_sched_group(struct task_group *tg) { } | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/cputime.o] Error 1 In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/idle.c:9: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/fair.o] Error 1 make[3]: *** [scripts/Makefile.build:281: kernel/sched/deadline.o] Error 1 kernel/sched/core.c:2117:6: warning: no previous prototype for 'sched_set_stop_task' [-Wmissing-prototypes] 2117 | void sched_set_stop_task(int cpu, struct task_struct *stop) | ^~~~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/loadavg.o] Error 1 kernel/sched/rt.c:253:6: warning: no previous prototype for 'free_rt_sched_group' [-Wmissing-prototypes] 253 | void free_rt_sched_group(struct task_group *tg) { } | ^~~~~~~~~~~~~~~~~~~ kernel/sched/rt.c:255:5: warning: no previous prototype for 'alloc_rt_sched_group' [-Wmissing-prototypes] 255 | int alloc_rt_sched_group(struct task_group *tg, struct task_group *parent) | ^~~~~~~~~~~~~~~~~~~~ kernel/sched/rt.c:668:6: warning: no previous prototype for 'sched_rt_bandwidth_account' [-Wmissing-prototypes] 668 | bool sched_rt_bandwidth_account(struct rt_rq *rt_rq) | ^~~~~~~~~~~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/core.o] Error 1 make[3]: *** [scripts/Makefile.build:281: kernel/sched/rt.o] Error 1 kernel/trace/trace_seq.c:142: warning: Function parameter or member 'args' not described in 'trace_seq_vprintf' kernel/trace/trace_output.c: In function 'trace_output_raw': kernel/trace/trace_output.c:321:2: warning: function 'trace_output_raw' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format] 321 | trace_seq_vprintf(s, fmt, ap); | ^~~~~~~~~~~~~~~~~ kernel/events/core.c:6490:6: warning: no previous prototype for 'perf_pmu_snapshot_aux' [-Wmissing-prototypes] 6490 | long perf_pmu_snapshot_aux(struct perf_buffer *rb, | ^~~~~~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/wait_bit.c:5: >> include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ >> include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/swait.c:5: include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ make[3]: *** [scripts/Makefile.build:281: kernel/sched/wait_bit.o] Error 1 make[3]: *** [scripts/Makefile.build:281: kernel/sched/idle.o] Error 1 In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/completion.c:14: include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/trace/ftrace.c:5306: warning: Function parameter or member 'ops' not described in 'ftrace_set_filter_ip' kernel/trace/ftrace.c:5306: warning: Function parameter or member 'ip' not described in 'ftrace_set_filter_ip' kernel/trace/ftrace.c:5306: warning: Function parameter or member 'remove' not described in 'ftrace_set_filter_ip' kernel/trace/ftrace.c:5306: warning: Function parameter or member 'reset' not described in 'ftrace_set_filter_ip' kernel/trace/ftrace.c:5320: warning: Function parameter or member 'ops' not described in 'ftrace_ops_set_global_filter' kernel/trace/ftrace.c:5348: warning: Function parameter or member 'ops' not described in 'ftrace_set_filter' kernel/trace/ftrace.c:5348: warning: Function parameter or member 'buf' not described in 'ftrace_set_filter' kernel/trace/ftrace.c:5348: warning: Function parameter or member 'len' not described in 'ftrace_set_filter' kernel/trace/ftrace.c:5348: warning: Function parameter or member 'reset' not described in 'ftrace_set_filter' kernel/trace/ftrace.c:5367: warning: Function parameter or member 'ops' not described in 'ftrace_set_notrace' kernel/trace/ftrace.c:5367: warning: Function parameter or member 'buf' not described in 'ftrace_set_notrace' kernel/trace/ftrace.c:5367: warning: Function parameter or member 'len' not described in 'ftrace_set_notrace' kernel/trace/ftrace.c:5367: warning: Function parameter or member 'reset' not described in 'ftrace_set_notrace' kernel/trace/ftrace.c:5382: warning: Function parameter or member 'buf' not described in 'ftrace_set_global_filter' kernel/trace/ftrace.c:5382: warning: Function parameter or member 'len' not described in 'ftrace_set_global_filter' kernel/trace/ftrace.c:5382: warning: Function parameter or member 'reset' not described in 'ftrace_set_global_filter' kernel/trace/ftrace.c:5398: warning: Function parameter or member 'buf' not described in 'ftrace_set_global_notrace' kernel/trace/ftrace.c:5398: warning: Function parameter or member 'len' not described in 'ftrace_set_global_notrace' kernel/trace/ftrace.c:5398: warning: Function parameter or member 'reset' not described in 'ftrace_set_global_notrace' kernel/trace/ftrace.c:7374: warning: Function parameter or member 'ops' not described in 'register_ftrace_function' kernel/trace/ftrace.c:7396: warning: Function parameter or member 'ops' not described in 'unregister_ftrace_function' kernel/exit.c:1714:13: warning: no previous prototype for 'abort' [-Wmissing-prototypes] 1714 | __weak void abort(void) | ^~~~~ In file included from include/linux/linkage.h:7, from include/linux/kernel.h:8, from arch/x86/include/asm/percpu.h:45, from arch/x86/include/asm/current.h:6, from include/linux/sched.h:12, from kernel/sched/sched.h:5, from kernel/sched/cpupri.c:25: include/linux/cpuidle.h:267:19: error: 'cpuidle_governor' undeclared here (not in a function) 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~ include/linux/export.h:98:16: note: in definition of macro '___EXPORT_SYMBOL' 98 | extern typeof(sym) sym; \ | ^~~ include/linux/export.h:155:34: note: in expansion of macro '__EXPORT_SYMBOL' 155 | #define _EXPORT_SYMBOL(sym, sec) __EXPORT_SYMBOL(sym, sec, "") | ^~~~~~~~~~~~~~~ include/linux/export.h:159:33: note: in expansion of macro '_EXPORT_SYMBOL' 159 | #define EXPORT_SYMBOL_GPL(sym) _EXPORT_SYMBOL(sym, "_gpl") | ^~~~~~~~~~~~~~ include/linux/cpuidle.h:267:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL' 267 | EXPORT_SYMBOL_GPL(cpuidle_governor); | ^~~~~~~~~~~~~~~~~ kernel/trace/ring_buffer.c:1141: warning: Function parameter or member 'cpu_buffer' not described in 'rb_check_list' kernel/trace/ring_buffer.c:1141: warning: Function parameter or member 'list' not described in 'rb_check_list' make[3]: *** [scripts/Makefile.build:281: kernel/sched/swait.o] Error 1 kernel/rcu/tree.c:969: warning: Excess function parameter 'irq' description in 'rcu_nmi_enter' kernel/rcu/tree.c:3024: warning: Function parameter or member 'count' not described in 'kfree_rcu_cpu' In file included from include/linux/linkage.h:7, .. vim +/cpuidle_governor +267 include/linux/cpuidle.h 247 248 /****************************** 249 * CPUIDLE GOVERNOR INTERFACE * 250 ******************************/ 251 252 struct cpuidle_governor { 253 char name[CPUIDLE_NAME_LEN]; 254 struct list_head governor_list; 255 unsigned int rating; 256 257 int (*enable) (struct cpuidle_driver *drv, 258 struct cpuidle_device *dev); 259 void (*disable) (struct cpuidle_driver *drv, 260 struct cpuidle_device *dev); 261 262 int (*select) (struct cpuidle_driver *drv, 263 struct cpuidle_device *dev, 264 bool *stop_tick); 265 void (*reflect) (struct cpuidle_device *dev, int index); 266 }; > 267 EXPORT_SYMBOL_GPL(cpuidle_governor); 268 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org [-- Attachment #2: config.gz --] [-- Type: application/gzip, Size: 34643 bytes --] ^ permalink raw reply [flat|nested] 8+ messages in thread
* [PATCH] cpuidle: governor: export cpuidle_register_governor
@ 2020-09-02 20:57 Lina Iyer
2020-09-03 10:35 ` Daniel Lezcano
0 siblings, 1 reply; 8+ messages in thread
From: Lina Iyer @ 2020-09-02 20:57 UTC (permalink / raw)
To: rjw, daniel.lezcano; +Cc: linux-pm, linux-arm-msm, Lina Iyer
Commit 83788c0caed3 ("cpuidle: remove unused exports") removed
capability of registering cpuidle governors, which was unused at that
time. By exporting the symbol, let's allow platform specific modules to
register cpuidle governors.
Signed-off-by: Lina Iyer <ilina@codeaurora.org>
---
drivers/cpuidle/governor.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/cpuidle/governor.c b/drivers/cpuidle/governor.c
index 29acaf48e575..480ec58cffa9 100644
--- a/drivers/cpuidle/governor.c
+++ b/drivers/cpuidle/governor.c
@@ -102,6 +102,7 @@ int cpuidle_register_governor(struct cpuidle_governor *gov)
return ret;
}
+EXPORT_SYMBOL_GPL(cpuidle_register_governor);
/**
* cpuidle_governor_latency_req - Compute a latency constraint for CPU
--
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project
^ permalink raw reply related [flat|nested] 8+ messages in thread* Re: [PATCH] cpuidle: governor: export cpuidle_register_governor 2020-09-02 20:57 Lina Iyer @ 2020-09-03 10:35 ` Daniel Lezcano 2020-09-03 15:23 ` Lina Iyer 0 siblings, 1 reply; 8+ messages in thread From: Daniel Lezcano @ 2020-09-03 10:35 UTC (permalink / raw) To: Lina Iyer, rjw; +Cc: linux-pm, linux-arm-msm On 02/09/2020 22:57, Lina Iyer wrote: > Commit 83788c0caed3 ("cpuidle: remove unused exports") removed > capability of registering cpuidle governors, which was unused at that > time. By exporting the symbol, let's allow platform specific modules to > register cpuidle governors. That would make sense as that follows the same pattern than the cpufreq framework. However, the unregister part is missing. > Signed-off-by: Lina Iyer <ilina@codeaurora.org> > --- > drivers/cpuidle/governor.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/cpuidle/governor.c b/drivers/cpuidle/governor.c > index 29acaf48e575..480ec58cffa9 100644 > --- a/drivers/cpuidle/governor.c > +++ b/drivers/cpuidle/governor.c > @@ -102,6 +102,7 @@ int cpuidle_register_governor(struct cpuidle_governor *gov) > > return ret; > } > +EXPORT_SYMBOL_GPL(cpuidle_register_governor); > > /** > * cpuidle_governor_latency_req - Compute a latency constraint for CPU > -- <http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook | <http://twitter.com/#!/linaroorg> Twitter | <http://www.linaro.org/linaro-blog/> Blog ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] cpuidle: governor: export cpuidle_register_governor 2020-09-03 10:35 ` Daniel Lezcano @ 2020-09-03 15:23 ` Lina Iyer 2020-09-03 15:50 ` Lina Iyer 0 siblings, 1 reply; 8+ messages in thread From: Lina Iyer @ 2020-09-03 15:23 UTC (permalink / raw) To: Daniel Lezcano; +Cc: rjw, linux-pm, linux-arm-msm On Thu, Sep 03 2020 at 04:35 -0600, Daniel Lezcano wrote: >On 02/09/2020 22:57, Lina Iyer wrote: >> Commit 83788c0caed3 ("cpuidle: remove unused exports") removed >> capability of registering cpuidle governors, which was unused at that >> time. By exporting the symbol, let's allow platform specific modules to >> register cpuidle governors. > >That would make sense as that follows the same pattern than the cpufreq >framework. However, the unregister part is missing. > Sure, let me add that too and repost. --Lina >> Signed-off-by: Lina Iyer <ilina@codeaurora.org> >> --- >> drivers/cpuidle/governor.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/drivers/cpuidle/governor.c b/drivers/cpuidle/governor.c >> index 29acaf48e575..480ec58cffa9 100644 >> --- a/drivers/cpuidle/governor.c >> +++ b/drivers/cpuidle/governor.c >> @@ -102,6 +102,7 @@ int cpuidle_register_governor(struct cpuidle_governor *gov) >> >> return ret; >> } >> +EXPORT_SYMBOL_GPL(cpuidle_register_governor); >> >> /** >> * cpuidle_governor_latency_req - Compute a latency constraint for CPU >> > > >-- ><http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs > >Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook | ><http://twitter.com/#!/linaroorg> Twitter | ><http://www.linaro.org/linaro-blog/> Blog ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] cpuidle: governor: export cpuidle_register_governor 2020-09-03 15:23 ` Lina Iyer @ 2020-09-03 15:50 ` Lina Iyer 0 siblings, 0 replies; 8+ messages in thread From: Lina Iyer @ 2020-09-03 15:50 UTC (permalink / raw) To: Daniel Lezcano; +Cc: rjw, linux-pm, linux-arm-msm On Thu, Sep 03 2020 at 09:23 -0600, Lina Iyer wrote: >On Thu, Sep 03 2020 at 04:35 -0600, Daniel Lezcano wrote: >>On 02/09/2020 22:57, Lina Iyer wrote: >>>Commit 83788c0caed3 ("cpuidle: remove unused exports") removed >>>capability of registering cpuidle governors, which was unused at that >>>time. By exporting the symbol, let's allow platform specific modules to >>>register cpuidle governors. >> >>That would make sense as that follows the same pattern than the cpufreq >>framework. However, the unregister part is missing. >> >Sure, let me add that too and repost. > Looks like there isn't any call to unregister a governor, which seems fair. Also, what do you think about exporting cpuidle_governor_latency_req()? This could prove quite useful for a governor. I could add that in a repost. >--Lina > >>>Signed-off-by: Lina Iyer <ilina@codeaurora.org> >>>--- >>> drivers/cpuidle/governor.c | 1 + >>> 1 file changed, 1 insertion(+) >>> >>>diff --git a/drivers/cpuidle/governor.c b/drivers/cpuidle/governor.c >>>index 29acaf48e575..480ec58cffa9 100644 >>>--- a/drivers/cpuidle/governor.c >>>+++ b/drivers/cpuidle/governor.c >>>@@ -102,6 +102,7 @@ int cpuidle_register_governor(struct cpuidle_governor *gov) >>> >>> return ret; >>> } >>>+EXPORT_SYMBOL_GPL(cpuidle_register_governor); >>> >>> /** >>> * cpuidle_governor_latency_req - Compute a latency constraint for CPU >>> >> >> >>-- >><http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs >> >>Follow Linaro: <http://www.facebook.com/pages/Linaro> Facebook | >><http://twitter.com/#!/linaroorg> Twitter | >><http://www.linaro.org/linaro-blog/> Blog ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2020-09-03 15:50 UTC | newest] Thread overview: 8+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2020-06-30 19:13 [PATCH] cpuidle: governor: export cpuidle_register_governor Lina Iyer 2020-06-30 20:26 ` Lina Iyer 2020-07-01 8:19 ` kernel test robot 2020-07-01 8:19 ` kernel test robot -- strict thread matches above, loose matches on Subject: below -- 2020-09-02 20:57 Lina Iyer 2020-09-03 10:35 ` Daniel Lezcano 2020-09-03 15:23 ` Lina Iyer 2020-09-03 15:50 ` Lina Iyer
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.