diff options
Diffstat (limited to 'kernel')
82 files changed, 225 insertions, 190 deletions
diff --git a/kernel/async.c b/kernel/async.c index 4c2843c0043e..80b74b88fefe 100644 --- a/kernel/async.c +++ b/kernel/async.c | |||
| @@ -51,7 +51,7 @@ asynchronous and synchronous parts of the kernel. | |||
| 51 | #include <linux/async.h> | 51 | #include <linux/async.h> |
| 52 | #include <linux/atomic.h> | 52 | #include <linux/atomic.h> |
| 53 | #include <linux/ktime.h> | 53 | #include <linux/ktime.h> |
| 54 | #include <linux/module.h> | 54 | #include <linux/export.h> |
| 55 | #include <linux/wait.h> | 55 | #include <linux/wait.h> |
| 56 | #include <linux/sched.h> | 56 | #include <linux/sched.h> |
| 57 | #include <linux/slab.h> | 57 | #include <linux/slab.h> |
diff --git a/kernel/audit.c b/kernel/audit.c index 0a1355ca3d79..09fae2677a45 100644 --- a/kernel/audit.c +++ b/kernel/audit.c | |||
| @@ -45,7 +45,7 @@ | |||
| 45 | #include <asm/types.h> | 45 | #include <asm/types.h> |
| 46 | #include <linux/atomic.h> | 46 | #include <linux/atomic.h> |
| 47 | #include <linux/mm.h> | 47 | #include <linux/mm.h> |
| 48 | #include <linux/module.h> | 48 | #include <linux/export.h> |
| 49 | #include <linux/slab.h> | 49 | #include <linux/slab.h> |
| 50 | #include <linux/err.h> | 50 | #include <linux/err.h> |
| 51 | #include <linux/kthread.h> | 51 | #include <linux/kthread.h> |
diff --git a/kernel/auditsc.c b/kernel/auditsc.c index ce4b054acee5..47b7fc1ea893 100644 --- a/kernel/auditsc.c +++ b/kernel/auditsc.c | |||
| @@ -48,7 +48,7 @@ | |||
| 48 | #include <linux/fs.h> | 48 | #include <linux/fs.h> |
| 49 | #include <linux/namei.h> | 49 | #include <linux/namei.h> |
| 50 | #include <linux/mm.h> | 50 | #include <linux/mm.h> |
| 51 | #include <linux/module.h> | 51 | #include <linux/export.h> |
| 52 | #include <linux/slab.h> | 52 | #include <linux/slab.h> |
| 53 | #include <linux/mount.h> | 53 | #include <linux/mount.h> |
| 54 | #include <linux/socket.h> | 54 | #include <linux/socket.h> |
diff --git a/kernel/capability.c b/kernel/capability.c index 283c529f8b1c..b463871a4e69 100644 --- a/kernel/capability.c +++ b/kernel/capability.c | |||
| @@ -10,7 +10,7 @@ | |||
| 10 | #include <linux/audit.h> | 10 | #include <linux/audit.h> |
| 11 | #include <linux/capability.h> | 11 | #include <linux/capability.h> |
| 12 | #include <linux/mm.h> | 12 | #include <linux/mm.h> |
| 13 | #include <linux/module.h> | 13 | #include <linux/export.h> |
| 14 | #include <linux/security.h> | 14 | #include <linux/security.h> |
| 15 | #include <linux/syscalls.h> | 15 | #include <linux/syscalls.h> |
| 16 | #include <linux/pid_namespace.h> | 16 | #include <linux/pid_namespace.h> |
diff --git a/kernel/cgroup.c b/kernel/cgroup.c index 453100a4159d..d9d5648f3cdc 100644 --- a/kernel/cgroup.c +++ b/kernel/cgroup.c | |||
| @@ -2027,7 +2027,7 @@ int cgroup_attach_proc(struct cgroup *cgrp, struct task_struct *leader) | |||
| 2027 | goto out_free_group_list; | 2027 | goto out_free_group_list; |
| 2028 | 2028 | ||
| 2029 | /* prevent changes to the threadgroup list while we take a snapshot. */ | 2029 | /* prevent changes to the threadgroup list while we take a snapshot. */ |
| 2030 | rcu_read_lock(); | 2030 | read_lock(&tasklist_lock); |
| 2031 | if (!thread_group_leader(leader)) { | 2031 | if (!thread_group_leader(leader)) { |
| 2032 | /* | 2032 | /* |
| 2033 | * a race with de_thread from another thread's exec() may strip | 2033 | * a race with de_thread from another thread's exec() may strip |
| @@ -2036,7 +2036,7 @@ int cgroup_attach_proc(struct cgroup *cgrp, struct task_struct *leader) | |||
| 2036 | * throw this task away and try again (from cgroup_procs_write); | 2036 | * throw this task away and try again (from cgroup_procs_write); |
| 2037 | * this is "double-double-toil-and-trouble-check locking". | 2037 | * this is "double-double-toil-and-trouble-check locking". |
| 2038 | */ | 2038 | */ |
| 2039 | rcu_read_unlock(); | 2039 | read_unlock(&tasklist_lock); |
| 2040 | retval = -EAGAIN; | 2040 | retval = -EAGAIN; |
| 2041 | goto out_free_group_list; | 2041 | goto out_free_group_list; |
| 2042 | } | 2042 | } |
| @@ -2057,7 +2057,7 @@ int cgroup_attach_proc(struct cgroup *cgrp, struct task_struct *leader) | |||
| 2057 | } while_each_thread(leader, tsk); | 2057 | } while_each_thread(leader, tsk); |
| 2058 | /* remember the number of threads in the array for later. */ | 2058 | /* remember the number of threads in the array for later. */ |
| 2059 | group_size = i; | 2059 | group_size = i; |
| 2060 | rcu_read_unlock(); | 2060 | read_unlock(&tasklist_lock); |
| 2061 | 2061 | ||
| 2062 | /* | 2062 | /* |
| 2063 | * step 1: check that we can legitimately attach to the cgroup. | 2063 | * step 1: check that we can legitimately attach to the cgroup. |
| @@ -2135,14 +2135,17 @@ int cgroup_attach_proc(struct cgroup *cgrp, struct task_struct *leader) | |||
| 2135 | oldcgrp = task_cgroup_from_root(tsk, root); | 2135 | oldcgrp = task_cgroup_from_root(tsk, root); |
| 2136 | if (cgrp == oldcgrp) | 2136 | if (cgrp == oldcgrp) |
| 2137 | continue; | 2137 | continue; |
| 2138 | /* attach each task to each subsystem */ | ||
| 2139 | for_each_subsys(root, ss) { | ||
| 2140 | if (ss->attach_task) | ||
| 2141 | ss->attach_task(cgrp, tsk); | ||
| 2142 | } | ||
| 2143 | /* if the thread is PF_EXITING, it can just get skipped. */ | 2138 | /* if the thread is PF_EXITING, it can just get skipped. */ |
| 2144 | retval = cgroup_task_migrate(cgrp, oldcgrp, tsk, true); | 2139 | retval = cgroup_task_migrate(cgrp, oldcgrp, tsk, true); |
| 2145 | BUG_ON(retval != 0 && retval != -ESRCH); | 2140 | if (retval == 0) { |
| 2141 | /* attach each task to each subsystem */ | ||
| 2142 | for_each_subsys(root, ss) { | ||
| 2143 | if (ss->attach_task) | ||
| 2144 | ss->attach_task(cgrp, tsk); | ||
| 2145 | } | ||
| 2146 | } else { | ||
| 2147 | BUG_ON(retval != -ESRCH); | ||
| 2148 | } | ||
| 2146 | } | 2149 | } |
| 2147 | /* nothing is sensitive to fork() after this point. */ | 2150 | /* nothing is sensitive to fork() after this point. */ |
| 2148 | 2151 | ||
| @@ -4880,9 +4883,9 @@ void free_css_id(struct cgroup_subsys *ss, struct cgroup_subsys_state *css) | |||
| 4880 | 4883 | ||
| 4881 | rcu_assign_pointer(id->css, NULL); | 4884 | rcu_assign_pointer(id->css, NULL); |
| 4882 | rcu_assign_pointer(css->id, NULL); | 4885 | rcu_assign_pointer(css->id, NULL); |
| 4883 | spin_lock(&ss->id_lock); | 4886 | write_lock(&ss->id_lock); |
| 4884 | idr_remove(&ss->idr, id->id); | 4887 | idr_remove(&ss->idr, id->id); |
| 4885 | spin_unlock(&ss->id_lock); | 4888 | write_unlock(&ss->id_lock); |
| 4886 | kfree_rcu(id, rcu_head); | 4889 | kfree_rcu(id, rcu_head); |
| 4887 | } | 4890 | } |
| 4888 | EXPORT_SYMBOL_GPL(free_css_id); | 4891 | EXPORT_SYMBOL_GPL(free_css_id); |
| @@ -4908,10 +4911,10 @@ static struct css_id *get_new_cssid(struct cgroup_subsys *ss, int depth) | |||
| 4908 | error = -ENOMEM; | 4911 | error = -ENOMEM; |
| 4909 | goto err_out; | 4912 | goto err_out; |
| 4910 | } | 4913 | } |
| 4911 | spin_lock(&ss->id_lock); | 4914 | write_lock(&ss->id_lock); |
| 4912 | /* Don't use 0. allocates an ID of 1-65535 */ | 4915 | /* Don't use 0. allocates an ID of 1-65535 */ |
| 4913 | error = idr_get_new_above(&ss->idr, newid, 1, &myid); | 4916 | error = idr_get_new_above(&ss->idr, newid, 1, &myid); |
| 4914 | spin_unlock(&ss->id_lock); | 4917 | write_unlock(&ss->id_lock); |
| 4915 | 4918 | ||
| 4916 | /* Returns error when there are no free spaces for new ID.*/ | 4919 | /* Returns error when there are no free spaces for new ID.*/ |
| 4917 | if (error) { | 4920 | if (error) { |
| @@ -4926,9 +4929,9 @@ static struct css_id *get_new_cssid(struct cgroup_subsys *ss, int depth) | |||
| 4926 | return newid; | 4929 | return newid; |
| 4927 | remove_idr: | 4930 | remove_idr: |
| 4928 | error = -ENOSPC; | 4931 | error = -ENOSPC; |
| 4929 | spin_lock(&ss->id_lock); | 4932 | write_lock(&ss->id_lock); |
| 4930 | idr_remove(&ss->idr, myid); | 4933 | idr_remove(&ss->idr, myid); |
| 4931 | spin_unlock(&ss->id_lock); | 4934 | write_unlock(&ss->id_lock); |
| 4932 | err_out: | 4935 | err_out: |
| 4933 | kfree(newid); | 4936 | kfree(newid); |
| 4934 | return ERR_PTR(error); | 4937 | return ERR_PTR(error); |
| @@ -4940,7 +4943,7 @@ static int __init_or_module cgroup_init_idr(struct cgroup_subsys *ss, | |||
| 4940 | { | 4943 | { |
| 4941 | struct css_id *newid; | 4944 | struct css_id *newid; |
| 4942 | 4945 | ||
| 4943 | spin_lock_init(&ss->id_lock); | 4946 | rwlock_init(&ss->id_lock); |
| 4944 | idr_init(&ss->idr); | 4947 | idr_init(&ss->idr); |
| 4945 | 4948 | ||
| 4946 | newid = get_new_cssid(ss, 0); | 4949 | newid = get_new_cssid(ss, 0); |
| @@ -5035,9 +5038,9 @@ css_get_next(struct cgroup_subsys *ss, int id, | |||
| 5035 | * scan next entry from bitmap(tree), tmpid is updated after | 5038 | * scan next entry from bitmap(tree), tmpid is updated after |
| 5036 | * idr_get_next(). | 5039 | * idr_get_next(). |
| 5037 | */ | 5040 | */ |
| 5038 | spin_lock(&ss->id_lock); | 5041 | read_lock(&ss->id_lock); |
| 5039 | tmp = idr_get_next(&ss->idr, &tmpid); | 5042 | tmp = idr_get_next(&ss->idr, &tmpid); |
| 5040 | spin_unlock(&ss->id_lock); | 5043 | read_unlock(&ss->id_lock); |
| 5041 | 5044 | ||
| 5042 | if (!tmp) | 5045 | if (!tmp) |
| 5043 | break; | 5046 | break; |
diff --git a/kernel/cgroup_freezer.c b/kernel/cgroup_freezer.c index e691818d7e45..5e828a2ca8e6 100644 --- a/kernel/cgroup_freezer.c +++ b/kernel/cgroup_freezer.c | |||
| @@ -14,7 +14,7 @@ | |||
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
| 15 | */ | 15 | */ |
| 16 | 16 | ||
| 17 | #include <linux/module.h> | 17 | #include <linux/export.h> |
| 18 | #include <linux/slab.h> | 18 | #include <linux/slab.h> |
| 19 | #include <linux/cgroup.h> | 19 | #include <linux/cgroup.h> |
| 20 | #include <linux/fs.h> | 20 | #include <linux/fs.h> |
diff --git a/kernel/compat.c b/kernel/compat.c index e2435ee9993a..f346cedfe24d 100644 --- a/kernel/compat.c +++ b/kernel/compat.c | |||
| @@ -21,6 +21,7 @@ | |||
| 21 | #include <linux/unistd.h> | 21 | #include <linux/unistd.h> |
| 22 | #include <linux/security.h> | 22 | #include <linux/security.h> |
| 23 | #include <linux/timex.h> | 23 | #include <linux/timex.h> |
| 24 | #include <linux/export.h> | ||
| 24 | #include <linux/migrate.h> | 25 | #include <linux/migrate.h> |
| 25 | #include <linux/posix-timers.h> | 26 | #include <linux/posix-timers.h> |
| 26 | #include <linux/times.h> | 27 | #include <linux/times.h> |
diff --git a/kernel/cpu.c b/kernel/cpu.c index 12b7458f23b1..563f13609470 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c | |||
| @@ -10,11 +10,12 @@ | |||
| 10 | #include <linux/sched.h> | 10 | #include <linux/sched.h> |
| 11 | #include <linux/unistd.h> | 11 | #include <linux/unistd.h> |
| 12 | #include <linux/cpu.h> | 12 | #include <linux/cpu.h> |
| 13 | #include <linux/module.h> | 13 | #include <linux/export.h> |
| 14 | #include <linux/kthread.h> | 14 | #include <linux/kthread.h> |
| 15 | #include <linux/stop_machine.h> | 15 | #include <linux/stop_machine.h> |
| 16 | #include <linux/mutex.h> | 16 | #include <linux/mutex.h> |
| 17 | #include <linux/gfp.h> | 17 | #include <linux/gfp.h> |
| 18 | #include <linux/suspend.h> | ||
| 18 | 19 | ||
| 19 | #ifdef CONFIG_SMP | 20 | #ifdef CONFIG_SMP |
| 20 | /* Serializes the updates to cpu_online_mask, cpu_present_mask */ | 21 | /* Serializes the updates to cpu_online_mask, cpu_present_mask */ |
| @@ -476,6 +477,79 @@ static int alloc_frozen_cpus(void) | |||
| 476 | return 0; | 477 | return 0; |
| 477 | } | 478 | } |
| 478 | core_initcall(alloc_frozen_cpus); | 479 | core_initcall(alloc_frozen_cpus); |
| 480 | |||
| 481 | /* | ||
| 482 | * Prevent regular CPU hotplug from racing with the freezer, by disabling CPU | ||
| 483 | * hotplug when tasks are about to be frozen. Also, don't allow the freezer | ||
| 484 | * to continue until any currently running CPU hotplug operation gets | ||
| 485 | * completed. | ||
| 486 | * To modify the 'cpu_hotplug_disabled' flag, we need to acquire the | ||
| 487 | * 'cpu_add_remove_lock'. And this same lock is also taken by the regular | ||
| 488 | * CPU hotplug path and released only after it is complete. Thus, we | ||
| 489 | * (and hence the freezer) will block here until any currently running CPU | ||
| 490 | * hotplug operation gets completed. | ||
| 491 | */ | ||
| 492 | void cpu_hotplug_disable_before_freeze(void) | ||
| 493 | { | ||
| 494 | cpu_maps_update_begin(); | ||
| 495 | cpu_hotplug_disabled = 1; | ||
| 496 | cpu_maps_update_done(); | ||
| 497 | } | ||
| 498 | |||
| 499 | |||
| 500 | /* | ||
| 501 | * When tasks have been thawed, re-enable regular CPU hotplug (which had been | ||
| 502 | * disabled while beginning to freeze tasks). | ||
| 503 | */ | ||
| 504 | void cpu_hotplug_enable_after_thaw(void) | ||
| 505 | { | ||
| 506 | cpu_maps_update_begin(); | ||
| 507 | cpu_hotplug_disabled = 0; | ||
| 508 | cpu_maps_update_done(); | ||
| 509 | } | ||
| 510 | |||
| 511 | /* | ||
| 512 | * When callbacks for CPU hotplug notifications are being executed, we must | ||
| 513 | * ensure that the state of the system with respect to the tasks being frozen | ||
| 514 | * or not, as reported by the notification, remains unchanged *throughout the | ||
| 515 | * duration* of the execution of the callbacks. | ||
| 516 | * Hence we need to prevent the freezer from racing with regular CPU hotplug. | ||
| 517 | * | ||
| 518 | * This synchronization is implemented by mutually excluding regular CPU | ||
| 519 | * hotplug and Suspend/Hibernate call paths by hooking onto the Suspend/ | ||
| 520 | * Hibernate notifications. | ||
| 521 | */ | ||
| 522 | static int | ||
| 523 | cpu_hotplug_pm_callback(struct notifier_block *nb, | ||
| 524 | unsigned long action, void *ptr) | ||
| 525 | { | ||
| 526 | switch (action) { | ||
| 527 | |||
| 528 | case PM_SUSPEND_PREPARE: | ||
| 529 | case PM_HIBERNATION_PREPARE: | ||
| 530 | cpu_hotplug_disable_before_freeze(); | ||
| 531 | break; | ||
| 532 | |||
| 533 | case PM_POST_SUSPEND: | ||
| 534 | case PM_POST_HIBERNATION: | ||
| 535 | cpu_hotplug_enable_after_thaw(); | ||
| 536 | break; | ||
| 537 | |||
| 538 | default: | ||
| 539 | return NOTIFY_DONE; | ||
| 540 | } | ||
| 541 | |||
| 542 | return NOTIFY_OK; | ||
| 543 | } | ||
| 544 | |||
| 545 | |||
| 546 | int cpu_hotplug_pm_sync_init(void) | ||
| 547 | { | ||
| 548 | pm_notifier(cpu_hotplug_pm_callback, 0); | ||
| 549 | return 0; | ||
| 550 | } | ||
| 551 | core_initcall(cpu_hotplug_pm_sync_init); | ||
| 552 | |||
| 479 | #endif /* CONFIG_PM_SLEEP_SMP */ | 553 | #endif /* CONFIG_PM_SLEEP_SMP */ |
| 480 | 554 | ||
| 481 | /** | 555 | /** |
diff --git a/kernel/cpuset.c b/kernel/cpuset.c index 10131fdaff70..9fe58c46a426 100644 --- a/kernel/cpuset.c +++ b/kernel/cpuset.c | |||
| @@ -37,7 +37,7 @@ | |||
| 37 | #include <linux/mempolicy.h> | 37 | #include <linux/mempolicy.h> |
| 38 | #include <linux/mm.h> | 38 | #include <linux/mm.h> |
| 39 | #include <linux/memory.h> | 39 | #include <linux/memory.h> |
| 40 | #include <linux/module.h> | 40 | #include <linux/export.h> |
| 41 | #include <linux/mount.h> | 41 | #include <linux/mount.h> |
| 42 | #include <linux/namei.h> | 42 | #include <linux/namei.h> |
| 43 | #include <linux/pagemap.h> | 43 | #include <linux/pagemap.h> |
| @@ -949,6 +949,8 @@ static void cpuset_migrate_mm(struct mm_struct *mm, const nodemask_t *from, | |||
| 949 | static void cpuset_change_task_nodemask(struct task_struct *tsk, | 949 | static void cpuset_change_task_nodemask(struct task_struct *tsk, |
| 950 | nodemask_t *newmems) | 950 | nodemask_t *newmems) |
| 951 | { | 951 | { |
| 952 | bool masks_disjoint = !nodes_intersects(*newmems, tsk->mems_allowed); | ||
| 953 | |||
| 952 | repeat: | 954 | repeat: |
| 953 | /* | 955 | /* |
| 954 | * Allow tasks that have access to memory reserves because they have | 956 | * Allow tasks that have access to memory reserves because they have |
| @@ -963,7 +965,6 @@ repeat: | |||
| 963 | nodes_or(tsk->mems_allowed, tsk->mems_allowed, *newmems); | 965 | nodes_or(tsk->mems_allowed, tsk->mems_allowed, *newmems); |
| 964 | mpol_rebind_task(tsk, newmems, MPOL_REBIND_STEP1); | 966 | mpol_rebind_task(tsk, newmems, MPOL_REBIND_STEP1); |
| 965 | 967 | ||
| 966 | |||
| 967 | /* | 968 | /* |
| 968 | * ensure checking ->mems_allowed_change_disable after setting all new | 969 | * ensure checking ->mems_allowed_change_disable after setting all new |
| 969 | * allowed nodes. | 970 | * allowed nodes. |
| @@ -980,9 +981,11 @@ repeat: | |||
| 980 | 981 | ||
| 981 | /* | 982 | /* |
| 982 | * Allocation of memory is very fast, we needn't sleep when waiting | 983 | * Allocation of memory is very fast, we needn't sleep when waiting |
| 983 | * for the read-side. | 984 | * for the read-side. No wait is necessary, however, if at least one |
| 985 | * node remains unchanged. | ||
| 984 | */ | 986 | */ |
| 985 | while (ACCESS_ONCE(tsk->mems_allowed_change_disable)) { | 987 | while (masks_disjoint && |
| 988 | ACCESS_ONCE(tsk->mems_allowed_change_disable)) { | ||
| 986 | task_unlock(tsk); | 989 | task_unlock(tsk); |
| 987 | if (!task_curr(tsk)) | 990 | if (!task_curr(tsk)) |
| 988 | yield(); | 991 | yield(); |
diff --git a/kernel/crash_dump.c b/kernel/crash_dump.c index 69ebf3380bac..c766ee54c0b1 100644 --- a/kernel/crash_dump.c +++ b/kernel/crash_dump.c | |||
| @@ -2,7 +2,7 @@ | |||
| 2 | #include <linux/crash_dump.h> | 2 | #include <linux/crash_dump.h> |
| 3 | #include <linux/init.h> | 3 | #include <linux/init.h> |
| 4 | #include <linux/errno.h> | 4 | #include <linux/errno.h> |
| 5 | #include <linux/module.h> | 5 | #include <linux/export.h> |
| 6 | 6 | ||
| 7 | /* | 7 | /* |
| 8 | * If we have booted due to a crash, max_pfn will be a very low value. We need | 8 | * If we have booted due to a crash, max_pfn will be a very low value. We need |
diff --git a/kernel/cred.c b/kernel/cred.c index bb55d052d858..5791612a4045 100644 --- a/kernel/cred.c +++ b/kernel/cred.c | |||
| @@ -8,7 +8,7 @@ | |||
| 8 | * as published by the Free Software Foundation; either version | 8 | * as published by the Free Software Foundation; either version |
| 9 | * 2 of the Licence, or (at your option) any later version. | 9 | * 2 of the Licence, or (at your option) any later version. |
| 10 | */ | 10 | */ |
| 11 | #include <linux/module.h> | 11 | #include <linux/export.h> |
| 12 | #include <linux/cred.h> | 12 | #include <linux/cred.h> |
| 13 | #include <linux/slab.h> | 13 | #include <linux/slab.h> |
| 14 | #include <linux/sched.h> | 14 | #include <linux/sched.h> |
diff --git a/kernel/debug/kdb/kdb_debugger.c b/kernel/debug/kdb/kdb_debugger.c index d9ca9aa481ec..8b68ce78ff17 100644 --- a/kernel/debug/kdb/kdb_debugger.c +++ b/kernel/debug/kdb/kdb_debugger.c | |||
| @@ -11,6 +11,7 @@ | |||
| 11 | #include <linux/kgdb.h> | 11 | #include <linux/kgdb.h> |
| 12 | #include <linux/kdb.h> | 12 | #include <linux/kdb.h> |
| 13 | #include <linux/kdebug.h> | 13 | #include <linux/kdebug.h> |
| 14 | #include <linux/export.h> | ||
| 14 | #include "kdb_private.h" | 15 | #include "kdb_private.h" |
| 15 | #include "../debug_core.h" | 16 | #include "../debug_core.h" |
| 16 | 17 | ||
diff --git a/kernel/dma.c b/kernel/dma.c index f903189c5304..68a2306522c8 100644 --- a/kernel/dma.c +++ b/kernel/dma.c | |||
| @@ -9,7 +9,7 @@ | |||
| 9 | * [It also happened to remove the sizeof(char *) == sizeof(int) | 9 | * [It also happened to remove the sizeof(char *) == sizeof(int) |
| 10 | * assumption introduced because of those /proc/dma patches. -- Hennus] | 10 | * assumption introduced because of those /proc/dma patches. -- Hennus] |
| 11 | */ | 11 | */ |
| 12 | #include <linux/module.h> | 12 | #include <linux/export.h> |
| 13 | #include <linux/kernel.h> | 13 | #include <linux/kernel.h> |
| 14 | #include <linux/errno.h> | 14 | #include <linux/errno.h> |
| 15 | #include <linux/spinlock.h> | 15 | #include <linux/spinlock.h> |
diff --git a/kernel/events/core.c b/kernel/events/core.c index 12a0287e0358..0e8457da6f95 100644 --- a/kernel/events/core.c +++ b/kernel/events/core.c | |||
| @@ -25,11 +25,11 @@ | |||
| 25 | #include <linux/reboot.h> | 25 | #include <linux/reboot.h> |
| 26 | #include <linux/vmstat.h> | 26 | #include <linux/vmstat.h> |
| 27 | #include <linux/device.h> | 27 | #include <linux/device.h> |
| 28 | #include <linux/export.h> | ||
| 28 | #include <linux/vmalloc.h> | 29 | #include <linux/vmalloc.h> |
| 29 | #include <linux/hardirq.h> | 30 | #include <linux/hardirq.h> |
| 30 | #include <linux/rculist.h> | 31 | #include <linux/rculist.h> |
| 31 | #include <linux/uaccess.h> | 32 | #include <linux/uaccess.h> |
| 32 | #include <linux/suspend.h> | ||
| 33 | #include <linux/syscalls.h> | 33 | #include <linux/syscalls.h> |
| 34 | #include <linux/anon_inodes.h> | 34 | #include <linux/anon_inodes.h> |
| 35 | #include <linux/kernel_stat.h> | 35 | #include <linux/kernel_stat.h> |
| @@ -6853,7 +6853,7 @@ static void __cpuinit perf_event_init_cpu(int cpu) | |||
| 6853 | struct swevent_htable *swhash = &per_cpu(swevent_htable, cpu); | 6853 | struct swevent_htable *swhash = &per_cpu(swevent_htable, cpu); |
| 6854 | 6854 | ||
| 6855 | mutex_lock(&swhash->hlist_mutex); | 6855 | mutex_lock(&swhash->hlist_mutex); |
| 6856 | if (swhash->hlist_refcount > 0 && !swhash->swevent_hlist) { | 6856 | if (swhash->hlist_refcount > 0) { |
| 6857 | struct swevent_hlist *hlist; | 6857 | struct swevent_hlist *hlist; |
| 6858 | 6858 | ||
| 6859 | hlist = kzalloc_node(sizeof(*hlist), GFP_KERNEL, cpu_to_node(cpu)); | 6859 | hlist = kzalloc_node(sizeof(*hlist), GFP_KERNEL, cpu_to_node(cpu)); |
| @@ -6942,14 +6942,7 @@ perf_cpu_notify(struct notifier_block *self, unsigned long action, void *hcpu) | |||
| 6942 | { | 6942 | { |
| 6943 | unsigned int cpu = (long)hcpu; | 6943 | unsigned int cpu = (long)hcpu; |
| 6944 | 6944 | ||
| 6945 | /* | 6945 | switch (action & ~CPU_TASKS_FROZEN) { |
| 6946 | * Ignore suspend/resume action, the perf_pm_notifier will | ||
| 6947 | * take care of that. | ||
| 6948 | */ | ||
| 6949 | if (action & CPU_TASKS_FROZEN) | ||
| 6950 | return NOTIFY_OK; | ||
| 6951 | |||
| 6952 | switch (action) { | ||
| 6953 | 6946 | ||
| 6954 | case CPU_UP_PREPARE: | 6947 | case CPU_UP_PREPARE: |
| 6955 | case CPU_DOWN_FAILED: | 6948 | case CPU_DOWN_FAILED: |
| @@ -6968,90 +6961,6 @@ perf_cpu_notify(struct notifier_block *self, unsigned long action, void *hcpu) | |||
| 6968 | return NOTIFY_OK; | 6961 | return NOTIFY_OK; |
| 6969 | } | 6962 | } |
| 6970 | 6963 | ||
| 6971 | static void perf_pm_resume_cpu(void *unused) | ||
| 6972 | { | ||
| 6973 | struct perf_cpu_context *cpuctx; | ||
| 6974 | struct perf_event_context *ctx; | ||
| 6975 | struct pmu *pmu; | ||
| 6976 | int idx; | ||
| 6977 | |||
| 6978 | idx = srcu_read_lock(&pmus_srcu); | ||
| 6979 | list_for_each_entry_rcu(pmu, &pmus, entry) { | ||
| 6980 | cpuctx = this_cpu_ptr(pmu->pmu_cpu_context); | ||
| 6981 | ctx = cpuctx->task_ctx; | ||
| 6982 | |||
| 6983 | perf_ctx_lock(cpuctx, ctx); | ||
| 6984 | perf_pmu_disable(cpuctx->ctx.pmu); | ||
| 6985 | |||
| 6986 | cpu_ctx_sched_out(cpuctx, EVENT_ALL); | ||
| 6987 | if (ctx) | ||
| 6988 | ctx_sched_out(ctx, cpuctx, EVENT_ALL); | ||
| 6989 | |||
| 6990 | perf_pmu_enable(cpuctx->ctx.pmu); | ||
| 6991 | perf_ctx_unlock(cpuctx, ctx); | ||
| 6992 | } | ||
| 6993 | srcu_read_unlock(&pmus_srcu, idx); | ||
| 6994 | } | ||
| 6995 | |||
| 6996 | static void perf_pm_suspend_cpu(void *unused) | ||
| 6997 | { | ||
| 6998 | struct perf_cpu_context *cpuctx; | ||
| 6999 | struct perf_event_context *ctx; | ||
| 7000 | struct pmu *pmu; | ||
| 7001 | int idx; | ||
| 7002 | |||
| 7003 | idx = srcu_read_lock(&pmus_srcu); | ||
| 7004 | list_for_each_entry_rcu(pmu, &pmus, entry) { | ||
| 7005 | cpuctx = this_cpu_ptr(pmu->pmu_cpu_context); | ||
| 7006 | ctx = cpuctx->task_ctx; | ||
| 7007 | |||
| 7008 | perf_ctx_lock(cpuctx, ctx); | ||
| 7009 | perf_pmu_disable(cpuctx->ctx.pmu); | ||
| 7010 | |||
| 7011 | perf_event_sched_in(cpuctx, ctx, current); | ||
| 7012 | |||
| 7013 | perf_pmu_enable(cpuctx->ctx.pmu); | ||
| 7014 | perf_ctx_unlock(cpuctx, ctx); | ||
| 7015 | } | ||
| 7016 | srcu_read_unlock(&pmus_srcu, idx); | ||
| 7017 | } | ||
| 7018 | |||
| 7019 | static int perf_resume(void) | ||
| 7020 | { | ||
| 7021 | get_online_cpus(); | ||
| 7022 | smp_call_function(perf_pm_resume_cpu, NULL, 1); | ||
| 7023 | put_online_cpus(); | ||
| 7024 | |||
| 7025 | return NOTIFY_OK; | ||
| 7026 | } | ||
| 7027 | |||
| 7028 | static int perf_suspend(void) | ||
| 7029 | { | ||
| 7030 | get_online_cpus(); | ||
| 7031 | smp_call_function(perf_pm_suspend_cpu, NULL, 1); | ||
| 7032 | put_online_cpus(); | ||
| 7033 | |||
| 7034 | return NOTIFY_OK; | ||
| 7035 | } | ||
| 7036 | |||
| 7037 | static int perf_pm(struct notifier_block *self, unsigned long action, void *ptr) | ||
| 7038 | { | ||
| 7039 | switch (action) { | ||
| 7040 | case PM_POST_HIBERNATION: | ||
| 7041 | case PM_POST_SUSPEND: | ||
| 7042 | return perf_resume(); | ||
| 7043 | case PM_HIBERNATION_PREPARE: | ||
| 7044 | case PM_SUSPEND_PREPARE: | ||
| 7045 | return perf_suspend(); | ||
| 7046 | default: | ||
| 7047 | return NOTIFY_DONE; | ||
| 7048 | } | ||
| 7049 | } | ||
| 7050 | |||
| 7051 | static struct notifier_block perf_pm_notifier = { | ||
| 7052 | .notifier_call = perf_pm, | ||
| 7053 | }; | ||
| 7054 | |||
| 7055 | void __init perf_event_init(void) | 6964 | void __init perf_event_init(void) |
| 7056 | { | 6965 | { |
| 7057 | int ret; | 6966 | int ret; |
| @@ -7066,7 +6975,6 @@ void __init perf_event_init(void) | |||
| 7066 | perf_tp_register(); | 6975 | perf_tp_register(); |
| 7067 | perf_cpu_notifier(perf_cpu_notify); | 6976 | perf_cpu_notifier(perf_cpu_notify); |
| 7068 | register_reboot_notifier(&perf_reboot_notifier); | 6977 | register_reboot_notifier(&perf_reboot_notifier); |
| 7069 | register_pm_notifier(&perf_pm_notifier); | ||
| 7070 | 6978 | ||
| 7071 | ret = init_hw_breakpoint(); | 6979 | ret = init_hw_breakpoint(); |
| 7072 | WARN(ret, "hw_breakpoint initialization failed with: %d", ret); | 6980 | WARN(ret, "hw_breakpoint initialization failed with: %d", ret); |
diff --git a/kernel/fork.c b/kernel/fork.c index 70d76191afb9..ba0d17261329 100644 --- a/kernel/fork.c +++ b/kernel/fork.c | |||
| @@ -1299,6 +1299,9 @@ static struct task_struct *copy_process(unsigned long clone_flags, | |||
| 1299 | p->pdeath_signal = 0; | 1299 | p->pdeath_signal = 0; |
| 1300 | p->exit_state = 0; | 1300 | p->exit_state = 0; |
| 1301 | 1301 | ||
| 1302 | p->nr_dirtied = 0; | ||
| 1303 | p->nr_dirtied_pause = 128 >> (PAGE_SHIFT - 10); | ||
| 1304 | |||
| 1302 | /* | 1305 | /* |
| 1303 | * Ok, make it visible to the rest of the system. | 1306 | * Ok, make it visible to the rest of the system. |
| 1304 | * We dont wake it up yet. | 1307 | * We dont wake it up yet. |
diff --git a/kernel/freezer.c b/kernel/freezer.c index 66a594e8ad2f..7be56c534397 100644 --- a/kernel/freezer.c +++ b/kernel/freezer.c | |||
| @@ -6,7 +6,7 @@ | |||
| 6 | 6 | ||
| 7 | #include <linux/interrupt.h> | 7 | #include <linux/interrupt.h> |
| 8 | #include <linux/suspend.h> | 8 | #include <linux/suspend.h> |
| 9 | #include <linux/module.h> | 9 | #include <linux/export.h> |
| 10 | #include <linux/syscalls.h> | 10 | #include <linux/syscalls.h> |
| 11 | #include <linux/freezer.h> | 11 | #include <linux/freezer.h> |
| 12 | 12 | ||
| @@ -67,7 +67,7 @@ static void fake_signal_wake_up(struct task_struct *p) | |||
| 67 | unsigned long flags; | 67 | unsigned long flags; |
| 68 | 68 | ||
| 69 | spin_lock_irqsave(&p->sighand->siglock, flags); | 69 | spin_lock_irqsave(&p->sighand->siglock, flags); |
| 70 | signal_wake_up(p, 1); | 70 | signal_wake_up(p, 0); |
| 71 | spin_unlock_irqrestore(&p->sighand->siglock, flags); | 71 | spin_unlock_irqrestore(&p->sighand->siglock, flags); |
| 72 | } | 72 | } |
| 73 | 73 | ||
diff --git a/kernel/futex.c b/kernel/futex.c index 1511dff0cfd6..ea87f4d2f455 100644 --- a/kernel/futex.c +++ b/kernel/futex.c | |||
| @@ -55,7 +55,7 @@ | |||
| 55 | #include <linux/pagemap.h> | 55 | #include <linux/pagemap.h> |
| 56 | #include <linux/syscalls.h> | 56 | #include <linux/syscalls.h> |
| 57 | #include <linux/signal.h> | 57 | #include <linux/signal.h> |
| 58 | #include <linux/module.h> | 58 | #include <linux/export.h> |
| 59 | #include <linux/magic.h> | 59 | #include <linux/magic.h> |
| 60 | #include <linux/pid.h> | 60 | #include <linux/pid.h> |
| 61 | #include <linux/nsproxy.h> | 61 | #include <linux/nsproxy.h> |
diff --git a/kernel/groups.c b/kernel/groups.c index 1cc476d52dd3..99b53d1eb7ea 100644 --- a/kernel/groups.c +++ b/kernel/groups.c | |||
| @@ -2,7 +2,7 @@ | |||
| 2 | * Supplementary group IDs | 2 | * Supplementary group IDs |
| 3 | */ | 3 | */ |
| 4 | #include <linux/cred.h> | 4 | #include <linux/cred.h> |
| 5 | #include <linux/module.h> | 5 | #include <linux/export.h> |
| 6 | #include <linux/slab.h> | 6 | #include <linux/slab.h> |
| 7 | #include <linux/security.h> | 7 | #include <linux/security.h> |
| 8 | #include <linux/syscalls.h> | 8 | #include <linux/syscalls.h> |
diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c index a9205e32a059..422e567eecf6 100644 --- a/kernel/hrtimer.c +++ b/kernel/hrtimer.c | |||
| @@ -32,7 +32,7 @@ | |||
| 32 | */ | 32 | */ |
| 33 | 33 | ||
| 34 | #include <linux/cpu.h> | 34 | #include <linux/cpu.h> |
| 35 | #include <linux/module.h> | 35 | #include <linux/export.h> |
| 36 | #include <linux/percpu.h> | 36 | #include <linux/percpu.h> |
| 37 | #include <linux/hrtimer.h> | 37 | #include <linux/hrtimer.h> |
| 38 | #include <linux/notifier.h> | 38 | #include <linux/notifier.h> |
diff --git a/kernel/hung_task.c b/kernel/hung_task.c index ea640120ab86..8b1748d0172c 100644 --- a/kernel/hung_task.c +++ b/kernel/hung_task.c | |||
| @@ -13,7 +13,7 @@ | |||
| 13 | #include <linux/freezer.h> | 13 | #include <linux/freezer.h> |
| 14 | #include <linux/kthread.h> | 14 | #include <linux/kthread.h> |
| 15 | #include <linux/lockdep.h> | 15 | #include <linux/lockdep.h> |
| 16 | #include <linux/module.h> | 16 | #include <linux/export.h> |
| 17 | #include <linux/sysctl.h> | 17 | #include <linux/sysctl.h> |
| 18 | 18 | ||
| 19 | /* | 19 | /* |
diff --git a/kernel/irq/generic-chip.c b/kernel/irq/generic-chip.c index 6cb7613e4bf4..c89295a8f668 100644 --- a/kernel/irq/generic-chip.c +++ b/kernel/irq/generic-chip.c | |||
| @@ -6,6 +6,7 @@ | |||
| 6 | #include <linux/io.h> | 6 | #include <linux/io.h> |
| 7 | #include <linux/irq.h> | 7 | #include <linux/irq.h> |
| 8 | #include <linux/slab.h> | 8 | #include <linux/slab.h> |
| 9 | #include <linux/export.h> | ||
| 9 | #include <linux/interrupt.h> | 10 | #include <linux/interrupt.h> |
| 10 | #include <linux/kernel_stat.h> | 11 | #include <linux/kernel_stat.h> |
| 11 | #include <linux/syscore_ops.h> | 12 | #include <linux/syscore_ops.h> |
diff --git a/kernel/irq/irqdesc.c b/kernel/irq/irqdesc.c index 1550e8447a16..d86e254b95eb 100644 --- a/kernel/irq/irqdesc.c +++ b/kernel/irq/irqdesc.c | |||
| @@ -9,7 +9,7 @@ | |||
| 9 | */ | 9 | */ |
| 10 | #include <linux/irq.h> | 10 | #include <linux/irq.h> |
| 11 | #include <linux/slab.h> | 11 | #include <linux/slab.h> |
| 12 | #include <linux/module.h> | 12 | #include <linux/export.h> |
| 13 | #include <linux/interrupt.h> | 13 | #include <linux/interrupt.h> |
| 14 | #include <linux/kernel_stat.h> | 14 | #include <linux/kernel_stat.h> |
| 15 | #include <linux/radix-tree.h> | 15 | #include <linux/radix-tree.h> |
diff --git a/kernel/irq_work.c b/kernel/irq_work.c index 0e2cde4f380b..c3c46c72046e 100644 --- a/kernel/irq_work.c +++ b/kernel/irq_work.c | |||
| @@ -6,9 +6,11 @@ | |||
| 6 | */ | 6 | */ |
| 7 | 7 | ||
| 8 | #include <linux/kernel.h> | 8 | #include <linux/kernel.h> |
| 9 | #include <linux/module.h> | 9 | #include <linux/export.h> |
| 10 | #include <linux/irq_work.h> | 10 | #include <linux/irq_work.h> |
| 11 | #include <linux/percpu.h> | ||
| 11 | #include <linux/hardirq.h> | 12 | #include <linux/hardirq.h> |
| 13 | #include <asm/processor.h> | ||
| 12 | 14 | ||
| 13 | /* | 15 | /* |
| 14 | * An entry can be in one of four states: | 16 | * An entry can be in one of four states: |
diff --git a/kernel/kfifo.c b/kernel/kfifo.c index 01a0700e873f..c744b88c44e2 100644 --- a/kernel/kfifo.c +++ b/kernel/kfifo.c | |||
| @@ -20,7 +20,7 @@ | |||
| 20 | */ | 20 | */ |
| 21 | 21 | ||
| 22 | #include <linux/kernel.h> | 22 | #include <linux/kernel.h> |
| 23 | #include <linux/module.h> | 23 | #include <linux/export.h> |
| 24 | #include <linux/slab.h> | 24 | #include <linux/slab.h> |
| 25 | #include <linux/err.h> | 25 | #include <linux/err.h> |
| 26 | #include <linux/log2.h> | 26 | #include <linux/log2.h> |
diff --git a/kernel/kprobes.c b/kernel/kprobes.c index 2f193d0ba7f2..e5d84644823b 100644 --- a/kernel/kprobes.c +++ b/kernel/kprobes.c | |||
| @@ -36,7 +36,7 @@ | |||
| 36 | #include <linux/init.h> | 36 | #include <linux/init.h> |
| 37 | #include <linux/slab.h> | 37 | #include <linux/slab.h> |
| 38 | #include <linux/stddef.h> | 38 | #include <linux/stddef.h> |
| 39 | #include <linux/module.h> | 39 | #include <linux/export.h> |
| 40 | #include <linux/moduleloader.h> | 40 | #include <linux/moduleloader.h> |
| 41 | #include <linux/kallsyms.h> | 41 | #include <linux/kallsyms.h> |
| 42 | #include <linux/freezer.h> | 42 | #include <linux/freezer.h> |
diff --git a/kernel/ksysfs.c b/kernel/ksysfs.c index 3b053c04dd86..4e316e1acf58 100644 --- a/kernel/ksysfs.c +++ b/kernel/ksysfs.c | |||
| @@ -11,10 +11,11 @@ | |||
| 11 | #include <linux/kobject.h> | 11 | #include <linux/kobject.h> |
| 12 | #include <linux/string.h> | 12 | #include <linux/string.h> |
| 13 | #include <linux/sysfs.h> | 13 | #include <linux/sysfs.h> |
| 14 | #include <linux/module.h> | 14 | #include <linux/export.h> |
| 15 | #include <linux/init.h> | 15 | #include <linux/init.h> |
| 16 | #include <linux/kexec.h> | 16 | #include <linux/kexec.h> |
| 17 | #include <linux/profile.h> | 17 | #include <linux/profile.h> |
| 18 | #include <linux/stat.h> | ||
| 18 | #include <linux/sched.h> | 19 | #include <linux/sched.h> |
| 19 | #include <linux/capability.h> | 20 | #include <linux/capability.h> |
| 20 | 21 | ||
diff --git a/kernel/kthread.c b/kernel/kthread.c index 4ba7cccb4994..b6d216a92639 100644 --- a/kernel/kthread.c +++ b/kernel/kthread.c | |||
| @@ -12,7 +12,7 @@ | |||
| 12 | #include <linux/cpuset.h> | 12 | #include <linux/cpuset.h> |
| 13 | #include <linux/unistd.h> | 13 | #include <linux/unistd.h> |
| 14 | #include <linux/file.h> | 14 | #include <linux/file.h> |
| 15 | #include <linux/module.h> | 15 | #include <linux/export.h> |
| 16 | #include <linux/mutex.h> | 16 | #include <linux/mutex.h> |
| 17 | #include <linux/slab.h> | 17 | #include <linux/slab.h> |
| 18 | #include <linux/freezer.h> | 18 | #include <linux/freezer.h> |
diff --git a/kernel/latencytop.c b/kernel/latencytop.c index 4ac8ebfcab59..a462b317f9a0 100644 --- a/kernel/latencytop.c +++ b/kernel/latencytop.c | |||
| @@ -53,7 +53,7 @@ | |||
| 53 | #include <linux/notifier.h> | 53 | #include <linux/notifier.h> |
| 54 | #include <linux/spinlock.h> | 54 | #include <linux/spinlock.h> |
| 55 | #include <linux/proc_fs.h> | 55 | #include <linux/proc_fs.h> |
| 56 | #include <linux/module.h> | 56 | #include <linux/export.h> |
| 57 | #include <linux/sched.h> | 57 | #include <linux/sched.h> |
| 58 | #include <linux/list.h> | 58 | #include <linux/list.h> |
| 59 | #include <linux/stacktrace.h> | 59 | #include <linux/stacktrace.h> |
diff --git a/kernel/lockdep_proc.c b/kernel/lockdep_proc.c index 71edd2f60c02..91c32a0b612c 100644 --- a/kernel/lockdep_proc.c +++ b/kernel/lockdep_proc.c | |||
| @@ -11,7 +11,7 @@ | |||
| 11 | * Code for /proc/lockdep and /proc/lockdep_stats: | 11 | * Code for /proc/lockdep and /proc/lockdep_stats: |
| 12 | * | 12 | * |
| 13 | */ | 13 | */ |
| 14 | #include <linux/module.h> | 14 | #include <linux/export.h> |
| 15 | #include <linux/proc_fs.h> | 15 | #include <linux/proc_fs.h> |
| 16 | #include <linux/seq_file.h> | 16 | #include <linux/seq_file.h> |
| 17 | #include <linux/kallsyms.h> | 17 | #include <linux/kallsyms.h> |
diff --git a/kernel/module.c b/kernel/module.c index 93342d992f34..178333c48d1e 100644 --- a/kernel/module.c +++ b/kernel/module.c | |||
| @@ -16,7 +16,7 @@ | |||
| 16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
| 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 17 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 18 | */ | 18 | */ |
| 19 | #include <linux/module.h> | 19 | #include <linux/export.h> |
| 20 | #include <linux/moduleloader.h> | 20 | #include <linux/moduleloader.h> |
| 21 | #include <linux/ftrace_event.h> | 21 | #include <linux/ftrace_event.h> |
| 22 | #include <linux/init.h> | 22 | #include <linux/init.h> |
| @@ -2487,6 +2487,9 @@ static int check_modinfo(struct module *mod, struct load_info *info) | |||
| 2487 | return -ENOEXEC; | 2487 | return -ENOEXEC; |
| 2488 | } | 2488 | } |
| 2489 | 2489 | ||
| 2490 | if (!get_modinfo(info, "intree")) | ||
| 2491 | add_taint_module(mod, TAINT_OOT_MODULE); | ||
| 2492 | |||
| 2490 | if (get_modinfo(info, "staging")) { | 2493 | if (get_modinfo(info, "staging")) { |
| 2491 | add_taint_module(mod, TAINT_CRAP); | 2494 | add_taint_module(mod, TAINT_CRAP); |
| 2492 | printk(KERN_WARNING "%s: module is from the staging directory," | 2495 | printk(KERN_WARNING "%s: module is from the staging directory," |
| @@ -2878,8 +2881,7 @@ static struct module *load_module(void __user *umod, | |||
| 2878 | } | 2881 | } |
| 2879 | 2882 | ||
| 2880 | /* This has to be done once we're sure module name is unique. */ | 2883 | /* This has to be done once we're sure module name is unique. */ |
| 2881 | if (!mod->taints || mod->taints == (1U<<TAINT_CRAP)) | 2884 | dynamic_debug_setup(info.debug, info.num_debug); |
| 2882 | dynamic_debug_setup(info.debug, info.num_debug); | ||
| 2883 | 2885 | ||
| 2884 | /* Find duplicate symbols */ | 2886 | /* Find duplicate symbols */ |
| 2885 | err = verify_export_symbols(mod); | 2887 | err = verify_export_symbols(mod); |
| @@ -2915,8 +2917,7 @@ static struct module *load_module(void __user *umod, | |||
| 2915 | module_bug_cleanup(mod); | 2917 | module_bug_cleanup(mod); |
| 2916 | 2918 | ||
| 2917 | ddebug: | 2919 | ddebug: |
| 2918 | if (!mod->taints || mod->taints == (1U<<TAINT_CRAP)) | 2920 | dynamic_debug_remove(info.debug); |
| 2919 | dynamic_debug_remove(info.debug); | ||
| 2920 | unlock: | 2921 | unlock: |
| 2921 | mutex_unlock(&module_mutex); | 2922 | mutex_unlock(&module_mutex); |
| 2922 | synchronize_sched(); | 2923 | synchronize_sched(); |
| @@ -3257,6 +3258,8 @@ static char *module_flags(struct module *mod, char *buf) | |||
| 3257 | buf[bx++] = '('; | 3258 | buf[bx++] = '('; |
| 3258 | if (mod->taints & (1 << TAINT_PROPRIETARY_MODULE)) | 3259 | if (mod->taints & (1 << TAINT_PROPRIETARY_MODULE)) |
| 3259 | buf[bx++] = 'P'; | 3260 | buf[bx++] = 'P'; |
| 3261 | else if (mod->taints & (1 << TAINT_OOT_MODULE)) | ||
| 3262 | buf[bx++] = 'O'; | ||
| 3260 | if (mod->taints & (1 << TAINT_FORCED_MODULE)) | 3263 | if (mod->taints & (1 << TAINT_FORCED_MODULE)) |
| 3261 | buf[bx++] = 'F'; | 3264 | buf[bx++] = 'F'; |
| 3262 | if (mod->taints & (1 << TAINT_CRAP)) | 3265 | if (mod->taints & (1 << TAINT_CRAP)) |
diff --git a/kernel/mutex-debug.c b/kernel/mutex-debug.c index 73da83aff418..7e3443fe1f48 100644 --- a/kernel/mutex-debug.c +++ b/kernel/mutex-debug.c | |||
| @@ -14,7 +14,7 @@ | |||
| 14 | */ | 14 | */ |
| 15 | #include <linux/mutex.h> | 15 | #include <linux/mutex.h> |
| 16 | #include <linux/delay.h> | 16 | #include <linux/delay.h> |
| 17 | #include <linux/module.h> | 17 | #include <linux/export.h> |
| 18 | #include <linux/poison.h> | 18 | #include <linux/poison.h> |
| 19 | #include <linux/sched.h> | 19 | #include <linux/sched.h> |
| 20 | #include <linux/spinlock.h> | 20 | #include <linux/spinlock.h> |
diff --git a/kernel/mutex.c b/kernel/mutex.c index d607ed5dd441..89096dd8786f 100644 --- a/kernel/mutex.c +++ b/kernel/mutex.c | |||
| @@ -19,7 +19,7 @@ | |||
| 19 | */ | 19 | */ |
| 20 | #include <linux/mutex.h> | 20 | #include <linux/mutex.h> |
| 21 | #include <linux/sched.h> | 21 | #include <linux/sched.h> |
| 22 | #include <linux/module.h> | 22 | #include <linux/export.h> |
| 23 | #include <linux/spinlock.h> | 23 | #include <linux/spinlock.h> |
| 24 | #include <linux/interrupt.h> | 24 | #include <linux/interrupt.h> |
| 25 | #include <linux/debug_locks.h> | 25 | #include <linux/debug_locks.h> |
diff --git a/kernel/notifier.c b/kernel/notifier.c index 8d7b435806c9..2d5cc4ccff7f 100644 --- a/kernel/notifier.c +++ b/kernel/notifier.c | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | #include <linux/kdebug.h> | 1 | #include <linux/kdebug.h> |
| 2 | #include <linux/kprobes.h> | 2 | #include <linux/kprobes.h> |
| 3 | #include <linux/module.h> | 3 | #include <linux/export.h> |
| 4 | #include <linux/notifier.h> | 4 | #include <linux/notifier.h> |
| 5 | #include <linux/rcupdate.h> | 5 | #include <linux/rcupdate.h> |
| 6 | #include <linux/vmalloc.h> | 6 | #include <linux/vmalloc.h> |
diff --git a/kernel/nsproxy.c b/kernel/nsproxy.c index 9aeab4b98c64..b576f7f14bc6 100644 --- a/kernel/nsproxy.c +++ b/kernel/nsproxy.c | |||
| @@ -14,7 +14,7 @@ | |||
| 14 | */ | 14 | */ |
| 15 | 15 | ||
| 16 | #include <linux/slab.h> | 16 | #include <linux/slab.h> |
| 17 | #include <linux/module.h> | 17 | #include <linux/export.h> |
| 18 | #include <linux/nsproxy.h> | 18 | #include <linux/nsproxy.h> |
| 19 | #include <linux/init_task.h> | 19 | #include <linux/init_task.h> |
| 20 | #include <linux/mnt_namespace.h> | 20 | #include <linux/mnt_namespace.h> |
diff --git a/kernel/padata.c b/kernel/padata.c index b91941df5e63..b45259931512 100644 --- a/kernel/padata.c +++ b/kernel/padata.c | |||
| @@ -18,7 +18,7 @@ | |||
| 18 | * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. | 18 | * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. |
| 19 | */ | 19 | */ |
| 20 | 20 | ||
| 21 | #include <linux/module.h> | 21 | #include <linux/export.h> |
| 22 | #include <linux/cpumask.h> | 22 | #include <linux/cpumask.h> |
| 23 | #include <linux/err.h> | 23 | #include <linux/err.h> |
| 24 | #include <linux/cpu.h> | 24 | #include <linux/cpu.h> |
diff --git a/kernel/panic.c b/kernel/panic.c index d7bb6974efb5..b26593604214 100644 --- a/kernel/panic.c +++ b/kernel/panic.c | |||
| @@ -177,6 +177,7 @@ static const struct tnt tnts[] = { | |||
| 177 | { TAINT_WARN, 'W', ' ' }, | 177 | { TAINT_WARN, 'W', ' ' }, |
| 178 | { TAINT_CRAP, 'C', ' ' }, | 178 | { TAINT_CRAP, 'C', ' ' }, |
| 179 | { TAINT_FIRMWARE_WORKAROUND, 'I', ' ' }, | 179 | { TAINT_FIRMWARE_WORKAROUND, 'I', ' ' }, |
| 180 | { TAINT_OOT_MODULE, 'O', ' ' }, | ||
| 180 | }; | 181 | }; |
| 181 | 182 | ||
| 182 | /** | 183 | /** |
| @@ -194,6 +195,7 @@ static const struct tnt tnts[] = { | |||
| 194 | * 'W' - Taint on warning. | 195 | * 'W' - Taint on warning. |
| 195 | * 'C' - modules from drivers/staging are loaded. | 196 | * 'C' - modules from drivers/staging are loaded. |
| 196 | * 'I' - Working around severe firmware bug. | 197 | * 'I' - Working around severe firmware bug. |
| 198 | * 'O' - Out-of-tree module has been loaded. | ||
| 197 | * | 199 | * |
| 198 | * The string is overwritten by the next call to print_tainted(). | 200 | * The string is overwritten by the next call to print_tainted(). |
| 199 | */ | 201 | */ |
diff --git a/kernel/params.c b/kernel/params.c index 821788947e40..65aae11eb93f 100644 --- a/kernel/params.c +++ b/kernel/params.c | |||
| @@ -15,7 +15,7 @@ | |||
| 15 | along with this program; if not, write to the Free Software | 15 | along with this program; if not, write to the Free Software |
| 16 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 16 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 17 | */ | 17 | */ |
| 18 | #include <linux/moduleparam.h> | 18 | #include <linux/module.h> |
| 19 | #include <linux/kernel.h> | 19 | #include <linux/kernel.h> |
| 20 | #include <linux/string.h> | 20 | #include <linux/string.h> |
| 21 | #include <linux/errno.h> | 21 | #include <linux/errno.h> |
diff --git a/kernel/pid.c b/kernel/pid.c index 8cafe7e72ad2..fa5f72227e5f 100644 --- a/kernel/pid.c +++ b/kernel/pid.c | |||
| @@ -27,7 +27,7 @@ | |||
| 27 | */ | 27 | */ |
| 28 | 28 | ||
| 29 | #include <linux/mm.h> | 29 | #include <linux/mm.h> |
| 30 | #include <linux/module.h> | 30 | #include <linux/export.h> |
| 31 | #include <linux/slab.h> | 31 | #include <linux/slab.h> |
| 32 | #include <linux/init.h> | 32 | #include <linux/init.h> |
| 33 | #include <linux/rculist.h> | 33 | #include <linux/rculist.h> |
diff --git a/kernel/posix-timers.c b/kernel/posix-timers.c index 4556182527f3..69185ae6b701 100644 --- a/kernel/posix-timers.c +++ b/kernel/posix-timers.c | |||
| @@ -46,7 +46,7 @@ | |||
| 46 | #include <linux/syscalls.h> | 46 | #include <linux/syscalls.h> |
| 47 | #include <linux/wait.h> | 47 | #include <linux/wait.h> |
| 48 | #include <linux/workqueue.h> | 48 | #include <linux/workqueue.h> |
| 49 | #include <linux/module.h> | 49 | #include <linux/export.h> |
| 50 | 50 | ||
| 51 | /* | 51 | /* |
| 52 | * Management arrays for POSIX timers. Timers are kept in slab memory | 52 | * Management arrays for POSIX timers. Timers are kept in slab memory |
diff --git a/kernel/power/hibernate.c b/kernel/power/hibernate.c index 1c53f7fad5f7..b4511b6d3ef9 100644 --- a/kernel/power/hibernate.c +++ b/kernel/power/hibernate.c | |||
| @@ -9,6 +9,7 @@ | |||
| 9 | * This file is released under the GPLv2. | 9 | * This file is released under the GPLv2. |
| 10 | */ | 10 | */ |
| 11 | 11 | ||
| 12 | #include <linux/export.h> | ||
| 12 | #include <linux/suspend.h> | 13 | #include <linux/suspend.h> |
| 13 | #include <linux/syscalls.h> | 14 | #include <linux/syscalls.h> |
| 14 | #include <linux/reboot.h> | 15 | #include <linux/reboot.h> |
diff --git a/kernel/power/main.c b/kernel/power/main.c index a52e88425a31..71f49fe4377e 100644 --- a/kernel/power/main.c +++ b/kernel/power/main.c | |||
| @@ -8,6 +8,7 @@ | |||
| 8 | * | 8 | * |
| 9 | */ | 9 | */ |
| 10 | 10 | ||
| 11 | #include <linux/export.h> | ||
| 11 | #include <linux/kobject.h> | 12 | #include <linux/kobject.h> |
| 12 | #include <linux/string.h> | 13 | #include <linux/string.h> |
| 13 | #include <linux/resume-trace.h> | 14 | #include <linux/resume-trace.h> |
diff --git a/kernel/power/qos.c b/kernel/power/qos.c index 1c1797dd1d1d..56db75147186 100644 --- a/kernel/power/qos.c +++ b/kernel/power/qos.c | |||
| @@ -43,6 +43,7 @@ | |||
| 43 | #include <linux/kernel.h> | 43 | #include <linux/kernel.h> |
| 44 | 44 | ||
| 45 | #include <linux/uaccess.h> | 45 | #include <linux/uaccess.h> |
| 46 | #include <linux/export.h> | ||
| 46 | 47 | ||
| 47 | /* | 48 | /* |
| 48 | * locking rule: all changes to constraints or notifiers lists | 49 | * locking rule: all changes to constraints or notifiers lists |
| @@ -386,8 +387,7 @@ static int pm_qos_power_open(struct inode *inode, struct file *filp) | |||
| 386 | pm_qos_add_request(req, pm_qos_class, PM_QOS_DEFAULT_VALUE); | 387 | pm_qos_add_request(req, pm_qos_class, PM_QOS_DEFAULT_VALUE); |
| 387 | filp->private_data = req; | 388 | filp->private_data = req; |
| 388 | 389 | ||
| 389 | if (filp->private_data) | 390 | return 0; |
| 390 | return 0; | ||
| 391 | } | 391 | } |
| 392 | return -EPERM; | 392 | return -EPERM; |
| 393 | } | 393 | } |
diff --git a/kernel/power/suspend.c b/kernel/power/suspend.c index fdd4263b995d..4953dc054c53 100644 --- a/kernel/power/suspend.c +++ b/kernel/power/suspend.c | |||
| @@ -12,6 +12,7 @@ | |||
| 12 | #include <linux/delay.h> | 12 | #include <linux/delay.h> |
| 13 | #include <linux/errno.h> | 13 | #include <linux/errno.h> |
| 14 | #include <linux/init.h> | 14 | #include <linux/init.h> |
| 15 | #include <linux/kmod.h> | ||
| 15 | #include <linux/console.h> | 16 | #include <linux/console.h> |
| 16 | #include <linux/cpu.h> | 17 | #include <linux/cpu.h> |
| 17 | #include <linux/syscalls.h> | 18 | #include <linux/syscalls.h> |
| @@ -21,6 +22,7 @@ | |||
| 21 | #include <linux/list.h> | 22 | #include <linux/list.h> |
| 22 | #include <linux/mm.h> | 23 | #include <linux/mm.h> |
| 23 | #include <linux/slab.h> | 24 | #include <linux/slab.h> |
| 25 | #include <linux/export.h> | ||
| 24 | #include <linux/suspend.h> | 26 | #include <linux/suspend.h> |
| 25 | #include <linux/syscore_ops.h> | 27 | #include <linux/syscore_ops.h> |
| 26 | #include <trace/events/power.h> | 28 | #include <trace/events/power.h> |
diff --git a/kernel/power/user.c b/kernel/power/user.c index 42ddbc6f0de6..6d8f535c2b88 100644 --- a/kernel/power/user.c +++ b/kernel/power/user.c | |||
| @@ -12,6 +12,7 @@ | |||
| 12 | #include <linux/suspend.h> | 12 | #include <linux/suspend.h> |
| 13 | #include <linux/syscalls.h> | 13 | #include <linux/syscalls.h> |
| 14 | #include <linux/reboot.h> | 14 | #include <linux/reboot.h> |
| 15 | #include <linux/kmod.h> | ||
| 15 | #include <linux/string.h> | 16 | #include <linux/string.h> |
| 16 | #include <linux/device.h> | 17 | #include <linux/device.h> |
| 17 | #include <linux/miscdevice.h> | 18 | #include <linux/miscdevice.h> |
diff --git a/kernel/profile.c b/kernel/profile.c index 961b389fe52f..76b8e77773ee 100644 --- a/kernel/profile.c +++ b/kernel/profile.c | |||
| @@ -13,7 +13,7 @@ | |||
| 13 | * to resolve timer interrupt livelocks, William Irwin, Oracle, 2004 | 13 | * to resolve timer interrupt livelocks, William Irwin, Oracle, 2004 |
| 14 | */ | 14 | */ |
| 15 | 15 | ||
| 16 | #include <linux/module.h> | 16 | #include <linux/export.h> |
| 17 | #include <linux/profile.h> | 17 | #include <linux/profile.h> |
| 18 | #include <linux/bootmem.h> | 18 | #include <linux/bootmem.h> |
| 19 | #include <linux/notifier.h> | 19 | #include <linux/notifier.h> |
diff --git a/kernel/ptrace.c b/kernel/ptrace.c index a70d2a5d8c7b..24d04477b257 100644 --- a/kernel/ptrace.c +++ b/kernel/ptrace.c | |||
| @@ -8,7 +8,7 @@ | |||
| 8 | */ | 8 | */ |
| 9 | 9 | ||
| 10 | #include <linux/capability.h> | 10 | #include <linux/capability.h> |
| 11 | #include <linux/module.h> | 11 | #include <linux/export.h> |
| 12 | #include <linux/sched.h> | 12 | #include <linux/sched.h> |
| 13 | #include <linux/errno.h> | 13 | #include <linux/errno.h> |
| 14 | #include <linux/mm.h> | 14 | #include <linux/mm.h> |
diff --git a/kernel/range.c b/kernel/range.c index 37fa9b99ad58..9b8ae2d6ed68 100644 --- a/kernel/range.c +++ b/kernel/range.c | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* | 1 | /* |
| 2 | * Range add and subtract | 2 | * Range add and subtract |
| 3 | */ | 3 | */ |
| 4 | #include <linux/module.h> | 4 | #include <linux/kernel.h> |
| 5 | #include <linux/init.h> | 5 | #include <linux/init.h> |
| 6 | #include <linux/sort.h> | 6 | #include <linux/sort.h> |
| 7 | 7 | ||
diff --git a/kernel/rcupdate.c b/kernel/rcupdate.c index ca0d23b6b3e8..c5b98e565aee 100644 --- a/kernel/rcupdate.c +++ b/kernel/rcupdate.c | |||
| @@ -43,7 +43,7 @@ | |||
| 43 | #include <linux/notifier.h> | 43 | #include <linux/notifier.h> |
| 44 | #include <linux/cpu.h> | 44 | #include <linux/cpu.h> |
| 45 | #include <linux/mutex.h> | 45 | #include <linux/mutex.h> |
| 46 | #include <linux/module.h> | 46 | #include <linux/export.h> |
| 47 | #include <linux/hardirq.h> | 47 | #include <linux/hardirq.h> |
| 48 | 48 | ||
| 49 | #define CREATE_TRACE_POINTS | 49 | #define CREATE_TRACE_POINTS |
diff --git a/kernel/rcutiny.c b/kernel/rcutiny.c index da775c87f27f..636af6d9c6e5 100644 --- a/kernel/rcutiny.c +++ b/kernel/rcutiny.c | |||
| @@ -22,13 +22,12 @@ | |||
| 22 | * For detailed explanation of Read-Copy Update mechanism see - | 22 | * For detailed explanation of Read-Copy Update mechanism see - |
| 23 | * Documentation/RCU | 23 | * Documentation/RCU |
| 24 | */ | 24 | */ |
| 25 | #include <linux/moduleparam.h> | ||
| 26 | #include <linux/completion.h> | 25 | #include <linux/completion.h> |
| 27 | #include <linux/interrupt.h> | 26 | #include <linux/interrupt.h> |
| 28 | #include <linux/notifier.h> | 27 | #include <linux/notifier.h> |
| 29 | #include <linux/rcupdate.h> | 28 | #include <linux/rcupdate.h> |
| 30 | #include <linux/kernel.h> | 29 | #include <linux/kernel.h> |
| 31 | #include <linux/module.h> | 30 | #include <linux/export.h> |
| 32 | #include <linux/mutex.h> | 31 | #include <linux/mutex.h> |
| 33 | #include <linux/sched.h> | 32 | #include <linux/sched.h> |
| 34 | #include <linux/types.h> | 33 | #include <linux/types.h> |
diff --git a/kernel/rcutiny_plugin.h b/kernel/rcutiny_plugin.h index 02aa7139861c..2b0484a5dc28 100644 --- a/kernel/rcutiny_plugin.h +++ b/kernel/rcutiny_plugin.h | |||
| @@ -23,6 +23,7 @@ | |||
| 23 | */ | 23 | */ |
| 24 | 24 | ||
| 25 | #include <linux/kthread.h> | 25 | #include <linux/kthread.h> |
| 26 | #include <linux/module.h> | ||
| 26 | #include <linux/debugfs.h> | 27 | #include <linux/debugfs.h> |
| 27 | #include <linux/seq_file.h> | 28 | #include <linux/seq_file.h> |
| 28 | 29 | ||
diff --git a/kernel/rcutree.c b/kernel/rcutree.c index e234eb92a177..6b76d812740c 100644 --- a/kernel/rcutree.c +++ b/kernel/rcutree.c | |||
| @@ -38,7 +38,7 @@ | |||
| 38 | #include <linux/nmi.h> | 38 | #include <linux/nmi.h> |
| 39 | #include <linux/atomic.h> | 39 | #include <linux/atomic.h> |
| 40 | #include <linux/bitops.h> | 40 | #include <linux/bitops.h> |
| 41 | #include <linux/module.h> | 41 | #include <linux/export.h> |
| 42 | #include <linux/completion.h> | 42 | #include <linux/completion.h> |
| 43 | #include <linux/moduleparam.h> | 43 | #include <linux/moduleparam.h> |
| 44 | #include <linux/percpu.h> | 44 | #include <linux/percpu.h> |
diff --git a/kernel/relay.c b/kernel/relay.c index 859ea5a9605f..226fade4d727 100644 --- a/kernel/relay.c +++ b/kernel/relay.c | |||
| @@ -15,7 +15,7 @@ | |||
| 15 | #include <linux/errno.h> | 15 | #include <linux/errno.h> |
| 16 | #include <linux/stddef.h> | 16 | #include <linux/stddef.h> |
| 17 | #include <linux/slab.h> | 17 | #include <linux/slab.h> |
| 18 | #include <linux/module.h> | 18 | #include <linux/export.h> |
| 19 | #include <linux/string.h> | 19 | #include <linux/string.h> |
| 20 | #include <linux/relay.h> | 20 | #include <linux/relay.h> |
| 21 | #include <linux/vmalloc.h> | 21 | #include <linux/vmalloc.h> |
diff --git a/kernel/resource.c b/kernel/resource.c index c8dc249da5ce..7640b3a947d0 100644 --- a/kernel/resource.c +++ b/kernel/resource.c | |||
| @@ -7,7 +7,7 @@ | |||
| 7 | * Arbitrary resource management. | 7 | * Arbitrary resource management. |
| 8 | */ | 8 | */ |
| 9 | 9 | ||
| 10 | #include <linux/module.h> | 10 | #include <linux/export.h> |
| 11 | #include <linux/errno.h> | 11 | #include <linux/errno.h> |
| 12 | #include <linux/ioport.h> | 12 | #include <linux/ioport.h> |
| 13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
diff --git a/kernel/rtmutex-debug.c b/kernel/rtmutex-debug.c index a2e7e7210f3e..8eafd1bd273e 100644 --- a/kernel/rtmutex-debug.c +++ b/kernel/rtmutex-debug.c | |||
| @@ -18,7 +18,7 @@ | |||
| 18 | */ | 18 | */ |
| 19 | #include <linux/sched.h> | 19 | #include <linux/sched.h> |
| 20 | #include <linux/delay.h> | 20 | #include <linux/delay.h> |
| 21 | #include <linux/module.h> | 21 | #include <linux/export.h> |
| 22 | #include <linux/spinlock.h> | 22 | #include <linux/spinlock.h> |
| 23 | #include <linux/kallsyms.h> | 23 | #include <linux/kallsyms.h> |
| 24 | #include <linux/syscalls.h> | 24 | #include <linux/syscalls.h> |
diff --git a/kernel/rtmutex-tester.c b/kernel/rtmutex-tester.c index 5c9ccd380966..3d9f31cd79e7 100644 --- a/kernel/rtmutex-tester.c +++ b/kernel/rtmutex-tester.c | |||
| @@ -7,7 +7,7 @@ | |||
| 7 | * | 7 | * |
| 8 | */ | 8 | */ |
| 9 | #include <linux/kthread.h> | 9 | #include <linux/kthread.h> |
| 10 | #include <linux/module.h> | 10 | #include <linux/export.h> |
| 11 | #include <linux/sched.h> | 11 | #include <linux/sched.h> |
| 12 | #include <linux/spinlock.h> | 12 | #include <linux/spinlock.h> |
| 13 | #include <linux/sysdev.h> | 13 | #include <linux/sysdev.h> |
diff --git a/kernel/rtmutex.c b/kernel/rtmutex.c index 5e8d9cce7470..f9d8482dd487 100644 --- a/kernel/rtmutex.c +++ b/kernel/rtmutex.c | |||
| @@ -11,7 +11,7 @@ | |||
| 11 | * See Documentation/rt-mutex-design.txt for details. | 11 | * See Documentation/rt-mutex-design.txt for details. |
| 12 | */ | 12 | */ |
| 13 | #include <linux/spinlock.h> | 13 | #include <linux/spinlock.h> |
| 14 | #include <linux/module.h> | 14 | #include <linux/export.h> |
| 15 | #include <linux/sched.h> | 15 | #include <linux/sched.h> |
| 16 | #include <linux/timer.h> | 16 | #include <linux/timer.h> |
| 17 | 17 | ||
diff --git a/kernel/rwsem.c b/kernel/rwsem.c index 9f48f3d82e9b..b152f74f02de 100644 --- a/kernel/rwsem.c +++ b/kernel/rwsem.c | |||
| @@ -7,7 +7,7 @@ | |||
| 7 | #include <linux/types.h> | 7 | #include <linux/types.h> |
| 8 | #include <linux/kernel.h> | 8 | #include <linux/kernel.h> |
| 9 | #include <linux/sched.h> | 9 | #include <linux/sched.h> |
| 10 | #include <linux/module.h> | 10 | #include <linux/export.h> |
| 11 | #include <linux/rwsem.h> | 11 | #include <linux/rwsem.h> |
| 12 | 12 | ||
| 13 | #include <asm/system.h> | 13 | #include <asm/system.h> |
diff --git a/kernel/sched.c b/kernel/sched.c index d87c6e5d4e8c..0e9344a71be3 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
| @@ -7087,8 +7087,6 @@ static int __init isolated_cpu_setup(char *str) | |||
| 7087 | 7087 | ||
| 7088 | __setup("isolcpus=", isolated_cpu_setup); | 7088 | __setup("isolcpus=", isolated_cpu_setup); |
| 7089 | 7089 | ||
| 7090 | #define SD_NODES_PER_DOMAIN 16 | ||
| 7091 | |||
| 7092 | #ifdef CONFIG_NUMA | 7090 | #ifdef CONFIG_NUMA |
| 7093 | 7091 | ||
| 7094 | /** | 7092 | /** |
diff --git a/kernel/sched_clock.c b/kernel/sched_clock.c index 9d8af0b3fb64..c685e31492df 100644 --- a/kernel/sched_clock.c +++ b/kernel/sched_clock.c | |||
| @@ -62,7 +62,7 @@ | |||
| 62 | */ | 62 | */ |
| 63 | #include <linux/spinlock.h> | 63 | #include <linux/spinlock.h> |
| 64 | #include <linux/hardirq.h> | 64 | #include <linux/hardirq.h> |
| 65 | #include <linux/module.h> | 65 | #include <linux/export.h> |
| 66 | #include <linux/percpu.h> | 66 | #include <linux/percpu.h> |
| 67 | #include <linux/ktime.h> | 67 | #include <linux/ktime.h> |
| 68 | #include <linux/sched.h> | 68 | #include <linux/sched.h> |
diff --git a/kernel/semaphore.c b/kernel/semaphore.c index d831841e55a7..60636a4e25c3 100644 --- a/kernel/semaphore.c +++ b/kernel/semaphore.c | |||
| @@ -27,7 +27,7 @@ | |||
| 27 | 27 | ||
| 28 | #include <linux/compiler.h> | 28 | #include <linux/compiler.h> |
| 29 | #include <linux/kernel.h> | 29 | #include <linux/kernel.h> |
| 30 | #include <linux/module.h> | 30 | #include <linux/export.h> |
| 31 | #include <linux/sched.h> | 31 | #include <linux/sched.h> |
| 32 | #include <linux/semaphore.h> | 32 | #include <linux/semaphore.h> |
| 33 | #include <linux/spinlock.h> | 33 | #include <linux/spinlock.h> |
diff --git a/kernel/signal.c b/kernel/signal.c index d252be2d3de5..b3f78d09a105 100644 --- a/kernel/signal.c +++ b/kernel/signal.c | |||
| @@ -11,7 +11,7 @@ | |||
| 11 | */ | 11 | */ |
| 12 | 12 | ||
| 13 | #include <linux/slab.h> | 13 | #include <linux/slab.h> |
| 14 | #include <linux/module.h> | 14 | #include <linux/export.h> |
| 15 | #include <linux/init.h> | 15 | #include <linux/init.h> |
| 16 | #include <linux/sched.h> | 16 | #include <linux/sched.h> |
| 17 | #include <linux/fs.h> | 17 | #include <linux/fs.h> |
diff --git a/kernel/smp.c b/kernel/smp.c index fb67dfa8394e..db197d60489b 100644 --- a/kernel/smp.c +++ b/kernel/smp.c | |||
| @@ -6,7 +6,7 @@ | |||
| 6 | #include <linux/rcupdate.h> | 6 | #include <linux/rcupdate.h> |
| 7 | #include <linux/rculist.h> | 7 | #include <linux/rculist.h> |
| 8 | #include <linux/kernel.h> | 8 | #include <linux/kernel.h> |
| 9 | #include <linux/module.h> | 9 | #include <linux/export.h> |
| 10 | #include <linux/percpu.h> | 10 | #include <linux/percpu.h> |
| 11 | #include <linux/init.h> | 11 | #include <linux/init.h> |
| 12 | #include <linux/gfp.h> | 12 | #include <linux/gfp.h> |
diff --git a/kernel/softirq.c b/kernel/softirq.c index fca82c32042b..2c71d91efff0 100644 --- a/kernel/softirq.c +++ b/kernel/softirq.c | |||
| @@ -10,7 +10,7 @@ | |||
| 10 | * Remote softirq infrastructure is by Jens Axboe. | 10 | * Remote softirq infrastructure is by Jens Axboe. |
| 11 | */ | 11 | */ |
| 12 | 12 | ||
| 13 | #include <linux/module.h> | 13 | #include <linux/export.h> |
| 14 | #include <linux/kernel_stat.h> | 14 | #include <linux/kernel_stat.h> |
| 15 | #include <linux/interrupt.h> | 15 | #include <linux/interrupt.h> |
| 16 | #include <linux/init.h> | 16 | #include <linux/init.h> |
diff --git a/kernel/spinlock.c b/kernel/spinlock.c index be6517fb9c14..84c7d96918bf 100644 --- a/kernel/spinlock.c +++ b/kernel/spinlock.c | |||
| @@ -19,7 +19,7 @@ | |||
| 19 | #include <linux/spinlock.h> | 19 | #include <linux/spinlock.h> |
| 20 | #include <linux/interrupt.h> | 20 | #include <linux/interrupt.h> |
| 21 | #include <linux/debug_locks.h> | 21 | #include <linux/debug_locks.h> |
| 22 | #include <linux/module.h> | 22 | #include <linux/export.h> |
| 23 | 23 | ||
| 24 | /* | 24 | /* |
| 25 | * If lockdep is enabled then we use the non-preemption spin-ops | 25 | * If lockdep is enabled then we use the non-preemption spin-ops |
diff --git a/kernel/srcu.c b/kernel/srcu.c index 73ce23feaea9..0febf61e1aa3 100644 --- a/kernel/srcu.c +++ b/kernel/srcu.c | |||
| @@ -24,7 +24,7 @@ | |||
| 24 | * | 24 | * |
| 25 | */ | 25 | */ |
| 26 | 26 | ||
| 27 | #include <linux/module.h> | 27 | #include <linux/export.h> |
| 28 | #include <linux/mutex.h> | 28 | #include <linux/mutex.h> |
| 29 | #include <linux/percpu.h> | 29 | #include <linux/percpu.h> |
| 30 | #include <linux/preempt.h> | 30 | #include <linux/preempt.h> |
diff --git a/kernel/stacktrace.c b/kernel/stacktrace.c index d20c6983aad9..00fe55cc5a82 100644 --- a/kernel/stacktrace.c +++ b/kernel/stacktrace.c | |||
| @@ -7,7 +7,7 @@ | |||
| 7 | */ | 7 | */ |
| 8 | #include <linux/sched.h> | 8 | #include <linux/sched.h> |
| 9 | #include <linux/kernel.h> | 9 | #include <linux/kernel.h> |
| 10 | #include <linux/module.h> | 10 | #include <linux/export.h> |
| 11 | #include <linux/kallsyms.h> | 11 | #include <linux/kallsyms.h> |
| 12 | #include <linux/stacktrace.h> | 12 | #include <linux/stacktrace.h> |
| 13 | 13 | ||
diff --git a/kernel/stop_machine.c b/kernel/stop_machine.c index 5b0951aa0496..2f194e965715 100644 --- a/kernel/stop_machine.c +++ b/kernel/stop_machine.c | |||
| @@ -12,7 +12,7 @@ | |||
| 12 | #include <linux/cpu.h> | 12 | #include <linux/cpu.h> |
| 13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
| 14 | #include <linux/kthread.h> | 14 | #include <linux/kthread.h> |
| 15 | #include <linux/module.h> | 15 | #include <linux/export.h> |
| 16 | #include <linux/percpu.h> | 16 | #include <linux/percpu.h> |
| 17 | #include <linux/sched.h> | 17 | #include <linux/sched.h> |
| 18 | #include <linux/stop_machine.h> | 18 | #include <linux/stop_machine.h> |
diff --git a/kernel/sys.c b/kernel/sys.c index 58459509b14c..481611fbd079 100644 --- a/kernel/sys.c +++ b/kernel/sys.c | |||
| @@ -4,7 +4,7 @@ | |||
| 4 | * Copyright (C) 1991, 1992 Linus Torvalds | 4 | * Copyright (C) 1991, 1992 Linus Torvalds |
| 5 | */ | 5 | */ |
| 6 | 6 | ||
| 7 | #include <linux/module.h> | 7 | #include <linux/export.h> |
| 8 | #include <linux/mm.h> | 8 | #include <linux/mm.h> |
| 9 | #include <linux/utsname.h> | 9 | #include <linux/utsname.h> |
| 10 | #include <linux/mman.h> | 10 | #include <linux/mman.h> |
| @@ -12,6 +12,7 @@ | |||
| 12 | #include <linux/prctl.h> | 12 | #include <linux/prctl.h> |
| 13 | #include <linux/highuid.h> | 13 | #include <linux/highuid.h> |
| 14 | #include <linux/fs.h> | 14 | #include <linux/fs.h> |
| 15 | #include <linux/kmod.h> | ||
| 15 | #include <linux/perf_event.h> | 16 | #include <linux/perf_event.h> |
| 16 | #include <linux/resource.h> | 17 | #include <linux/resource.h> |
| 17 | #include <linux/kernel.h> | 18 | #include <linux/kernel.h> |
| @@ -1286,6 +1287,7 @@ SYSCALL_DEFINE2(sethostname, char __user *, name, int, len) | |||
| 1286 | memset(u->nodename + len, 0, sizeof(u->nodename) - len); | 1287 | memset(u->nodename + len, 0, sizeof(u->nodename) - len); |
| 1287 | errno = 0; | 1288 | errno = 0; |
| 1288 | } | 1289 | } |
| 1290 | uts_proc_notify(UTS_PROC_HOSTNAME); | ||
| 1289 | up_write(&uts_sem); | 1291 | up_write(&uts_sem); |
| 1290 | return errno; | 1292 | return errno; |
| 1291 | } | 1293 | } |
| @@ -1336,6 +1338,7 @@ SYSCALL_DEFINE2(setdomainname, char __user *, name, int, len) | |||
| 1336 | memset(u->domainname + len, 0, sizeof(u->domainname) - len); | 1338 | memset(u->domainname + len, 0, sizeof(u->domainname) - len); |
| 1337 | errno = 0; | 1339 | errno = 0; |
| 1338 | } | 1340 | } |
| 1341 | uts_proc_notify(UTS_PROC_DOMAINNAME); | ||
| 1339 | up_write(&uts_sem); | 1342 | up_write(&uts_sem); |
| 1340 | return errno; | 1343 | return errno; |
| 1341 | } | 1344 | } |
diff --git a/kernel/time.c b/kernel/time.c index d77606214529..73e416db0a1e 100644 --- a/kernel/time.c +++ b/kernel/time.c | |||
| @@ -27,7 +27,7 @@ | |||
| 27 | * with nanosecond accuracy | 27 | * with nanosecond accuracy |
| 28 | */ | 28 | */ |
| 29 | 29 | ||
| 30 | #include <linux/module.h> | 30 | #include <linux/export.h> |
| 31 | #include <linux/timex.h> | 31 | #include <linux/timex.h> |
| 32 | #include <linux/capability.h> | 32 | #include <linux/capability.h> |
| 33 | #include <linux/clocksource.h> | 33 | #include <linux/clocksource.h> |
diff --git a/kernel/time/posix-clock.c b/kernel/time/posix-clock.c index c340ca658f37..ce033c7aa2e8 100644 --- a/kernel/time/posix-clock.c +++ b/kernel/time/posix-clock.c | |||
| @@ -18,6 +18,7 @@ | |||
| 18 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | 18 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
| 19 | */ | 19 | */ |
| 20 | #include <linux/device.h> | 20 | #include <linux/device.h> |
| 21 | #include <linux/export.h> | ||
| 21 | #include <linux/file.h> | 22 | #include <linux/file.h> |
| 22 | #include <linux/posix-clock.h> | 23 | #include <linux/posix-clock.h> |
| 23 | #include <linux/slab.h> | 24 | #include <linux/slab.h> |
diff --git a/kernel/timer.c b/kernel/timer.c index 8cff36119e4d..dbaa62422b13 100644 --- a/kernel/timer.c +++ b/kernel/timer.c | |||
| @@ -20,7 +20,7 @@ | |||
| 20 | */ | 20 | */ |
| 21 | 21 | ||
| 22 | #include <linux/kernel_stat.h> | 22 | #include <linux/kernel_stat.h> |
| 23 | #include <linux/module.h> | 23 | #include <linux/export.h> |
| 24 | #include <linux/interrupt.h> | 24 | #include <linux/interrupt.h> |
| 25 | #include <linux/percpu.h> | 25 | #include <linux/percpu.h> |
| 26 | #include <linux/init.h> | 26 | #include <linux/init.h> |
diff --git a/kernel/trace/blktrace.c b/kernel/trace/blktrace.c index 7c910a5593a6..16fc34a0806f 100644 --- a/kernel/trace/blktrace.c +++ b/kernel/trace/blktrace.c | |||
| @@ -23,6 +23,7 @@ | |||
| 23 | #include <linux/mutex.h> | 23 | #include <linux/mutex.h> |
| 24 | #include <linux/slab.h> | 24 | #include <linux/slab.h> |
| 25 | #include <linux/debugfs.h> | 25 | #include <linux/debugfs.h> |
| 26 | #include <linux/export.h> | ||
| 26 | #include <linux/time.h> | 27 | #include <linux/time.h> |
| 27 | #include <linux/uaccess.h> | 28 | #include <linux/uaccess.h> |
| 28 | 29 | ||
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c index 077d85387908..900b409543db 100644 --- a/kernel/trace/ftrace.c +++ b/kernel/trace/ftrace.c | |||
| @@ -22,6 +22,7 @@ | |||
| 22 | #include <linux/hardirq.h> | 22 | #include <linux/hardirq.h> |
| 23 | #include <linux/kthread.h> | 23 | #include <linux/kthread.h> |
| 24 | #include <linux/uaccess.h> | 24 | #include <linux/uaccess.h> |
| 25 | #include <linux/module.h> | ||
| 25 | #include <linux/ftrace.h> | 26 | #include <linux/ftrace.h> |
| 26 | #include <linux/sysctl.h> | 27 | #include <linux/sysctl.h> |
| 27 | #include <linux/slab.h> | 28 | #include <linux/slab.h> |
diff --git a/kernel/trace/trace_syscalls.c b/kernel/trace/trace_syscalls.c index ee7b5a0bb9f8..cb654542c1a1 100644 --- a/kernel/trace/trace_syscalls.c +++ b/kernel/trace/trace_syscalls.c | |||
| @@ -2,6 +2,7 @@ | |||
| 2 | #include <trace/events/syscalls.h> | 2 | #include <trace/events/syscalls.h> |
| 3 | #include <linux/slab.h> | 3 | #include <linux/slab.h> |
| 4 | #include <linux/kernel.h> | 4 | #include <linux/kernel.h> |
| 5 | #include <linux/module.h> /* for MODULE_NAME_LEN via KSYM_SYMBOL_LEN */ | ||
| 5 | #include <linux/ftrace.h> | 6 | #include <linux/ftrace.h> |
| 6 | #include <linux/perf_event.h> | 7 | #include <linux/perf_event.h> |
| 7 | #include <asm/syscall.h> | 8 | #include <asm/syscall.h> |
diff --git a/kernel/up.c b/kernel/up.c index 1ff27a28bb7d..c54c75e9faf7 100644 --- a/kernel/up.c +++ b/kernel/up.c | |||
| @@ -4,7 +4,7 @@ | |||
| 4 | 4 | ||
| 5 | #include <linux/interrupt.h> | 5 | #include <linux/interrupt.h> |
| 6 | #include <linux/kernel.h> | 6 | #include <linux/kernel.h> |
| 7 | #include <linux/module.h> | 7 | #include <linux/export.h> |
| 8 | #include <linux/smp.h> | 8 | #include <linux/smp.h> |
| 9 | 9 | ||
| 10 | int smp_call_function_single(int cpu, void (*func) (void *info), void *info, | 10 | int smp_call_function_single(int cpu, void (*func) (void *info), void *info, |
diff --git a/kernel/user-return-notifier.c b/kernel/user-return-notifier.c index 92cb706c7fc8..1744bb80f1fb 100644 --- a/kernel/user-return-notifier.c +++ b/kernel/user-return-notifier.c | |||
| @@ -2,7 +2,7 @@ | |||
| 2 | #include <linux/user-return-notifier.h> | 2 | #include <linux/user-return-notifier.h> |
| 3 | #include <linux/percpu.h> | 3 | #include <linux/percpu.h> |
| 4 | #include <linux/sched.h> | 4 | #include <linux/sched.h> |
| 5 | #include <linux/module.h> | 5 | #include <linux/export.h> |
| 6 | 6 | ||
| 7 | static DEFINE_PER_CPU(struct hlist_head, return_notifier_list); | 7 | static DEFINE_PER_CPU(struct hlist_head, return_notifier_list); |
| 8 | 8 | ||
diff --git a/kernel/user.c b/kernel/user.c index 9e03e9c1df8d..71dd2363ab0f 100644 --- a/kernel/user.c +++ b/kernel/user.c | |||
| @@ -14,7 +14,7 @@ | |||
| 14 | #include <linux/bitops.h> | 14 | #include <linux/bitops.h> |
| 15 | #include <linux/key.h> | 15 | #include <linux/key.h> |
| 16 | #include <linux/interrupt.h> | 16 | #include <linux/interrupt.h> |
| 17 | #include <linux/module.h> | 17 | #include <linux/export.h> |
| 18 | #include <linux/user_namespace.h> | 18 | #include <linux/user_namespace.h> |
| 19 | 19 | ||
| 20 | /* | 20 | /* |
diff --git a/kernel/user_namespace.c b/kernel/user_namespace.c index 9da289c34f22..3b906e98b1db 100644 --- a/kernel/user_namespace.c +++ b/kernel/user_namespace.c | |||
| @@ -5,7 +5,7 @@ | |||
| 5 | * License. | 5 | * License. |
| 6 | */ | 6 | */ |
| 7 | 7 | ||
| 8 | #include <linux/module.h> | 8 | #include <linux/export.h> |
| 9 | #include <linux/nsproxy.h> | 9 | #include <linux/nsproxy.h> |
| 10 | #include <linux/slab.h> | 10 | #include <linux/slab.h> |
| 11 | #include <linux/user_namespace.h> | 11 | #include <linux/user_namespace.h> |
diff --git a/kernel/utsname.c b/kernel/utsname.c index bff131b9510a..405caf91aad5 100644 --- a/kernel/utsname.c +++ b/kernel/utsname.c | |||
| @@ -9,7 +9,7 @@ | |||
| 9 | * License. | 9 | * License. |
| 10 | */ | 10 | */ |
| 11 | 11 | ||
| 12 | #include <linux/module.h> | 12 | #include <linux/export.h> |
| 13 | #include <linux/uts.h> | 13 | #include <linux/uts.h> |
| 14 | #include <linux/utsname.h> | 14 | #include <linux/utsname.h> |
| 15 | #include <linux/err.h> | 15 | #include <linux/err.h> |
diff --git a/kernel/utsname_sysctl.c b/kernel/utsname_sysctl.c index a2cd77e70d4d..63da38c2d820 100644 --- a/kernel/utsname_sysctl.c +++ b/kernel/utsname_sysctl.c | |||
| @@ -9,10 +9,11 @@ | |||
| 9 | * License. | 9 | * License. |
| 10 | */ | 10 | */ |
| 11 | 11 | ||
| 12 | #include <linux/module.h> | 12 | #include <linux/export.h> |
| 13 | #include <linux/uts.h> | 13 | #include <linux/uts.h> |
| 14 | #include <linux/utsname.h> | 14 | #include <linux/utsname.h> |
| 15 | #include <linux/sysctl.h> | 15 | #include <linux/sysctl.h> |
| 16 | #include <linux/wait.h> | ||
| 16 | 17 | ||
| 17 | static void *get_uts(ctl_table *table, int write) | 18 | static void *get_uts(ctl_table *table, int write) |
| 18 | { | 19 | { |
| @@ -51,12 +52,19 @@ static int proc_do_uts_string(ctl_table *table, int write, | |||
| 51 | uts_table.data = get_uts(table, write); | 52 | uts_table.data = get_uts(table, write); |
| 52 | r = proc_dostring(&uts_table,write,buffer,lenp, ppos); | 53 | r = proc_dostring(&uts_table,write,buffer,lenp, ppos); |
| 53 | put_uts(table, write, uts_table.data); | 54 | put_uts(table, write, uts_table.data); |
| 55 | |||
| 56 | if (write) | ||
| 57 | proc_sys_poll_notify(table->poll); | ||
| 58 | |||
| 54 | return r; | 59 | return r; |
| 55 | } | 60 | } |
| 56 | #else | 61 | #else |
| 57 | #define proc_do_uts_string NULL | 62 | #define proc_do_uts_string NULL |
| 58 | #endif | 63 | #endif |
| 59 | 64 | ||
| 65 | static DEFINE_CTL_TABLE_POLL(hostname_poll); | ||
| 66 | static DEFINE_CTL_TABLE_POLL(domainname_poll); | ||
| 67 | |||
| 60 | static struct ctl_table uts_kern_table[] = { | 68 | static struct ctl_table uts_kern_table[] = { |
| 61 | { | 69 | { |
| 62 | .procname = "ostype", | 70 | .procname = "ostype", |
| @@ -85,6 +93,7 @@ static struct ctl_table uts_kern_table[] = { | |||
| 85 | .maxlen = sizeof(init_uts_ns.name.nodename), | 93 | .maxlen = sizeof(init_uts_ns.name.nodename), |
| 86 | .mode = 0644, | 94 | .mode = 0644, |
| 87 | .proc_handler = proc_do_uts_string, | 95 | .proc_handler = proc_do_uts_string, |
| 96 | .poll = &hostname_poll, | ||
| 88 | }, | 97 | }, |
| 89 | { | 98 | { |
| 90 | .procname = "domainname", | 99 | .procname = "domainname", |
| @@ -92,6 +101,7 @@ static struct ctl_table uts_kern_table[] = { | |||
| 92 | .maxlen = sizeof(init_uts_ns.name.domainname), | 101 | .maxlen = sizeof(init_uts_ns.name.domainname), |
| 93 | .mode = 0644, | 102 | .mode = 0644, |
| 94 | .proc_handler = proc_do_uts_string, | 103 | .proc_handler = proc_do_uts_string, |
| 104 | .poll = &domainname_poll, | ||
| 95 | }, | 105 | }, |
| 96 | {} | 106 | {} |
| 97 | }; | 107 | }; |
| @@ -105,6 +115,19 @@ static struct ctl_table uts_root_table[] = { | |||
| 105 | {} | 115 | {} |
| 106 | }; | 116 | }; |
| 107 | 117 | ||
| 118 | #ifdef CONFIG_PROC_SYSCTL | ||
| 119 | /* | ||
| 120 | * Notify userspace about a change in a certain entry of uts_kern_table, | ||
| 121 | * identified by the parameter proc. | ||
| 122 | */ | ||
| 123 | void uts_proc_notify(enum uts_proc proc) | ||
| 124 | { | ||
| 125 | struct ctl_table *table = &uts_kern_table[proc]; | ||
| 126 | |||
| 127 | proc_sys_poll_notify(table->poll); | ||
| 128 | } | ||
| 129 | #endif | ||
| 130 | |||
| 108 | static int __init utsname_sysctl_init(void) | 131 | static int __init utsname_sysctl_init(void) |
| 109 | { | 132 | { |
| 110 | register_sysctl_table(uts_root_table); | 133 | register_sysctl_table(uts_root_table); |
diff --git a/kernel/wait.c b/kernel/wait.c index f45ea8d2a1ce..26fa7797f90f 100644 --- a/kernel/wait.c +++ b/kernel/wait.c | |||
| @@ -4,7 +4,7 @@ | |||
| 4 | * (C) 2004 William Irwin, Oracle | 4 | * (C) 2004 William Irwin, Oracle |
| 5 | */ | 5 | */ |
| 6 | #include <linux/init.h> | 6 | #include <linux/init.h> |
| 7 | #include <linux/module.h> | 7 | #include <linux/export.h> |
| 8 | #include <linux/sched.h> | 8 | #include <linux/sched.h> |
| 9 | #include <linux/mm.h> | 9 | #include <linux/mm.h> |
| 10 | #include <linux/wait.h> | 10 | #include <linux/wait.h> |
diff --git a/kernel/workqueue.c b/kernel/workqueue.c index 1783aabc6128..42fa9ad0a810 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c | |||
| @@ -23,7 +23,7 @@ | |||
| 23 | * Please read Documentation/workqueue.txt for details. | 23 | * Please read Documentation/workqueue.txt for details. |
| 24 | */ | 24 | */ |
| 25 | 25 | ||
| 26 | #include <linux/module.h> | 26 | #include <linux/export.h> |
| 27 | #include <linux/kernel.h> | 27 | #include <linux/kernel.h> |
| 28 | #include <linux/sched.h> | 28 | #include <linux/sched.h> |
| 29 | #include <linux/init.h> | 29 | #include <linux/init.h> |
