Message ID | 20210904105003.11688-30-vbabka@suse.cz (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <SRS0=a5Vl=N2=kvack.org=owner-linux-mm@kernel.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1D1DDC433F5 for <linux-mm@archiver.kernel.org>; Sat, 4 Sep 2021 10:51:08 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 4BBF06054F for <linux-mm@archiver.kernel.org>; Sat, 4 Sep 2021 10:51:07 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 4BBF06054F Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 63404940017; Sat, 4 Sep 2021 06:50:17 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 33BF4940014; Sat, 4 Sep 2021 06:50:16 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 973A8940010; Sat, 4 Sep 2021 06:50:16 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0237.hostedemail.com [216.40.44.237]) by kanga.kvack.org (Postfix) with ESMTP id F2BC86B0085 for <linux-mm@kvack.org>; Sat, 4 Sep 2021 06:50:15 -0400 (EDT) Received: from smtpin07.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay04.hostedemail.com (Postfix) with ESMTP id B51CA2FE10 for <linux-mm@kvack.org>; Sat, 4 Sep 2021 10:50:15 +0000 (UTC) X-FDA: 78549571590.07.B559772 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by imf16.hostedemail.com (Postfix) with ESMTP id 6601AF000091 for <linux-mm@kvack.org>; Sat, 4 Sep 2021 10:50:15 +0000 (UTC) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 73405226A3; Sat, 4 Sep 2021 10:50:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1630752614; 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=Ime3x2lj2MOgr3oHMSc5CXs9wlGouwatOfwI8ckMnLg=; b=l/h5S0Tzw82raud2Cto9UcG5h9t8KUOWUD2lDa2rL8Ty1Xa+g/EM6ZuP0aWDg85v4v+ryP DnzuxAw1XJuC+obJOOdhRw2wh/4HaiBaLsEpUd0WWUuO+O7w1XIxzkOpzDPztByFOGx9QY 9hlWc97cTKR7ufc9X+T3WtOXzEwlMt4= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1630752614; 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=Ime3x2lj2MOgr3oHMSc5CXs9wlGouwatOfwI8ckMnLg=; b=Y4fw0QTUZvGWMJNVmAxwsoRtl6qze+L6rdP/4a0hRauvr3LaE/9+ICKGwjgtQsWEsq2bzy EjhtxASnhczYEyCw== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 4B0D413A2C; Sat, 4 Sep 2021 10:50:14 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id SHu8EWZPM2HoUQAAMHmgww (envelope-from <vbabka@suse.cz>); Sat, 04 Sep 2021 10:50:14 +0000 From: Vlastimil Babka <vbabka@suse.cz> To: linux-mm@kvack.org, Christoph Lameter <cl@linux.com>, David Rientjes <rientjes@google.com>, Pekka Enberg <penberg@kernel.org>, Joonsoo Kim <iamjoonsoo.kim@lge.com> Cc: Andrew Morton <akpm@linux-foundation.org>, linux-kernel@vger.kernel.org, Mike Galbraith <efault@gmx.de>, Sebastian Andrzej Siewior <bigeasy@linutronix.de>, Thomas Gleixner <tglx@linutronix.de>, Mel Gorman <mgorman@techsingularity.net>, Vlastimil Babka <vbabka@suse.cz> Subject: [PATCH v6 29/33] mm: slub: make object_map_lock a raw_spinlock_t Date: Sat, 4 Sep 2021 12:49:59 +0200 Message-Id: <20210904105003.11688-30-vbabka@suse.cz> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210904105003.11688-1-vbabka@suse.cz> References: <20210904105003.11688-1-vbabka@suse.cz> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1480; i=vbabka@suse.cz; h=from:subject; bh=2/8u3UH5En3AyznTWqpc4cL+b7AuqqKzQa93bRzqE7A=; b=owEBbQGS/pANAwAIAeAhynPxiakQAcsmYgBhM09Pf1VeinWtUFeSCTnH3nZhlj6Wr8HzOQ3KMWZ7 xmNb/bKJATMEAAEIAB0WIQSNS5MBqTXjGL5IXszgIcpz8YmpEAUCYTNPTwAKCRDgIcpz8YmpEPKfB/ 0TnPZL0UUrCRyKA60dWdmDV6d2u+fC/GWjzEF8xEjTExfmEVDS1nERDrZm+2LZLm6wcf7J5xAwr85/ F+KdZk7ratV3QSOQEGIbCa4umGO+Mt3C7bTuRe6Y755IzvcBq/IE5/UlzNZ1XXGp/iotTjEWkXoM/S Lcs6DbyK6mlRiPVKKHFXEGLQA10yJ347Sry1av6y8RektgBUBSvUL0conZ39EwzvkpieZG5NUs7bHq NET+bNFKes768IP7uri2+kMK8076o9EwZLV9L4EabGdJSHF40kqv73BXWgOpF8U79dpOLo5ALBjRD/ Pw3rL18n3jmAsJk8ARATI9xzMhNc/K X-Developer-Key: i=vbabka@suse.cz; a=openpgp; fpr=A940D434992C2E8E99103D50224FA7E7CC82A664 Authentication-Results: imf16.hostedemail.com; dkim=pass header.d=suse.cz header.s=susede2_rsa header.b="l/h5S0Tz"; dkim=pass header.d=suse.cz header.s=susede2_ed25519 header.b=Y4fw0QTU; spf=pass (imf16.hostedemail.com: domain of vbabka@suse.cz designates 195.135.220.28 as permitted sender) smtp.mailfrom=vbabka@suse.cz; dmarc=none X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: 6601AF000091 X-Stat-Signature: 7syhnza1qjqt4ofiujd67o6syf6mufxd X-HE-Tag: 1630752615-256339 Content-Transfer-Encoding: quoted-printable X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> |
Series |
SLUB: reduce irq disabled scope and make it RT compatible
|
expand
|
diff --git a/mm/slub.c b/mm/slub.c index b7f8b9d34e46..76e56ce55d21 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -452,7 +452,7 @@ static inline bool cmpxchg_double_slab(struct kmem_cache *s, struct page *page, #ifdef CONFIG_SLUB_DEBUG static unsigned long object_map[BITS_TO_LONGS(MAX_OBJS_PER_PAGE)]; -static DEFINE_SPINLOCK(object_map_lock); +static DEFINE_RAW_SPINLOCK(object_map_lock); static void __fill_map(unsigned long *obj_map, struct kmem_cache *s, struct page *page) @@ -497,7 +497,7 @@ static unsigned long *get_map(struct kmem_cache *s, struct page *page) { VM_BUG_ON(!irqs_disabled()); - spin_lock(&object_map_lock); + raw_spin_lock(&object_map_lock); __fill_map(object_map, s, page); @@ -507,7 +507,7 @@ static unsigned long *get_map(struct kmem_cache *s, struct page *page) static void put_map(unsigned long *map) __releases(&object_map_lock) { VM_BUG_ON(map != object_map); - spin_unlock(&object_map_lock); + raw_spin_unlock(&object_map_lock); } static inline unsigned int size_from_object(struct kmem_cache *s)