Re: [PATCH] memcg: fix return value of mem_cgroup_hierarchy_write()

From: Balbir Singh
Date: Wed Jan 14 2009 - 03:38:54 EST


* Li Zefan <lizf@xxxxxxxxxxxxxx> [2009-01-14 16:10:52]:

> When there are sub-dirs, writing to memory.use_hierarchy returns -EBUSY,
> this doesn't seem to fit the meaning of EBUSY, and is inconsistent with
> memory.swappiness, which returns -EINVAL in this case.
>
> Signed-off-by: Li Zefan <lizf@xxxxxxxxxxxxxx>

The patch does much more than the changelog says. The reason for EBUSY
is that the group is in use due to children or existing references and
tasks. I think EBUSY is the correct error code to return.

--
Balbir
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/