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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7B01EECAAA1 for ; Thu, 15 Sep 2022 09:42:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229716AbiIOJmO (ORCPT ); Thu, 15 Sep 2022 05:42:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37620 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229570AbiIOJmM (ORCPT ); Thu, 15 Sep 2022 05:42:12 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A63846CF4E; Thu, 15 Sep 2022 02:42:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: Content-ID:Content-Description:In-Reply-To:References; bh=kmV+bjuBIbb/1Zd/POYrIraBtwwr2RAc0pWgW32GYaw=; b=pxDLm4xC98kMchQ2l7sCCX9ypx yEG1CA9vqMQoSnRfymGegTpnD7aWpNAjR0io9BXKkCJUlaeaImBb5HPHQvpaIEcn7gQlp9MdmyA2u ud5HTkIA99OGEQgFFW00Oi3IvT4qXbgu2Bly55ijYDeIKcHa+uDrleY8qQACq9sLyqYqbhy+sCJH4 axR2Ss+V5nYbvPWnt8c5pCYa2CwDlUHh5DRfgqzyo3K3adLgRqRVBQ+5PhnjU33dzwau//LcLchDQ LXMHkjhT2m0c8ylR37ue/UV76hsx/rcvJDhVPj7laWTuXEbPHAhw2KB8FvSSN9CFC6h/aXAQCyCVD pkhNmU4Q==; Received: from [185.122.133.20] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1oYlNi-005auV-92; Thu, 15 Sep 2022 09:42:02 +0000 From: Christoph Hellwig To: Jens Axboe , Matthew Wilcox , Johannes Weiner , Suren Baghdasaryan , Andrew Morton Cc: Chris Mason , Josef Bacik , David Sterba , Gao Xiang , Chao Yu , linux-block@vger.kernel.org, linux-btrfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-erofs@lists.ozlabs.org, linux-mm@kvack.org Subject: improve pagecache PSI annotations v2 Date: Thu, 15 Sep 2022 10:41:55 +0100 Message-Id: <20220915094200.139713-1-hch@lst.de> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org Hi all, currently the VM tries to abuse the block layer submission path for the page cache PSI annotations. This series instead annotates the ->read_folio and ->readahead calls in the core VM code, and then only deals with the odd direct add_to_page_cache_lru calls manually. Changes since v1: - fix a logic error in ra_alloc_folio - drop a unlikely() - spell a comment in the weird way preferred by btrfs maintainers Diffstat: block/bio.c | 8 -------- block/blk-core.c | 17 ----------------- fs/btrfs/compression.c | 14 ++++++++++++-- fs/direct-io.c | 2 -- fs/erofs/zdata.c | 13 ++++++++++++- include/linux/blk_types.h | 1 - include/linux/pagemap.h | 2 ++ kernel/sched/psi.c | 2 ++ mm/filemap.c | 7 +++++++ mm/readahead.c | 22 ++++++++++++++++++---- 10 files changed, 53 insertions(+), 35 deletions(-)