From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: 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=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=no 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 BBCC8C433F5 for ; Wed, 22 Sep 2021 09:20:46 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 44F8A6126A for ; Wed, 22 Sep 2021 09:20:46 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 44F8A6126A Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linutronix.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id C5E216B006C; Wed, 22 Sep 2021 05:20:45 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id C0DEB6B0072; Wed, 22 Sep 2021 05:20:45 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B2306900002; Wed, 22 Sep 2021 05:20:45 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0058.hostedemail.com [216.40.44.58]) by kanga.kvack.org (Postfix) with ESMTP id A40C06B006C for ; Wed, 22 Sep 2021 05:20:45 -0400 (EDT) Received: from smtpin10.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id 55CF92C5AB for ; Wed, 22 Sep 2021 09:20:45 +0000 (UTC) X-FDA: 78614664450.10.5CBE856 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by imf17.hostedemail.com (Postfix) with ESMTP id C103FF00038D for ; Wed, 22 Sep 2021 09:20:44 +0000 (UTC) Date: Wed, 22 Sep 2021 11:20:39 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1632302441; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=rsfkG6tEJiJIjiDfatw6ng1M6I65JveUXPR34wT3l4M=; b=NDXzQ2ZhFMBccLKKuhCfQOzukC7Ajim86c8QbZXvMacspu8qDA5QtwyMSp0VpFTf7A0WMT egPSpi0dZ1Prg40S+155v4tGjv3TkM04KPcWAf/cXTojUwjJrjb/Q4F+WkY4dJbUI3oOLZ 844MM1TqlK50MEFR4cGJemFyiqcqv/qoBfzA64Hwwc/nubNkBpjkWtSBg17IEtMhCQwGyW cs71Pg65xNo0EMFa0Ms7twyBXa4WL3Q9pwcRIxKv3S1OouvM0IeA8W2mieVLcsVCKfiGVj FPtJAuqqQtlXFoc+0c//j0uXheOdK8sfmxSoRa8kPRaUsl0HMuR2OlXuAkK9Iw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1632302441; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=rsfkG6tEJiJIjiDfatw6ng1M6I65JveUXPR34wT3l4M=; b=Jgp5Vbz3h0fVYm+RYtZsaoKjGizPzC76TKJlODeEyRworbpuFf06xDcYt7vj3v9Nt1oNM5 nkdU7VZFcW6yK7BA== From: Sebastian Andrzej Siewior To: nsaenzju@redhat.com Cc: Peter Zijlstra , akpm@linux-foundation.org, frederic@kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, tglx@linutronix.de, cl@linux.com, juri.lelli@redhat.com, mingo@redhat.com, mtosatti@redhat.com, nilal@redhat.com, mgorman@suse.de, ppandit@redhat.com, williams@redhat.com, anna-maria@linutronix.de, linux-rt-users@vger.kernel.org Subject: Re: [PATCH 2/6] mm/swap: Introduce alternative per-cpu LRU cache locking Message-ID: <20210922092039.2j6efnkhmfxuzjnx@linutronix.de> References: <20210921161323.607817-1-nsaenzju@redhat.com> <20210921161323.607817-3-nsaenzju@redhat.com> <20210921220358.GN4323@worktop.programming.kicks-ass.net> <0ec733daf2daaf8a6f5b1fbf56676b9892d5bf73.camel@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <0ec733daf2daaf8a6f5b1fbf56676b9892d5bf73.camel@redhat.com> X-Rspamd-Server: rspam01 X-Rspamd-Queue-Id: C103FF00038D Authentication-Results: imf17.hostedemail.com; dkim=pass header.d=linutronix.de header.s=2020 header.b=NDXzQ2Zh; dkim=pass header.d=linutronix.de header.s=2020e header.b=Jgp5Vbz3; dmarc=pass (policy=none) header.from=linutronix.de; spf=pass (imf17.hostedemail.com: domain of bigeasy@linutronix.de designates 193.142.43.55 as permitted sender) smtp.mailfrom=bigeasy@linutronix.de X-Stat-Signature: rpiofzhh65oiok1pubcwg8pdcshcoem3 X-HE-Tag: 1632302444-204938 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000007, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On 2021-09-22 10:47:07 [+0200], nsaenzju@redhat.com wrote: > > *why* use migrate_disable(), that's horrible! > > I was trying to be mindful of RT. They don't appreciate people taking spinlocks > just after having disabled preemption. > > I think getting local_lock(&locks->local) is my only option then. But it adds > an extra redundant spinlock in the RT+NOHZ_FULL case. spin_lock() does not disable preemption on PREEMPT_RT. You don't disables preemption on purpose or did I miss that? Sebastian