diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-10-10 07:24:40 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-10-10 07:24:40 -0400 |
| commit | b211e9d7c861bdb37b86d6384da9edfb80949ceb (patch) | |
| tree | dfb209ffce92a2b203a9fd2ddbc23eed5daddacf /fs/proc | |
| parent | d9428f09763d307a6d2220c4bbb01d8fc5c55b52 (diff) | |
| parent | e756c7b698604f11a979f2781d06eb7b80aba363 (diff) | |
Merge branch 'for-3.18' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup
Pull cgroup updates from Tejun Heo:
"Nothing too interesting. Just a handful of cleanup patches"
* 'for-3.18' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup:
Revert "cgroup: remove redundant variable in cgroup_mount()"
cgroup: remove redundant variable in cgroup_mount()
cgroup: fix missing unlock in cgroup_release_agent()
cgroup: remove CGRP_RELEASABLE flag
perf/cgroup: Remove perf_put_cgroup()
cgroup: remove redundant check in cgroup_ino()
cpuset: simplify proc_cpuset_show()
cgroup: simplify proc_cgroup_show()
cgroup: use a per-cgroup work for release agent
cgroup: remove bogus comments
cgroup: remove redundant code in cgroup_rmdir()
cgroup: remove some useless forward declarations
cgroup: fix a typo in comment.
Diffstat (limited to 'fs/proc')
| -rw-r--r-- | fs/proc/base.c | 39 |
1 files changed, 4 insertions, 35 deletions
diff --git a/fs/proc/base.c b/fs/proc/base.c index 4c542b907754..950100e326a1 100644 --- a/fs/proc/base.c +++ b/fs/proc/base.c | |||
| @@ -376,37 +376,6 @@ static const struct file_operations proc_lstats_operations = { | |||
| 376 | 376 | ||
| 377 | #endif | 377 | #endif |
| 378 | 378 | ||
| 379 | #ifdef CONFIG_CGROUPS | ||
| 380 | static int cgroup_open(struct inode *inode, struct file *file) | ||
| 381 | { | ||
| 382 | struct pid *pid = PROC_I(inode)->pid; | ||
| 383 | return single_open(file, proc_cgroup_show, pid); | ||
| 384 | } | ||
| 385 | |||
| 386 | static const struct file_operations proc_cgroup_operations = { | ||
| 387 | .open = cgroup_open, | ||
| 388 | .read = seq_read, | ||
| 389 | .llseek = seq_lseek, | ||
| 390 | .release = single_release, | ||
| 391 | }; | ||
| 392 | #endif | ||
| 393 | |||
| 394 | #ifdef CONFIG_PROC_PID_CPUSET | ||
| 395 | |||
| 396 | static int cpuset_open(struct inode *inode, struct file *file) | ||
| 397 | { | ||
| 398 | struct pid *pid = PROC_I(inode)->pid; | ||
| 399 | return single_open(file, proc_cpuset_show, pid); | ||
| 400 | } | ||
| 401 | |||
| 402 | static const struct file_operations proc_cpuset_operations = { | ||
| 403 | .open = cpuset_open, | ||
| 404 | .read = seq_read, | ||
| 405 | .llseek = seq_lseek, | ||
| 406 | .release = single_release, | ||
| 407 | }; | ||
| 408 | #endif | ||
| 409 | |||
| 410 | static int proc_oom_score(struct seq_file *m, struct pid_namespace *ns, | 379 | static int proc_oom_score(struct seq_file *m, struct pid_namespace *ns, |
| 411 | struct pid *pid, struct task_struct *task) | 380 | struct pid *pid, struct task_struct *task) |
| 412 | { | 381 | { |
| @@ -2579,10 +2548,10 @@ static const struct pid_entry tgid_base_stuff[] = { | |||
| 2579 | REG("latency", S_IRUGO, proc_lstats_operations), | 2548 | REG("latency", S_IRUGO, proc_lstats_operations), |
| 2580 | #endif | 2549 | #endif |
| 2581 | #ifdef CONFIG_PROC_PID_CPUSET | 2550 | #ifdef CONFIG_PROC_PID_CPUSET |
| 2582 | REG("cpuset", S_IRUGO, proc_cpuset_operations), | 2551 | ONE("cpuset", S_IRUGO, proc_cpuset_show), |
| 2583 | #endif | 2552 | #endif |
| 2584 | #ifdef CONFIG_CGROUPS | 2553 | #ifdef CONFIG_CGROUPS |
| 2585 | REG("cgroup", S_IRUGO, proc_cgroup_operations), | 2554 | ONE("cgroup", S_IRUGO, proc_cgroup_show), |
| 2586 | #endif | 2555 | #endif |
| 2587 | ONE("oom_score", S_IRUGO, proc_oom_score), | 2556 | ONE("oom_score", S_IRUGO, proc_oom_score), |
| 2588 | REG("oom_adj", S_IRUGO|S_IWUSR, proc_oom_adj_operations), | 2557 | REG("oom_adj", S_IRUGO|S_IWUSR, proc_oom_adj_operations), |
| @@ -2925,10 +2894,10 @@ static const struct pid_entry tid_base_stuff[] = { | |||
| 2925 | REG("latency", S_IRUGO, proc_lstats_operations), | 2894 | REG("latency", S_IRUGO, proc_lstats_operations), |
| 2926 | #endif | 2895 | #endif |
| 2927 | #ifdef CONFIG_PROC_PID_CPUSET | 2896 | #ifdef CONFIG_PROC_PID_CPUSET |
| 2928 | REG("cpuset", S_IRUGO, proc_cpuset_operations), | 2897 | ONE("cpuset", S_IRUGO, proc_cpuset_show), |
| 2929 | #endif | 2898 | #endif |
| 2930 | #ifdef CONFIG_CGROUPS | 2899 | #ifdef CONFIG_CGROUPS |
| 2931 | REG("cgroup", S_IRUGO, proc_cgroup_operations), | 2900 | ONE("cgroup", S_IRUGO, proc_cgroup_show), |
| 2932 | #endif | 2901 | #endif |
| 2933 | ONE("oom_score", S_IRUGO, proc_oom_score), | 2902 | ONE("oom_score", S_IRUGO, proc_oom_score), |
| 2934 | REG("oom_adj", S_IRUGO|S_IWUSR, proc_oom_adj_operations), | 2903 | REG("oom_adj", S_IRUGO|S_IWUSR, proc_oom_adj_operations), |
