History

kernel: delete __cpuinit usage from all core kernel files

The __cpuinit type of throwaway sections might have made sense some time ago when RAM was more constrained, but now the savings do not offset the cost and complications. For example, the fix in commit 5e427ec2d0 ("x86: Fix bit corruption at CPU resume time") is a good example of the nasty type of bugs that can be created with improper use of the various __init prefixes. After a discussion on LKML[1] it was decided that cpuinit should go the way of devinit and be phased out. Once all the users are gone, we can then finally remove the macros themselves from linux/init.h. This removes all the uses of the __cpuinit macros from C files in the core kernel directories (kernel, init, lib, mm, and include) that don't really have a specific maintainer. [1] https://lkml.org/lkml/2013/5/20/589

Paul Gortmaker committed 13 years ago

Commit 0db06281 parent 49fb4c627 files · +62 −59Browse files

Showing the changes to kernel/workqueue.c (1 of 27 files). Show all

Unified · Split

kernel/workqueue.c+2−2
@@ -4644,7 +4644,7 @@ static void restore_unbound_workers_cpumask(struct worker_pool *pool, int cpu) · 4643 unmodified lines
46444644 * Workqueues should be brought up before normal priority CPU notifiers.
46454645 * This will be registered high priority CPU notifier.
46464646 */
4647−static int __cpuinit workqueue_cpu_up_callback(struct notifier_block *nfb,
4647+static int workqueue_cpu_up_callback(struct notifier_block *nfb,
46484648 unsigned long action,
46494649 void *hcpu)
46504650 {
@@ -4697,7 +4697,7 @@ static int __cpuinit workqueue_cpu_up_callback(struct notifier_block *nfb, · 46 unmodified lines
46974697 * Workqueues should be brought down after normal priority CPU notifiers.
46984698 * This will be registered as low priority CPU notifier.
46994699 */
4700−static int __cpuinit workqueue_cpu_down_callback(struct notifier_block *nfb,
4700+static int workqueue_cpu_down_callback(struct notifier_block *nfb,
47014701 unsigned long action,
47024702 void *hcpu)
47034703 {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t