/* Somemtimes we have to undo a charge we got by try_charge(). This function is for that and do uncharge, put css's refcnt. gotten by try_charge().  */
static void mem_cgroup_cancel_charge(struct mem_cgroup *mem)
/* Somemtimes we have to undo a charge we got by try_charge(). This function is for that and do uncharge, put css's refcnt. gotten by try_charge().  */
static void mem_cgroup_cancel_charge(struct mem_cgroup *mem)
{
	if (!mem_cgroup_is_root(mem)) {
		res_counter_uncharge(&mem->res, PAGE_SIZE);
		if (do_swap_account)
			res_counter_uncharge(&mem->memsw, PAGE_SIZE);
	}
	css_put(&mem->css);
}