]> git.karo-electronics.de Git - mv-sheeva.git/commitdiff
Merge branch 'for-2.6.38/rc2-holder' into for-2.6.38/core
authorJens Axboe <jaxboe@fusionio.com>
Tue, 16 Nov 2010 09:10:12 +0000 (10:10 +0100)
committerJens Axboe <jaxboe@fusionio.com>
Tue, 16 Nov 2010 09:10:12 +0000 (10:10 +0100)
Documentation/cgroups/blkio-controller.txt
block/blk-cgroup.c

index d6da611f8f6338c66cf59e9b8df21eeaa4df500d..4ed7b5ceeed212c1b7a734451456896f4759ee9d 100644 (file)
@@ -89,6 +89,33 @@ Throttling/Upper Limit policy
 
  Limits for writes can be put using blkio.write_bps_device file.
 
+Hierarchical Cgroups
+====================
+- Currently none of the IO control policy supports hierarhical groups. But
+  cgroup interface does allow creation of hierarhical cgroups and internally
+  IO policies treat them as flat hierarchy.
+
+  So this patch will allow creation of cgroup hierarhcy but at the backend
+  everything will be treated as flat. So if somebody created a hierarchy like
+  as follows.
+
+                       root
+                       /  \
+                    test1 test2
+                       |
+                    test3
+
+  CFQ and throttling will practically treat all groups at same level.
+
+                               pivot
+                            /  |   \  \
+                       root  test1 test2  test3
+
+  Down the line we can implement hierarchical accounting/control support
+  and also introduce a new cgroup file "use_hierarchy" which will control
+  whether cgroup hierarchy is viewed as flat or hierarchical by the policy..
+  This is how memory controller also has implemented the things.
+
 Various user visible config options
 ===================================
 CONFIG_BLK_CGROUP
index b1febd0f6d2a5227f617d82c7d4687e190cfc456..455768a3eb9e8c916747024bc6cdfba101ab9919 100644 (file)
@@ -1452,10 +1452,6 @@ blkiocg_create(struct cgroup_subsys *subsys, struct cgroup *cgroup)
                goto done;
        }
 
-       /* Currently we do not support hierarchy deeper than two level (0,1) */
-       if (parent != cgroup->top_cgroup)
-               return ERR_PTR(-EPERM);
-
        blkcg = kzalloc(sizeof(*blkcg), GFP_KERNEL);
        if (!blkcg)
                return ERR_PTR(-ENOMEM);