[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20111220171000.e38cee0ea6b9bafc2851ad4b@canb.auug.org.au>
Date: Tue, 20 Dec 2011 17:10:00 +1100
From: Stephen Rothwell <sfr@...b.auug.org.au>
To: Tejun Heo <tj@...nel.org>
Cc: linux-next@...r.kernel.org, linux-kernel@...r.kernel.org,
Jens Axboe <axboe@...nel.dk>
Subject: linux-next: manual merge of the cgroup tree with the block tree
Hi Tejun,
Today's linux-next merge of the cgroup tree got a conflict in
block/blk-cgroup.c between commit 6e736be7f282 ("block: make ioc get/put
interface more conventional and fix race on alloction") from the block
tree and commit bb9d97b6dffa ("cgroup: don't use subsys->can_attach_task
() or ->attach_task()") from the cgroup tree.
I guessed about fixing it up (see below) and can carry the fix as
necessary.
--
Cheers,
Stephen Rothwell sfr@...b.auug.org.au
diff --cc block/blk-cgroup.c
index 2788693,b8c143d..0000000
--- a/block/blk-cgroup.c
+++ b/block/blk-cgroup.c
@@@ -1641,15 -1648,18 +1648,19 @@@ static int blkiocg_can_attach(struct cg
return ret;
}
- static void blkiocg_attach_task(struct cgroup *cgrp, struct task_struct *tsk)
+ static void blkiocg_attach(struct cgroup_subsys *ss, struct cgroup *cgrp,
+ struct cgroup_taskset *tset)
{
+ struct task_struct *task;
struct io_context *ioc;
- /* we don't lose anything even if ioc allocation fails */
- ioc = get_task_io_context(tsk, GFP_ATOMIC, NUMA_NO_NODE);
- if (ioc) {
- ioc_cgroup_changed(ioc);
- put_io_context(ioc, NULL);
+ cgroup_taskset_for_each(task, cgrp, tset) {
- task_lock(task);
- ioc = task->io_context;
- if (ioc)
- ioc->cgroup_changed = 1;
- task_unlock(task);
++ /* we don't lose anything even if ioc allocation fails */
++ ioc = get_task_io_context(task, GFP_ATOMIC, NUMA_NO_NODE);
++ if (ioc) {
++ ioc_cgroup_changed(ioc);
++ put_io_context(ioc, NULL);
++ }
}
}
Content of type "application/pgp-signature" skipped
Powered by blists - more mailing lists