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 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id A58C2C004D4 for ; Thu, 19 Jan 2023 16:36:28 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 0D3336B0073; Thu, 19 Jan 2023 11:36:28 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 05BEC6B0074; Thu, 19 Jan 2023 11:36:27 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id E3FDE6B0075; Thu, 19 Jan 2023 11:36:27 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id D13E06B0073 for ; Thu, 19 Jan 2023 11:36:27 -0500 (EST) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id 76199140668 for ; Thu, 19 Jan 2023 16:36:27 +0000 (UTC) X-FDA: 80372101614.20.4475E50 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by imf20.hostedemail.com (Postfix) with ESMTP id DB5471C0020 for ; Thu, 19 Jan 2023 16:36:25 +0000 (UTC) Authentication-Results: imf20.hostedemail.com; dkim=pass header.d=linutronix.de header.s=2020 header.b=EdWgIYtu; dkim=pass header.d=linutronix.de header.s=2020e header.b=lDnycYey; spf=pass (imf20.hostedemail.com: domain of bigeasy@linutronix.de designates 193.142.43.55 as permitted sender) smtp.mailfrom=bigeasy@linutronix.de; dmarc=pass (policy=none) header.from=linutronix.de ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1674146186; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=AQh0swIanCssR3rlyr5cq60y9iMeZJZy8kioKjVR4fc=; b=Fb7Sq+DkGU9cOu7yfuCON45vYdo4x6Va7iy/OaLBuhVNwBr47Fkzp3kJJh1lz1zAONGwY9 bpHRE5UNHv4NNXUiyvR+HMlyeUHkik9+83IlHNw++UZqQyy5AfKdbcgx/RBa064KfUJPhk R9EJ+gzhIdBgW2Cwp7dbxSa6HDsuSVU= ARC-Authentication-Results: i=1; imf20.hostedemail.com; dkim=pass header.d=linutronix.de header.s=2020 header.b=EdWgIYtu; dkim=pass header.d=linutronix.de header.s=2020e header.b=lDnycYey; spf=pass (imf20.hostedemail.com: domain of bigeasy@linutronix.de designates 193.142.43.55 as permitted sender) smtp.mailfrom=bigeasy@linutronix.de; dmarc=pass (policy=none) header.from=linutronix.de ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1674146186; a=rsa-sha256; cv=none; b=vMzeHFsHyMuZV9IXlk6HzNtJYq+rx22fE8GKZl+9+iJnqQWURv1L4Ao6zKUlkRHedYefVj 3ceL/HFTp2L0ktyD3CBv4ISahhDm4j4bCQ8h6w4WFTGzQXiYdXfb9zRDi/pB8Qv9+uMSeJ tBljNvwYts6oF8iisga+jOiJFifKDJg= Date: Thu, 19 Jan 2023 17:36:22 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1674146183; 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=AQh0swIanCssR3rlyr5cq60y9iMeZJZy8kioKjVR4fc=; b=EdWgIYtuPFXzFTmCN3Bfa+7uV+Bd5X3wJepa9+qR6M8gxf8KOJtOgAdL2ZrdOJBzj4RmV1 HKv++sFDw5ER2lFUB/wYyAQmSZTe3wdrSW9NAviueW+qBiIsMFe99mNqrMPkQ6vvoFP8Eh ECqBFAMquJhMTewq4sjaLwZ9/J875gwuiN8rNneGut9DUkO9/hfasBlpHp4kkAkvEHjXiR 5wrX/4dVBXaeieAkkT+i78+e5FTz1Y2vdcb4SXvpL9UjbsUFNtGB41l+4TsPv7Yl4Q4I/o jtGh33PAtEKC7nxzharBFN5lTikxP6T1A3O719MnAGFc/kgmSq6WLLI9G+xMBw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1674146183; 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=AQh0swIanCssR3rlyr5cq60y9iMeZJZy8kioKjVR4fc=; b=lDnycYeyyDavzYUGJ/HmjcwY0cx5LD16HSEhkQS1A9ldCvwkEes7qBE5mW53KGlb77V1Ad 4vCJ1S+c3LT0IBAg== From: Sebastian Andrzej Siewior To: Hillf Danton Cc: Mel Gorman , Peter Zijlstra , Thomas Gleixner , Ingo Molnar , Davidlohr Bueso , linux-mm@kvack.org, LKML Subject: Re: [PATCH v2] locking/rwbase: Prevent indefinite writer starvation Message-ID: References: <20230117083817.togfwc5cy4g67e5r@techsingularity.net> <20230117165021.t5m7c2d6frbbfzig@techsingularity.net> <20230119011538.3247-1-hdanton@sina.com> <20230119135903.3524-1-hdanton@sina.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20230119135903.3524-1-hdanton@sina.com> X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: DB5471C0020 X-Stat-Signature: abjfdzk4b7ooga61hkmpqeeudo7zuoiy X-Rspam-User: X-HE-Tag: 1674146185-717478 X-HE-Meta: U2FsdGVkX19GWQsGIX6TJIrmONOIaNx6jhpHfZp7HcC74UbSKCEStK9zR1xa+4JWwhW5nHs9QvRrjhyQ2qI8dtkSWjjOsIcGKrPz7ErC6SX6LFlrwZ8XYy/2gPJrl5TDR2/9semvpfTaS275p8GrpCj9Up0lAZyIvar4zq5txMKeczVKeKDf5zqrcoMhELl2GWatAedUhqYL7y7ep0DvQUw5fkl6HPA8d9JsAHxGAWbuVdmttJVY3ya2CdX8W6ltmhy5JAN9f70WfsprcXgSNwjjMtS3NT+H/EI0sqKkcUNSlihnmQ9CusOB1Bg6Ln9p0jaxSn5icuKkbMrGerAGnuKlolub+WYOOUIWniT69mCjYyvR9fh1wdi3M0P7u4bECwu/B1v/iZg6yZBDl36QQG296xO0nFU/lVA6RxvZN+JdZnJ1AjgU6h2NLVx4yqdEB7Ta8rauQ2fb4HacPmViwu63AJjSexWHhLhgMU0qa7hcS2xgYV6h+7IcL6r9w4XpJnIuFXWEJp81jdUlpysvyCLgTmZsP9yZKGAxFjchNNAhgwGDcoceMavffGoMtXH61sLb46XAVrPh9oSj4wZXrjTjCcGBirxqNBf3OJkfFWnyaMk5awUCxcDFs1uMzdGH616fyzVVQ6KEW7Prpg50EUsBr75LiB8WhuYWh4EYy4u9EynqldmmfB8XrVNC/e3esVqJhw7xurtIkTfbBCX3ovRzZOyi7CMZXDbrCIiViI7YGJ9p1n2NDwuSlPreJFJSU35PMCRkED6p9KVCgqgQ0QxiDNJDljjhw9iYKPm/gY0SsNnUnfeKOKX69ve0BarYMKN92PuoOs4R5D5EzLdXbg== 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: On 2023-01-19 21:59:03 [+0800], Hillf Danton wrote: > On Thu, 19 Jan 2023 09:32:22 +0100 Sebastian Andrzej Siewior > > > > As far as Mel's efforts go, I am satisfied so far. > > If not because you can, could you specify why 4ms fails to cure starvation? It does not fail to cure the starvation. I haven't tested it myself but base on Mel's description and the patch it very much looks like it cures the writer starvation. If you don't like the 4ms, it could be 1ms or 40ms - it does not really matter. The 4ms is aligned on the generic implementation which uses the same value. Unless there is strong evidence to use something else I don't see the need to diverse. Sebastian