Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1340063

[PATCH 2/6] Revert "cgroup: add cgroup_subsys->css_e_css_changed()"

From Tejun Heo <tj@kernel.org>
Newsgroups linux.kernel
Subject [PATCH 2/6] Revert "cgroup: add cgroup_subsys->css_e_css_changed()"
Date 2016-02-23 00:10 +0100
Message-ID <r57M6-4Su-23@gated-at.bofh.it> (permalink)
References <r57M5-4Su-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


This reverts commit 56c807ba4e91f0980567b6a69de239677879b17f.

cgroup_subsys->css_e_css_changed() was supposed to be used by cgroup
writeback support; however, the change to per-inode cgroup association
made it unnecessary and the callback doesn't have any user.  Remove
it.

Signed-off-by: Tejun Heo <tj@kernel.org>
---
 include/linux/cgroup-defs.h |  1 -
 kernel/cgroup.c             | 18 ------------------
 2 files changed, 19 deletions(-)

diff --git a/include/linux/cgroup-defs.h b/include/linux/cgroup-defs.h
index 789471d..4f3c0da 100644
--- a/include/linux/cgroup-defs.h
+++ b/include/linux/cgroup-defs.h
@@ -434,7 +434,6 @@ struct cgroup_subsys {
 	void (*css_released)(struct cgroup_subsys_state *css);
 	void (*css_free)(struct cgroup_subsys_state *css);
 	void (*css_reset)(struct cgroup_subsys_state *css);
-	void (*css_e_css_changed)(struct cgroup_subsys_state *css);
 
 	int (*can_attach)(struct cgroup_taskset *tset);
 	void (*cancel_attach)(struct cgroup_taskset *tset);
diff --git a/kernel/cgroup.c b/kernel/cgroup.c
index 68b032d..7727b6e 100644
--- a/kernel/cgroup.c
+++ b/kernel/cgroup.c
@@ -3127,24 +3127,6 @@ static ssize_t cgroup_subtree_control_write(struct kernfs_open_file *of,
 		}
 	}
 
-	/*
-	 * The effective csses of all the descendants (excluding @cgrp) may
-	 * have changed.  Subsystems can optionally subscribe to this event
-	 * by implementing ->css_e_css_changed() which is invoked if any of
-	 * the effective csses seen from the css's cgroup may have changed.
-	 */
-	for_each_subsys(ss, ssid) {
-		struct cgroup_subsys_state *this_css = cgroup_css(cgrp, ss);
-		struct cgroup_subsys_state *css;
-
-		if (!ss->css_e_css_changed || !this_css)
-			continue;
-
-		css_for_each_descendant_pre(css, this_css)
-			if (css != this_css)
-				ss->css_e_css_changed(css);
-	}
-
 	kernfs_activate(cgrp->kn);
 	ret = 0;
 out_unlock:
-- 
2.5.0

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCHSET] cgroup: misc fixes and cleanups Tejun Heo <tj@kernel.org> - 2016-02-23 00:10 +0100
  [PATCH 1/6] cgroup: fix error return value of cgroup_addrm_files() Tejun Heo <tj@kernel.org> - 2016-02-23 00:10 +0100
  [PATCH 2/6] Revert "cgroup: add cgroup_subsys->css_e_css_changed()" Tejun Heo <tj@kernel.org> - 2016-02-23 00:10 +0100
  [PATCH 4/6] cgroup: convert for_each_subsys_which() to do-while style Tejun Heo <tj@kernel.org> - 2016-02-23 00:10 +0100
  [PATCH 3/6] cgroup: s/child_subsys_mask/subtree_ss_mask/ Tejun Heo <tj@kernel.org> - 2016-02-23 00:10 +0100
  Re: [PATCHSET] cgroup: misc fixes and cleanups Johannes Weiner <hannes@cmpxchg.org> - 2016-02-23 02:40 +0100
  Re: [PATCHSET] cgroup: misc fixes and cleanups Tejun Heo <tj@kernel.org> - 2016-02-23 04:30 +0100
  Re: [PATCHSET] cgroup: misc fixes and cleanups Zefan Li <lizefan@huawei.com> - 2016-02-23 05:00 +0100

csiph-web