| Date | Tue, 6 Sep 2011 15:17:47 -0700 | From | Andrew Morton <> | Subject | Re: [PATCH 02/12] cgroups: New resource counter inheritance API |
| |
On Tue, 6 Sep 2011 02:12:56 +0200 Frederic Weisbecker <fweisbec@gmail.com> wrote:
> +void res_counter_inherit(struct res_counter *counter, int member) > +{ > + struct res_counter *parent; > + unsigned long long val; > + > + parent = counter->parent; > + if (parent) { > + val = res_counter_read_u64(parent, member); > + res_counter_write_u64(counter, member, val); > + } > +}
What locking protects the read-modify-write? If none, please fix, otherwise please document it.
All of kernel/res_counter.c is charmingly undocumented.
|