Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp3847740pxj; Mon, 24 May 2021 16:46:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyT54LIaKnF86NqgPSEeShPGKcoGt1mdkrYmuG34N8bvhz3NjeSlIord88RHC3uyThs0kbW X-Received: by 2002:a17:906:1d56:: with SMTP id o22mr24736339ejh.264.1621899967062; Mon, 24 May 2021 16:46:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1621899967; cv=none; d=google.com; s=arc-20160816; b=KSh3YSBER99ohpFXjt0/p7XT0We0ii15MYZ0M0A5G8ZxehYtNk+aeC0W2ScRQKjec0 +gKzI9yOFMWbaBMkRIOTm6aU4p0LOLp8ZelA8otl/LZEAFRa6z3oY0KMsXEwNJu2OOiK fk9sbmWpe3CCrjC9/QH5BX3Os5PLZr0gWYJVES2jxcjtCOBKzxB/ogsbnTOU+WMo6C3f LkN6AzrMqDRMzELledp8QG3pGquG3GY6W36WLDLqeXzjRt/QXeOo1wDpPkIYy0MEXncH hOBDRmr31UrVeTziH0epb11m/jlmmUIjlymFbJFZclXIg81pXIe7LZzljgcM630rhyOZ cAwQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-signature; bh=Vn0q2MowqtMDKWpeLbHMppeC+VLuK7X9dSk7w+C8hww=; b=poOddL9epgBYjt4vDj81cmoSrpCN/xVt6A9iW22W87OKVRufTeU2HMSZRUOKjVSWoH 0p0Cx8Ewkf1dzPtrwXjhuX/INRZOBxJBjsqLKw0P8vUHnvIUqE/eVNEdngM/eKJxGe6p pmRngFEbMT0NXWh6c4g5TysnMxWRUcnZPEP441Hr/gGd0fXlKYzmy5TcWYdLxeCpZS9Y IEBcyhQaOR3EaXwzccZhaW9u1xSy2U43IKkM9TYnTZ79AU7kQvPrADvjn0insb7z4f6t 8USV02ppuccyMjHKFQD6cIfFuSGpKmAH9P/MAAu5iJH+r15rhbBZEX+Vx2LHxWaXULQX O83w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=iRccDoB8; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d23si14898664ejz.732.2021.05.24.16.45.44; Mon, 24 May 2021 16:46:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=iRccDoB8; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229940AbhEXXni (ORCPT + 99 others); Mon, 24 May 2021 19:43:38 -0400 Received: from mx2.suse.de ([195.135.220.15]:50692 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229962AbhEXXmV (ORCPT ); Mon, 24 May 2021 19:42:21 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1621899649; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Vn0q2MowqtMDKWpeLbHMppeC+VLuK7X9dSk7w+C8hww=; b=iRccDoB8mUyH/MVrd5v/64ILvNf/DpJlIU/v48EEFKkMgev39CghddEg4y9LsUrIKRu6XH Vzp+HqV2vRgi6kR9MyRvBnVXqwe3SF3zg1X7KD/CwwMKasbeyP0cOwNzlSNmKGOXMlQLc0 S3F+aOYgdh8oUb6jL+yfcIwKGcKs4vU= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1621899649; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Vn0q2MowqtMDKWpeLbHMppeC+VLuK7X9dSk7w+C8hww=; b=dV6m66/oQWOK1Ti2udRobMzvcSd+vTOLKwUtUfQqdMnsPYeYCo0YkMChbRCj06BF71IvKO PD8SG0esmzSymSDw== Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 32B78AF45; Mon, 24 May 2021 23:40:49 +0000 (UTC) From: Vlastimil Babka To: linux-mm@kvack.org, linux-kernel@vger.kernel.org, Christoph Lameter , David Rientjes , Pekka Enberg , Joonsoo Kim Cc: Sebastian Andrzej Siewior , Thomas Gleixner , Mel Gorman , Jesper Dangaard Brouer , Peter Zijlstra , Jann Horn , Vlastimil Babka Subject: [RFC 20/26] mm, slub: discard slabs in unfreeze_partials() without irqs disabled Date: Tue, 25 May 2021 01:39:40 +0200 Message-Id: <20210524233946.20352-21-vbabka@suse.cz> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210524233946.20352-1-vbabka@suse.cz> References: <20210524233946.20352-1-vbabka@suse.cz> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org No need for disabled irqs when discarding slabs, so restore them before discarding. Signed-off-by: Vlastimil Babka --- mm/slub.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mm/slub.c b/mm/slub.c index 446d2d5344c9..33c3faacf7b1 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -2360,6 +2360,8 @@ static void unfreeze_partials(struct kmem_cache *s, if (n) spin_unlock(&n->list_lock); + local_irq_restore(flags); + while (discard_page) { page = discard_page; discard_page = discard_page->next; @@ -2369,7 +2371,6 @@ static void unfreeze_partials(struct kmem_cache *s, stat(s, FREE_SLAB); } - local_irq_restore(flags); #endif /* CONFIG_SLUB_CPU_PARTIAL */ } -- 2.31.1