From patchwork Mon Apr 3 13:22:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pankaj Raghav X-Patchwork-Id: 7638 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2308005vqo; Mon, 3 Apr 2023 06:36:42 -0700 (PDT) X-Google-Smtp-Source: AKy350ZdNlRB4CF1Pf3fvFSDAMNzqLX55rnHo6Hs4vBN+1FzvV86ZPcc5JWwAvqdYMhDutZGa5rX X-Received: by 2002:a17:906:e094:b0:862:c1d5:ea1b with SMTP id gh20-20020a170906e09400b00862c1d5ea1bmr33098115ejb.8.1680529002668; Mon, 03 Apr 2023 06:36:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680529002; cv=none; d=google.com; s=arc-20160816; b=YEjOyNsiAF2gNb66D25KTXSvEAlWo2o1pwrZAzyZI3rsIspXBaVwV9yIsYcJbdoqQn Vksxoro8dJoTz7h35Tu0I5UL/qwCwCDfi06EnjnzvWJk7zqLFGMsIVdxxrUNh0m6tsb0 TLWHBhkD50Oys9Ebj6S763QKqn9UZPtEQOgPsK0562BoRPFaqEF0ywTrrF5cGifo9GrR 2cv+m0PjK77J6JYp8foR+slw5r8OXp64k0sI5HifCymv47cQZOsKCEo/Dr6xdDrIY4kj +IFfZSmGejtstv7g4a5YW68mvKUGD7NrSy/yc6pbqoCcu3bE1lAbMQsfltDf9KR+mG0M yeHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:cms-type:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature :dkim-filter; bh=ObjzntybczC70XqbBMD54+/zmilnxb/jIpNihW2+Pg8=; b=UiU6ClWjhfZ3fv5QbGxVhZnI2QBDwF9Bbd1V6FFMsnaZQtv/dkFVIfnE5cIOmsRA2e xqKf0RBylE/H/C8cXCMnejrZYnxnDhp9WU8wHholpFjBCuKhB4JoCHusYURuH9AqbtDc zY4i1p4Z2upQsJeeJsCavvUUWVefk+CqgWRJBuIlZSU/jVZMRUdriD9pGGeBaRgC0lNe HHLhfSB8v6bV9KztTJpZmffOHmAc2g0twhWr9B45OxpZEyAuPFVOwNZCfRs9eczo3nnI r0s/SfQpHhJjpMp+kvVrP04bTGHdQUnVEdWT8xl+xkjguNphrdvuYEu4yl4czRO7muab wUJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=PHrFnw8L; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g6-20020a170906594600b0093033954892si4178623ejr.512.2023.04.03.06.36.18; Mon, 03 Apr 2023 06:36:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b=PHrFnw8L; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232424AbjDCNWb (ORCPT + 99 others); Mon, 3 Apr 2023 09:22:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47842 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229473AbjDCNW3 (ORCPT ); Mon, 3 Apr 2023 09:22:29 -0400 Received: from mailout2.w1.samsung.com (mailout2.w1.samsung.com [210.118.77.12]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0EA32558A for ; Mon, 3 Apr 2023 06:22:26 -0700 (PDT) Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20230403132225euoutp0215237ba5ad2397c04f343e8453cdc313~Sb3HMgHf_1375913759euoutp02i for ; Mon, 3 Apr 2023 13:22:25 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20230403132225euoutp0215237ba5ad2397c04f343e8453cdc313~Sb3HMgHf_1375913759euoutp02i DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1680528145; bh=ObjzntybczC70XqbBMD54+/zmilnxb/jIpNihW2+Pg8=; h=From:To:Cc:Subject:Date:References:From; b=PHrFnw8L9nqSJlcUoH3v9Ir9e8GvPm21vpYA5JWvG99O4thmulUb9ock0LvcRWE0i hN2HNJI69WlEXJGypLBsc3X63dTXRrW/VzWphcii6Ne8lYmGaDZBrBfmJj5WC6PddF X/m82ghIxAUSXNrGFR9qreUfqCU5L5ckSUdxCOl8= Received: from eusmges1new.samsung.com (unknown [203.254.199.242]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20230403132223eucas1p29eb1d990b50c925c97adeffdd348e752~Sb3FrThuy1872218722eucas1p2l; Mon, 3 Apr 2023 13:22:23 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges1new.samsung.com (EUCPMTA) with SMTP id 69.F4.09503.F03DA246; Mon, 3 Apr 2023 14:22:23 +0100 (BST) Received: from eusmtrp2.samsung.com (unknown [182.198.249.139]) by eucas1p2.samsung.com (KnoxPortal) with ESMTPA id 20230403132223eucas1p28adb1d36d39add989d46e9f175c07986~Sb3FEGt8e2688526885eucas1p2R; Mon, 3 Apr 2023 13:22:23 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eusmtrp2.samsung.com (KnoxPortal) with ESMTP id 20230403132223eusmtrp2fe9c8c3ae0a35135ff22db5353c2d44c~Sb3FDYXo80200802008eusmtrp2H; Mon, 3 Apr 2023 13:22:23 +0000 (GMT) X-AuditID: cbfec7f2-ea5ff7000000251f-ad-642ad30f88e1 Received: from eusmtip1.samsung.com ( [203.254.199.221]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id EA.16.08862.F03DA246; Mon, 3 Apr 2023 14:22:23 +0100 (BST) Received: from localhost (unknown [106.210.248.30]) by eusmtip1.samsung.com (KnoxPortal) with ESMTPA id 20230403132222eusmtip1ceffd813a58e2638c75300bc28fb0544~Sb3E097ue2319123191eusmtip1D; Mon, 3 Apr 2023 13:22:22 +0000 (GMT) From: Pankaj Raghav To: axboe@kernel.dk, minchan@kernel.org, martin@omnibond.com, hubcap@omnibond.com, brauner@kernel.org, viro@zeniv.linux.org.uk, senozhatsky@chromium.org, akpm@linux-foundation.org, willy@infradead.org, hch@lst.de Cc: devel@lists.orangefs.org, mcgrof@kernel.org, linux-block@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, gost.dev@samsung.com, linux-fsdevel@vger.kernel.org, Pankaj Raghav Subject: [PATCH v2 0/5] remove page_endio() Date: Mon, 3 Apr 2023 15:22:16 +0200 Message-Id: <20230403132221.94921-1-p.raghav@samsung.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrOKsWRmVeSWpSXmKPExsWy7djP87r8l7VSDDqe61jMWb+GzWL13X42 i9eHPzFa7N88hcni5oGdTBYrVx9lsmi/28dksfeWtsWevSdZLC7vmsNmcW/Nf1aLk+v/M1vc mPCU0WLZ1/fsFp+XtrBb7N64iM3i/N/jrBa/f8xhcxDymN1wkcVj8wotj8tnSz02repk89j0 aRK7x4kZv1k8GqbeYvPYfbOBzePX7TusHn1bVjF6fN4k57HpyVumAJ4oLpuU1JzMstQifbsE row3V6cxFpzmrZj9/DB7A+M3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ator: CA X-RootMTR: 20230403132223eucas1p28adb1d36d39add989d46e9f175c07986 X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20230403132223eucas1p28adb1d36d39add989d46e9f175c07986 References: X-Spam-Status: No, score=-5.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1762162379777624433?= X-GMAIL-MSGID: =?utf-8?q?1762162379777624433?= It was decided to remove the page_endio() as per the previous RFC discussion[1] of this series and move that functionality into the caller itself. One of the side benefit of doing that is the callers have been modified to directly work on folios as page_endio() already worked on folios. mpage changes were tested with a simple boot testing. orangefs was tested by Mike Marshall (No code changes since he tested). A basic testing was performed for the zram changes with fio and writeback to a backing device. Changes since v1: - Always chain the IO to the parent as it can never be NULL (Minchan) - Added reviewed and tested by tags Changes since RFC 2[2]: - Call bio_put in zram bio end io handler (Still not Acked by hch[3]) - Call folio_set_error in mpage read endio error path (Willy) - Directly call folio->mapping in mpage write endio error path (Willy) [1] https://lore.kernel.org/linux-mm/ZBHcl8Pz2ULb4RGD@infradead.org/ [2] https://lore.kernel.org/linux-mm/20230322135013.197076-1-p.raghav@samsung.com/ [3] https://lore.kernel.org/linux-mm/8adb0770-6124-e11f-2551-6582db27ed32@samsung.com/ Pankaj Raghav (5): zram: always chain bio to the parent in read_from_bdev_async orangefs: use folios in orangefs_readahead mpage: split bi_end_io callback for reads and writes mpage: use folios in bio end_io handler filemap: remove page_endio() drivers/block/zram/zram_drv.c | 16 +++------------ fs/mpage.c | 38 +++++++++++++++++++++++++++-------- fs/orangefs/inode.c | 9 +++++---- include/linux/pagemap.h | 2 -- mm/filemap.c | 30 --------------------------- 5 files changed, 38 insertions(+), 57 deletions(-)