Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp756181ybz; Wed, 15 Apr 2020 18:16:04 -0700 (PDT) X-Google-Smtp-Source: APiQypKKyrtFTk1sLw1TODOJhVauiblQ0gILEslX4xDKN2VnQ7WzzvY6uFDqsB2Sey4vxAkY3ZJp X-Received: by 2002:a17:906:1502:: with SMTP id b2mr7517470ejd.359.1586999764214; Wed, 15 Apr 2020 18:16:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586999764; cv=none; d=google.com; s=arc-20160816; b=qjAsF3Z3gS+rJi2Eu6YnY0/94L43MtOkl5xvj8bTP4okLbFvQX1LAN5DGWNWisa4rv pAB7GhXLBoA5WBnbcbhvEPg50L9/eU5zWiKfpFwTB9OCW1ahFeY4NuUUk6yzh8EetSoa 4jgMHk9FvKeWMVZNwhZuwXnKhSEqrwSOzXGnkVU0iPFcTBt8e62U2xMBCjqBPHCwbwla J/FQQ9EUWGeICthZuxt5t/8HWhOeYAyL1E2IEALG/QKaySHsCvsgQB4mkVjFFrcjaJ9e nXt/xHMftN7CUfjPuzBoXJ5UxzuX7+d8HzQDaLmCV7OxZ+USjU0m26vFd4c3nkQTW9/E x3jw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:references :in-reply-to:subject:cc:date:to:from; bh=LnIsTJVA1eLrGklDMm8JmMa/chAKqOSi885CMKjpFAw=; b=eHEqv5Ok4wrkQK2fw41whqAGJ//zcb2/zFOoljxB7qArK1Y+jXEXdRMdatoFqomyOl JKYmQ8tgbilmfpk7xhwnNGD/qbz7smeV/m61kE+QLyMrkUHfrQV5Dn2O4J6XHKQG4DtV KQNyB0DO1IMpRKTh/hRckpTnGpXIv4BLoopzO7DVdagNqfyUnBFc1yoOYS/nMokdG39W R9Z8p0wtV9H0ZmcTdUMIiF4PqmkX7HgALYIEpSp3ranlstF9yEouVlT0u4l1caJrErgP MtCE+53c7oR/bw4QNXpey8JTrbx5UFbhMCGBXYbCiZPYuQQk7jqh9l9FoSKoql8Wk8ET rJWg== ARC-Authentication-Results: i=1; mx.google.com; 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 ay20si11800038edb.6.2020.04.15.18.15.41; Wed, 15 Apr 2020 18:16:04 -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; 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 S2403916AbgDPAaD (ORCPT + 99 others); Wed, 15 Apr 2020 20:30:03 -0400 Received: from mx2.suse.de ([195.135.220.15]:42916 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2391755AbgDPA36 (ORCPT ); Wed, 15 Apr 2020 20:29:58 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 39771AF8A; Thu, 16 Apr 2020 00:29:53 +0000 (UTC) From: NeilBrown To: Trond Myklebust , "Anna.Schumaker\@Netapp.com" , Andrew Morton , Jan Kara , Michal Hocko Date: Thu, 16 Apr 2020 10:29:45 +1000 Cc: linux-mm@kvack.org, linux-nfs@vger.kernel.org, LKML Subject: Writeback fixes for NFS - V3 In-Reply-To: <87ftdgw58w.fsf@notabene.neil.brown.name> References: <87tv2b7q72.fsf@notabene.neil.brown.name> <87v9miydai.fsf@notabene.neil.brown.name> <87ftdgw58w.fsf@notabene.neil.brown.name> Message-ID: <87wo6gs26e.fsf@notabene.neil.brown.name> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --=-=-= Content-Type: text/plain This is version 3 (I think) of my patches to improve NFS writeaback. Changes: - the code for adding legacy values to /proc/vmstat was broken. I haven't taken the approach that Michal and Jan discussed but a simpler (I hope) approach that just seq_puts() the lines at an appropriate place. - I've modified the handling of PF_LOCAL_THROTTLE - sufficiently that I dropped Jan's reviewed-by. Rather than invoking the same behaviour as BDI_CAP_STRICTLIMIT, I now just use the part I needed. So if the global threshold is not exceeded, PF_LOCAL_THROTTLE tasks are not throttled. This is the case for normal processes, but not when BDI_CAP_STRICTLIMIT is in effect. If the global threshold *is* exceeded, only then to we check the local per-bdi threshold. If that is not exceeded then PF_LOCAL_THROTTLE again avoid any throttling. Only if both the thresholds are exceeded are these tasks throttled. I think this is more refletive if what we actually need. Thanks, NeilBrown --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEG8Yp69OQ2HB7X0l6Oeye3VZigbkFAl6XpvkACgkQOeye3VZi gbmE0g//fohyxqVmWfY0gBY1Eu5eE69mCobqspLO+gxINBuecBNhzJRXDub+b9Jk gGwg5NnJ0yJfUxN//Et4UzX+ZhQWg5rrJ9fYPXkNt4LrsRR1fnr31jUI3+S+XpcZ GxnJjWCHskHVlqf7N9cjdFj+i6Yl4/yVqP0XqWtBVW+IDBvP8WAmICh5BM5rEqrB 0MEKRU3UwVFWLvn+tH6BrSboiSCNHIxsGL/t2nYQf3/CD+s00t4YzRp1FPzV8/WE T1i93OdjiOzaWqDQs3VBaPqyb7fzo/Y35s/2cDJ/WXD2kuEDefmM5P+7uF/UUXir DlCa1IC5mlbsP2qMsrJl4SgbL0IUgqZXpZZUU7n77N7hd6QznJMI60mXKBthrnwq J6Tuua66nAWI7te6EHJkLYP5zTHiAa8dQEk5o7S0ENx/ojcoXjU2LWfMEgCVGrud GUCHWWswFD4w3Xz29UDwAfUTkntbML77hgwlhUI9bKsOtu3IvlQ3npbyVS3DN8wu WQh0YR5e/C3vAQA6vHgw3WhJcMG2vqqMdZeCIwcGOBZ9Z+c00j7t+T9PN2UHiLWs 3OX6yo70TJwYvzRqWrqWJMnaQ1kPxMJVDCt9ZteVkCgmE/PTYCqDNuAUKnZds5Ej XFbpwoyhzN/hxLJRbUOndIb7NJspO5hPVzJvkrrt9era8tXt7j8= =pJOU -----END PGP SIGNATURE----- --=-=-=--