diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-03 19:22:16 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-04-03 19:22:16 -0400 |
commit | 76ca7d1cca761bb9712dfcad9a27d70b520874ae (patch) | |
tree | 4af495beaeee26b126e3dc6f0aa644e8e0b9e24e /kernel | |
parent | d0cb5f71c5cde8e1ef6d03983641366800ceabdb (diff) | |
parent | 8d81e29fae18b93ab51f308b31babe1a6eb04314 (diff) |
Merge branch 'akpm' (incoming from Andrew)
Merge first patch-bomb from Andrew Morton:
- Various misc bits
- kmemleak fixes
- small befs, codafs, cifs, efs, freexxfs, hfsplus, minixfs, reiserfs things
- fanotify
- I appear to have become SuperH maintainer
- ocfs2 updates
- direct-io tweaks
- a bit of the MM queue
- printk updates
- MAINTAINERS maintenance
- some backlight things
- lib/ updates
- checkpatch updates
- the rtc queue
- nilfs2 updates
- Small Documentation/ updates
* emailed patches from Andrew Morton <akpm@linux-foundation.org>: (237 commits)
Documentation/SubmittingPatches: remove references to patch-scripts
Documentation/SubmittingPatches: update some dead URLs
Documentation/filesystems/ntfs.txt: remove changelog reference
Documentation/kmemleak.txt: updates
fs/reiserfs/super.c: add __init to init_inodecache
fs/reiserfs: move prototype declaration to header file
fs/hfsplus/attributes.c: add __init to hfsplus_create_attr_tree_cache()
fs/hfsplus/extents.c: fix concurrent acess of alloc_blocks
fs/hfsplus/extents.c: remove unused variable in hfsplus_get_block
nilfs2: update project's web site in nilfs2.txt
nilfs2: update MAINTAINERS file entries fix
nilfs2: verify metadata sizes read from disk
nilfs2: add FITRIM ioctl support for nilfs2
nilfs2: add nilfs_sufile_trim_fs to trim clean segs
nilfs2: implementation of NILFS_IOCTL_SET_SUINFO ioctl
nilfs2: add nilfs_sufile_set_suinfo to update segment usage
nilfs2: add struct nilfs_suinfo_update and flags
nilfs2: update MAINTAINERS file entries
fs/coda/inode.c: add __init to init_inodecache()
BEFS: logging cleanup
...
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/cpuset.c | 2 | ||||
-rw-r--r-- | kernel/groups.c | 14 | ||||
-rw-r--r-- | kernel/hung_task.c | 3 | ||||
-rw-r--r-- | kernel/kexec.c | 4 | ||||
-rw-r--r-- | kernel/kthread.c | 4 | ||||
-rw-r--r-- | kernel/printk/printk.c | 15 | ||||
-rw-r--r-- | kernel/profile.c | 2 | ||||
-rw-r--r-- | kernel/resource.c | 2 | ||||
-rw-r--r-- | kernel/sched/stats.c | 2 | ||||
-rw-r--r-- | kernel/sys_ni.c | 2 | ||||
-rw-r--r-- | kernel/sysctl.c | 4 | ||||
-rw-r--r-- | kernel/user.c | 3 | ||||
-rw-r--r-- | kernel/user_namespace.c | 2 | ||||
-rw-r--r-- | kernel/watchdog.c | 16 |
14 files changed, 35 insertions, 40 deletions
diff --git a/kernel/cpuset.c b/kernel/cpuset.c index e2dbb60004d4..3d54c418bd06 100644 --- a/kernel/cpuset.c +++ b/kernel/cpuset.c | |||
@@ -996,7 +996,7 @@ static void cpuset_change_task_nodemask(struct task_struct *tsk, | |||
996 | task_lock(tsk); | 996 | task_lock(tsk); |
997 | /* | 997 | /* |
998 | * Determine if a loop is necessary if another thread is doing | 998 | * Determine if a loop is necessary if another thread is doing |
999 | * get_mems_allowed(). If at least one node remains unchanged and | 999 | * read_mems_allowed_begin(). If at least one node remains unchanged and |
1000 | * tsk does not have a mempolicy, then an empty nodemask will not be | 1000 | * tsk does not have a mempolicy, then an empty nodemask will not be |
1001 | * possible when mems_allowed is larger than a word. | 1001 | * possible when mems_allowed is larger than a word. |
1002 | */ | 1002 | */ |
diff --git a/kernel/groups.c b/kernel/groups.c index 90cf1c38c8ea..451698f86cfa 100644 --- a/kernel/groups.c +++ b/kernel/groups.c | |||
@@ -157,17 +157,13 @@ int groups_search(const struct group_info *group_info, kgid_t grp) | |||
157 | * set_groups - Change a group subscription in a set of credentials | 157 | * set_groups - Change a group subscription in a set of credentials |
158 | * @new: The newly prepared set of credentials to alter | 158 | * @new: The newly prepared set of credentials to alter |
159 | * @group_info: The group list to install | 159 | * @group_info: The group list to install |
160 | * | ||
161 | * Validate a group subscription and, if valid, insert it into a set | ||
162 | * of credentials. | ||
163 | */ | 160 | */ |
164 | int set_groups(struct cred *new, struct group_info *group_info) | 161 | void set_groups(struct cred *new, struct group_info *group_info) |
165 | { | 162 | { |
166 | put_group_info(new->group_info); | 163 | put_group_info(new->group_info); |
167 | groups_sort(group_info); | 164 | groups_sort(group_info); |
168 | get_group_info(group_info); | 165 | get_group_info(group_info); |
169 | new->group_info = group_info; | 166 | new->group_info = group_info; |
170 | return 0; | ||
171 | } | 167 | } |
172 | 168 | ||
173 | EXPORT_SYMBOL(set_groups); | 169 | EXPORT_SYMBOL(set_groups); |
@@ -182,18 +178,12 @@ EXPORT_SYMBOL(set_groups); | |||
182 | int set_current_groups(struct group_info *group_info) | 178 | int set_current_groups(struct group_info *group_info) |
183 | { | 179 | { |
184 | struct cred *new; | 180 | struct cred *new; |
185 | int ret; | ||
186 | 181 | ||
187 | new = prepare_creds(); | 182 | new = prepare_creds(); |
188 | if (!new) | 183 | if (!new) |
189 | return -ENOMEM; | 184 | return -ENOMEM; |
190 | 185 | ||
191 | ret = set_groups(new, group_info); | 186 | set_groups(new, group_info); |
192 | if (ret < 0) { | ||
193 | abort_creds(new); | ||
194 | return ret; | ||
195 | } | ||
196 | |||
197 | return commit_creds(new); | 187 | return commit_creds(new); |
198 | } | 188 | } |
199 | 189 | ||
diff --git a/kernel/hung_task.c b/kernel/hung_task.c index 0b9c169d577f..06bb1417b063 100644 --- a/kernel/hung_task.c +++ b/kernel/hung_task.c | |||
@@ -246,5 +246,4 @@ static int __init hung_task_init(void) | |||
246 | 246 | ||
247 | return 0; | 247 | return 0; |
248 | } | 248 | } |
249 | 249 | subsys_initcall(hung_task_init); | |
250 | module_init(hung_task_init); | ||
diff --git a/kernel/kexec.c b/kernel/kexec.c index 45601cf41bee..c0d261c7db7b 100644 --- a/kernel/kexec.c +++ b/kernel/kexec.c | |||
@@ -1235,7 +1235,7 @@ static int __init crash_notes_memory_init(void) | |||
1235 | } | 1235 | } |
1236 | return 0; | 1236 | return 0; |
1237 | } | 1237 | } |
1238 | module_init(crash_notes_memory_init) | 1238 | subsys_initcall(crash_notes_memory_init); |
1239 | 1239 | ||
1240 | 1240 | ||
1241 | /* | 1241 | /* |
@@ -1629,7 +1629,7 @@ static int __init crash_save_vmcoreinfo_init(void) | |||
1629 | return 0; | 1629 | return 0; |
1630 | } | 1630 | } |
1631 | 1631 | ||
1632 | module_init(crash_save_vmcoreinfo_init) | 1632 | subsys_initcall(crash_save_vmcoreinfo_init); |
1633 | 1633 | ||
1634 | /* | 1634 | /* |
1635 | * Move into place and start executing a preloaded standalone | 1635 | * Move into place and start executing a preloaded standalone |
diff --git a/kernel/kthread.c b/kernel/kthread.c index b5ae3ee860a9..9a130ec06f7a 100644 --- a/kernel/kthread.c +++ b/kernel/kthread.c | |||
@@ -217,7 +217,7 @@ int tsk_fork_get_node(struct task_struct *tsk) | |||
217 | if (tsk == kthreadd_task) | 217 | if (tsk == kthreadd_task) |
218 | return tsk->pref_node_fork; | 218 | return tsk->pref_node_fork; |
219 | #endif | 219 | #endif |
220 | return numa_node_id(); | 220 | return NUMA_NO_NODE; |
221 | } | 221 | } |
222 | 222 | ||
223 | static void create_kthread(struct kthread_create_info *create) | 223 | static void create_kthread(struct kthread_create_info *create) |
@@ -369,7 +369,7 @@ struct task_struct *kthread_create_on_cpu(int (*threadfn)(void *data), | |||
369 | { | 369 | { |
370 | struct task_struct *p; | 370 | struct task_struct *p; |
371 | 371 | ||
372 | p = kthread_create_on_node(threadfn, data, cpu_to_node(cpu), namefmt, | 372 | p = kthread_create_on_node(threadfn, data, cpu_to_mem(cpu), namefmt, |
373 | cpu); | 373 | cpu); |
374 | if (IS_ERR(p)) | 374 | if (IS_ERR(p)) |
375 | return p; | 375 | return p; |
diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c index 4dae9cbe9259..a45b50962295 100644 --- a/kernel/printk/printk.c +++ b/kernel/printk/printk.c | |||
@@ -319,7 +319,7 @@ static void log_store(int facility, int level, | |||
319 | else | 319 | else |
320 | free = log_first_idx - log_next_idx; | 320 | free = log_first_idx - log_next_idx; |
321 | 321 | ||
322 | if (free > size + sizeof(struct printk_log)) | 322 | if (free >= size + sizeof(struct printk_log)) |
323 | break; | 323 | break; |
324 | 324 | ||
325 | /* drop old messages until we have enough contiuous space */ | 325 | /* drop old messages until we have enough contiuous space */ |
@@ -327,7 +327,7 @@ static void log_store(int facility, int level, | |||
327 | log_first_seq++; | 327 | log_first_seq++; |
328 | } | 328 | } |
329 | 329 | ||
330 | if (log_next_idx + size + sizeof(struct printk_log) >= log_buf_len) { | 330 | if (log_next_idx + size + sizeof(struct printk_log) > log_buf_len) { |
331 | /* | 331 | /* |
332 | * This message + an additional empty header does not fit | 332 | * This message + an additional empty header does not fit |
333 | * at the end of the buffer. Add an empty header with len == 0 | 333 | * at the end of the buffer. Add an empty header with len == 0 |
@@ -351,7 +351,7 @@ static void log_store(int facility, int level, | |||
351 | else | 351 | else |
352 | msg->ts_nsec = local_clock(); | 352 | msg->ts_nsec = local_clock(); |
353 | memset(log_dict(msg) + dict_len, 0, pad_len); | 353 | memset(log_dict(msg) + dict_len, 0, pad_len); |
354 | msg->len = sizeof(struct printk_log) + text_len + dict_len + pad_len; | 354 | msg->len = size; |
355 | 355 | ||
356 | /* insert message */ | 356 | /* insert message */ |
357 | log_next_idx += msg->len; | 357 | log_next_idx += msg->len; |
@@ -1560,9 +1560,12 @@ asmlinkage int vprintk_emit(int facility, int level, | |||
1560 | level = kern_level - '0'; | 1560 | level = kern_level - '0'; |
1561 | case 'd': /* KERN_DEFAULT */ | 1561 | case 'd': /* KERN_DEFAULT */ |
1562 | lflags |= LOG_PREFIX; | 1562 | lflags |= LOG_PREFIX; |
1563 | case 'c': /* KERN_CONT */ | ||
1564 | break; | ||
1565 | } | 1563 | } |
1564 | /* | ||
1565 | * No need to check length here because vscnprintf | ||
1566 | * put '\0' at the end of the string. Only valid and | ||
1567 | * newly printed level is detected. | ||
1568 | */ | ||
1566 | text_len -= end_of_header - text; | 1569 | text_len -= end_of_header - text; |
1567 | text = (char *)end_of_header; | 1570 | text = (char *)end_of_header; |
1568 | } | 1571 | } |
@@ -1880,6 +1883,7 @@ void suspend_console(void) | |||
1880 | console_lock(); | 1883 | console_lock(); |
1881 | console_suspended = 1; | 1884 | console_suspended = 1; |
1882 | up(&console_sem); | 1885 | up(&console_sem); |
1886 | mutex_release(&console_lock_dep_map, 1, _RET_IP_); | ||
1883 | } | 1887 | } |
1884 | 1888 | ||
1885 | void resume_console(void) | 1889 | void resume_console(void) |
@@ -1887,6 +1891,7 @@ void resume_console(void) | |||
1887 | if (!console_suspend_enabled) | 1891 | if (!console_suspend_enabled) |
1888 | return; | 1892 | return; |
1889 | down(&console_sem); | 1893 | down(&console_sem); |
1894 | mutex_acquire(&console_lock_dep_map, 0, 0, _RET_IP_); | ||
1890 | console_suspended = 0; | 1895 | console_suspended = 0; |
1891 | console_unlock(); | 1896 | console_unlock(); |
1892 | } | 1897 | } |
diff --git a/kernel/profile.c b/kernel/profile.c index ebdd9c1a86b4..1b266dbe755a 100644 --- a/kernel/profile.c +++ b/kernel/profile.c | |||
@@ -604,5 +604,5 @@ int __ref create_proc_profile(void) /* false positive from hotcpu_notifier */ | |||
604 | hotcpu_notifier(profile_cpu_callback, 0); | 604 | hotcpu_notifier(profile_cpu_callback, 0); |
605 | return 0; | 605 | return 0; |
606 | } | 606 | } |
607 | module_init(create_proc_profile); | 607 | subsys_initcall(create_proc_profile); |
608 | #endif /* CONFIG_PROC_FS */ | 608 | #endif /* CONFIG_PROC_FS */ |
diff --git a/kernel/resource.c b/kernel/resource.c index 673061c06da1..8957d686e29b 100644 --- a/kernel/resource.c +++ b/kernel/resource.c | |||
@@ -511,7 +511,7 @@ static int find_resource(struct resource *root, struct resource *new, | |||
511 | * @newsize: new size of the resource descriptor | 511 | * @newsize: new size of the resource descriptor |
512 | * @constraint: the size and alignment constraints to be met. | 512 | * @constraint: the size and alignment constraints to be met. |
513 | */ | 513 | */ |
514 | int reallocate_resource(struct resource *root, struct resource *old, | 514 | static int reallocate_resource(struct resource *root, struct resource *old, |
515 | resource_size_t newsize, | 515 | resource_size_t newsize, |
516 | struct resource_constraint *constraint) | 516 | struct resource_constraint *constraint) |
517 | { | 517 | { |
diff --git a/kernel/sched/stats.c b/kernel/sched/stats.c index da98af347e8b..a476bea17fbc 100644 --- a/kernel/sched/stats.c +++ b/kernel/sched/stats.c | |||
@@ -142,4 +142,4 @@ static int __init proc_schedstat_init(void) | |||
142 | proc_create("schedstat", 0, NULL, &proc_schedstat_operations); | 142 | proc_create("schedstat", 0, NULL, &proc_schedstat_operations); |
143 | return 0; | 143 | return 0; |
144 | } | 144 | } |
145 | module_init(proc_schedstat_init); | 145 | subsys_initcall(proc_schedstat_init); |
diff --git a/kernel/sys_ni.c b/kernel/sys_ni.c index 7078052284fd..bc8d1b74a6b9 100644 --- a/kernel/sys_ni.c +++ b/kernel/sys_ni.c | |||
@@ -146,11 +146,13 @@ cond_syscall(sys_io_destroy); | |||
146 | cond_syscall(sys_io_submit); | 146 | cond_syscall(sys_io_submit); |
147 | cond_syscall(sys_io_cancel); | 147 | cond_syscall(sys_io_cancel); |
148 | cond_syscall(sys_io_getevents); | 148 | cond_syscall(sys_io_getevents); |
149 | cond_syscall(sys_sysfs); | ||
149 | cond_syscall(sys_syslog); | 150 | cond_syscall(sys_syslog); |
150 | cond_syscall(sys_process_vm_readv); | 151 | cond_syscall(sys_process_vm_readv); |
151 | cond_syscall(sys_process_vm_writev); | 152 | cond_syscall(sys_process_vm_writev); |
152 | cond_syscall(compat_sys_process_vm_readv); | 153 | cond_syscall(compat_sys_process_vm_readv); |
153 | cond_syscall(compat_sys_process_vm_writev); | 154 | cond_syscall(compat_sys_process_vm_writev); |
155 | cond_syscall(sys_uselib); | ||
154 | 156 | ||
155 | /* arch-specific weak syscall entries */ | 157 | /* arch-specific weak syscall entries */ |
156 | cond_syscall(sys_pciconfig_read); | 158 | cond_syscall(sys_pciconfig_read); |
diff --git a/kernel/sysctl.c b/kernel/sysctl.c index 09d2e2413605..5c14b547882e 100644 --- a/kernel/sysctl.c +++ b/kernel/sysctl.c | |||
@@ -123,7 +123,7 @@ static int __maybe_unused neg_one = -1; | |||
123 | static int zero; | 123 | static int zero; |
124 | static int __maybe_unused one = 1; | 124 | static int __maybe_unused one = 1; |
125 | static int __maybe_unused two = 2; | 125 | static int __maybe_unused two = 2; |
126 | static int __maybe_unused three = 3; | 126 | static int __maybe_unused four = 4; |
127 | static unsigned long one_ul = 1; | 127 | static unsigned long one_ul = 1; |
128 | static int one_hundred = 100; | 128 | static int one_hundred = 100; |
129 | #ifdef CONFIG_PRINTK | 129 | #ifdef CONFIG_PRINTK |
@@ -1264,7 +1264,7 @@ static struct ctl_table vm_table[] = { | |||
1264 | .mode = 0644, | 1264 | .mode = 0644, |
1265 | .proc_handler = drop_caches_sysctl_handler, | 1265 | .proc_handler = drop_caches_sysctl_handler, |
1266 | .extra1 = &one, | 1266 | .extra1 = &one, |
1267 | .extra2 = &three, | 1267 | .extra2 = &four, |
1268 | }, | 1268 | }, |
1269 | #ifdef CONFIG_COMPACTION | 1269 | #ifdef CONFIG_COMPACTION |
1270 | { | 1270 | { |
diff --git a/kernel/user.c b/kernel/user.c index c006131beb77..294fc6a94168 100644 --- a/kernel/user.c +++ b/kernel/user.c | |||
@@ -222,5 +222,4 @@ static int __init uid_cache_init(void) | |||
222 | 222 | ||
223 | return 0; | 223 | return 0; |
224 | } | 224 | } |
225 | 225 | subsys_initcall(uid_cache_init); | |
226 | module_init(uid_cache_init); | ||
diff --git a/kernel/user_namespace.c b/kernel/user_namespace.c index dd06439b9c84..0d8f6023fd8d 100644 --- a/kernel/user_namespace.c +++ b/kernel/user_namespace.c | |||
@@ -902,4 +902,4 @@ static __init int user_namespaces_init(void) | |||
902 | user_ns_cachep = KMEM_CACHE(user_namespace, SLAB_PANIC); | 902 | user_ns_cachep = KMEM_CACHE(user_namespace, SLAB_PANIC); |
903 | return 0; | 903 | return 0; |
904 | } | 904 | } |
905 | module_init(user_namespaces_init); | 905 | subsys_initcall(user_namespaces_init); |
diff --git a/kernel/watchdog.c b/kernel/watchdog.c index 01c6f979486f..e90089fd78e0 100644 --- a/kernel/watchdog.c +++ b/kernel/watchdog.c | |||
@@ -158,14 +158,14 @@ void touch_all_softlockup_watchdogs(void) | |||
158 | #ifdef CONFIG_HARDLOCKUP_DETECTOR | 158 | #ifdef CONFIG_HARDLOCKUP_DETECTOR |
159 | void touch_nmi_watchdog(void) | 159 | void touch_nmi_watchdog(void) |
160 | { | 160 | { |
161 | if (watchdog_user_enabled) { | 161 | /* |
162 | unsigned cpu; | 162 | * Using __raw here because some code paths have |
163 | 163 | * preemption enabled. If preemption is enabled | |
164 | for_each_present_cpu(cpu) { | 164 | * then interrupts should be enabled too, in which |
165 | if (per_cpu(watchdog_nmi_touch, cpu) != true) | 165 | * case we shouldn't have to worry about the watchdog |
166 | per_cpu(watchdog_nmi_touch, cpu) = true; | 166 | * going off. |
167 | } | 167 | */ |
168 | } | 168 | __raw_get_cpu_var(watchdog_nmi_touch) = true; |
169 | touch_softlockup_watchdog(); | 169 | touch_softlockup_watchdog(); |
170 | } | 170 | } |
171 | EXPORT_SYMBOL(touch_nmi_watchdog); | 171 | EXPORT_SYMBOL(touch_nmi_watchdog); |