mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH 0/2] cpu: __ref cleanups
@ 2015-07-19 18:06 Mathias Krause
  2015-07-19 18:06 ` [PATCH 1/2] cpu: Remove bogus __ref annotation of cpu_subsys_online() Mathias Krause
  2015-07-19 18:06 ` [PATCH 2/2] kernel, cpu: Remove bogus __ref annotations Mathias Krause
  0 siblings, 2 replies; 3+ messages in thread
From: Mathias Krause @ 2015-07-19 18:06 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, linux-kernel,
	Mathias Krause, Paul Gortmaker

Hi Greg,

this series removes a few bogus __ref annotations from the cpu code.
They are, apparently, left-overs from the __cpuinit cleanup that has
happened during the creation of v3.11.

Patch 1 is clearly yours but I'm uncertain through which tree the second
one should go. I cc'ed the x86 maintainers, just in case...

Please apply or tell me where to send to the patches to instead.

Thanks,

Mathias Krause (2):
  cpu: Remove bogus __ref annotation of cpu_subsys_online()
  kernel, cpu: Remove bogus __ref annotations

 drivers/base/cpu.c |    2 +-
 kernel/cpu.c       |   16 ++++++++--------
 2 files changed, 9 insertions(+), 9 deletions(-)

-- 
1.7.10.4


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH 1/2] cpu: Remove bogus __ref annotation of cpu_subsys_online()
  2015-07-19 18:06 [PATCH 0/2] cpu: __ref cleanups Mathias Krause
@ 2015-07-19 18:06 ` Mathias Krause
  2015-07-19 18:06 ` [PATCH 2/2] kernel, cpu: Remove bogus __ref annotations Mathias Krause
  1 sibling, 0 replies; 3+ messages in thread
From: Mathias Krause @ 2015-07-19 18:06 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, linux-kernel,
	Mathias Krause, Paul Gortmaker

In commit 0db0628d9012 ("kernel: delete __cpuinit usage from all core
kernel files") cpu_up() lost its __cpuinit annotation, vanishing the
need for cpu_subsys_online() to have a __ref annotation. Just drop it
to be able to catch real section mismatches in the future.

Signed-off-by: Mathias Krause <minipli@googlemail.com>
Cc: Paul Gortmaker <paul.gortmaker@windriver.com>
---
 drivers/base/cpu.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/base/cpu.c b/drivers/base/cpu.c
index 78720e706176..91bbb1959d8d 100644
--- a/drivers/base/cpu.c
+++ b/drivers/base/cpu.c
@@ -41,7 +41,7 @@ static void change_cpu_under_node(struct cpu *cpu,
 	cpu->node_id = to_nid;
 }
 
-static int __ref cpu_subsys_online(struct device *dev)
+static int cpu_subsys_online(struct device *dev)
 {
 	struct cpu *cpu = container_of(dev, struct cpu, dev);
 	int cpuid = dev->id;
-- 
1.7.10.4


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [PATCH 2/2] kernel, cpu: Remove bogus __ref annotations
  2015-07-19 18:06 [PATCH 0/2] cpu: __ref cleanups Mathias Krause
  2015-07-19 18:06 ` [PATCH 1/2] cpu: Remove bogus __ref annotation of cpu_subsys_online() Mathias Krause
@ 2015-07-19 18:06 ` Mathias Krause
  1 sibling, 0 replies; 3+ messages in thread
From: Mathias Krause @ 2015-07-19 18:06 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Thomas Gleixner, Ingo Molnar, H. Peter Anvin, linux-kernel,
	Mathias Krause, Paul Gortmaker, Linus Torvalds

cpu_chain lost its __cpuinitdata annotation long ago in commit
5c113fbeed7a ("fix cpu_chain section mismatch..."). This and the global
__cpuinit annotation drop in v3.11 vanished the need to mark all users,
including transitive ones, with the __ref annotation. Just get rid of it
to not wrongly hide section mismatches.

Signed-off-by: Mathias Krause <minipli@googlemail.com>
Cc: Paul Gortmaker <paul.gortmaker@windriver.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
---
 kernel/cpu.c |   16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)

diff --git a/kernel/cpu.c b/kernel/cpu.c
index 5644ec5582b9..a5f2165b2dc4 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -205,7 +205,7 @@ void cpu_hotplug_enable(void)
 #endif	/* CONFIG_HOTPLUG_CPU */
 
 /* Need to know about CPUs going up/down? */
-int __ref register_cpu_notifier(struct notifier_block *nb)
+int register_cpu_notifier(struct notifier_block *nb)
 {
 	int ret;
 	cpu_maps_update_begin();
@@ -214,7 +214,7 @@ int __ref register_cpu_notifier(struct notifier_block *nb)
 	return ret;
 }
 
-int __ref __register_cpu_notifier(struct notifier_block *nb)
+int __register_cpu_notifier(struct notifier_block *nb)
 {
 	return raw_notifier_chain_register(&cpu_chain, nb);
 }
@@ -244,7 +244,7 @@ static void cpu_notify_nofail(unsigned long val, void *v)
 EXPORT_SYMBOL(register_cpu_notifier);
 EXPORT_SYMBOL(__register_cpu_notifier);
 
-void __ref unregister_cpu_notifier(struct notifier_block *nb)
+void unregister_cpu_notifier(struct notifier_block *nb)
 {
 	cpu_maps_update_begin();
 	raw_notifier_chain_unregister(&cpu_chain, nb);
@@ -252,7 +252,7 @@ void __ref unregister_cpu_notifier(struct notifier_block *nb)
 }
 EXPORT_SYMBOL(unregister_cpu_notifier);
 
-void __ref __unregister_cpu_notifier(struct notifier_block *nb)
+void __unregister_cpu_notifier(struct notifier_block *nb)
 {
 	raw_notifier_chain_unregister(&cpu_chain, nb);
 }
@@ -329,7 +329,7 @@ struct take_cpu_down_param {
 };
 
 /* Take this CPU down. */
-static int __ref take_cpu_down(void *_param)
+static int take_cpu_down(void *_param)
 {
 	struct take_cpu_down_param *param = _param;
 	int err;
@@ -348,7 +348,7 @@ static int __ref take_cpu_down(void *_param)
 }
 
 /* Requires cpu_add_remove_lock to be held */
-static int __ref _cpu_down(unsigned int cpu, int tasks_frozen)
+static int _cpu_down(unsigned int cpu, int tasks_frozen)
 {
 	int err, nr_calls = 0;
 	void *hcpu = (void *)(long)cpu;
@@ -442,7 +442,7 @@ out_release:
 	return err;
 }
 
-int __ref cpu_down(unsigned int cpu)
+int cpu_down(unsigned int cpu)
 {
 	int err;
 
@@ -627,7 +627,7 @@ void __weak arch_enable_nonboot_cpus_end(void)
 {
 }
 
-void __ref enable_nonboot_cpus(void)
+void enable_nonboot_cpus(void)
 {
 	int cpu, error;
 
-- 
1.7.10.4


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-07-19 18:06 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-07-19 18:06 [PATCH 0/2] cpu: __ref cleanups Mathias Krause
2015-07-19 18:06 ` [PATCH 1/2] cpu: Remove bogus __ref annotation of cpu_subsys_online() Mathias Krause
2015-07-19 18:06 ` [PATCH 2/2] kernel, cpu: Remove bogus __ref annotations Mathias Krause

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®