Re: [PATCH] mm/list_lru: allocate on first insert instead of allocation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Feb 28, 2025 at 07:38:36PM +0800, Jingxiang Zeng wrote:
> @@ -84,6 +86,9 @@ lock_list_lru_of_memcg(struct list_lru *lru, int nid, struct mem_cgroup *memcg,
>  			spin_unlock_irq(&l->lock);
>  		else
>  			spin_unlock(&l->lock);
> +	} else {
> +		if (!memcg_list_lru_alloc(memcg, lru))
> +			goto again;
>  	}

Unfortunately, you can't do allocations from this path :(

list_lru_add() is called from many places with spinlocks, rcu locks
etc. held.




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux