Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp2260025ybz; Sun, 26 Apr 2020 14:52:49 -0700 (PDT) X-Google-Smtp-Source: APiQypJOZz7qdOdnsfp3lUHeUJuTN/gCPjzKO760TwFvK3Ym5zhcB3rPeZAh4nQb9wu/Uyc57fxC X-Received: by 2002:a17:906:68cf:: with SMTP id y15mr16209654ejr.260.1587937968984; Sun, 26 Apr 2020 14:52:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587937968; cv=none; d=google.com; s=arc-20160816; b=Rn19kVGby6EAeF5i74Q4Pxf2gALiuwnBeIbV/4U3K1Ejge5pqi5KUONq6J1HOrckIQ usYmSb+PORCDNtA523Vbu2f2EvFm0gLj4z8qZAhjVD/GP+a6IjkBquWQ1dzBrbizWv4H Q2/5MSIlFpiieIFcov1/5Ja7uCmW7wol8V2V/tUdGCDgt53Wu4Bfe8Dr2AE4vQsVqHYF zI43dYbgJyqHTUOCzx9KJ88SSi9xp/MuYIw7pv/smZoMZpjSC3CrhksHTGqHpYd7iApq CexFftfFI68kEWV2Tvf2fv2EmWmfc4lxuZyJRIt/ApAiz4OHvNCV9tYaPI3J5Xjf/50A J8zw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=EVShq73FSgP/iPd7sAu/gmu6WN22oBRzfyOsdhWlH7E=; b=T6U2tkJadRrFxje4laog5zVZLodNJFwNZyVFgWivmWmAlpqArGBm9a8Vd3IPOBap4L lUX5CgSV9SHi8Ts+PjY+VFXdEUzE11dsiH0i1NFbFfPl7I5KqFUY6yC60nElf6VB7Zbq 77I7+/x+7Bjzx7NTXnf+hDiNNOYK0jSLTjjTKZOtk8Cf3/QBWZ4b2WmsYxMXDkV2W4z3 8RUz/r8uhITFhivLal9V8bS1/LpJR5h4aQWHss/QelwBIPbwYEgGZ9/sB8f6NzwYdabg qzFDQ43vhj/U9ASYZxLfAm7FU28Epx/AGq7bpkH25D3TgISsh9+1HvaVQqu65ApVqKXa tKyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cloud.ionos.com header.s=google header.b=PQHhUt4Q; 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 qq2si7264254ejb.426.2020.04.26.14.52.26; Sun, 26 Apr 2020 14:52:48 -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; dkim=pass header.i=@cloud.ionos.com header.s=google header.b=PQHhUt4Q; 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 S1726381AbgDZVuV (ORCPT + 99 others); Sun, 26 Apr 2020 17:50:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48568 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726380AbgDZVtx (ORCPT ); Sun, 26 Apr 2020 17:49:53 -0400 Received: from mail-ej1-x643.google.com (mail-ej1-x643.google.com [IPv6:2a00:1450:4864:20::643]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C9C77C09B050 for ; Sun, 26 Apr 2020 14:49:52 -0700 (PDT) Received: by mail-ej1-x643.google.com with SMTP id q8so12479976eja.2 for ; Sun, 26 Apr 2020 14:49:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cloud.ionos.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=EVShq73FSgP/iPd7sAu/gmu6WN22oBRzfyOsdhWlH7E=; b=PQHhUt4QYQ2lcD4jntv56PBlw8VdGuIt0HSBR79UTYajgyZK0++h/tPZu2kqq35XIu VQv5xha59bI/qnB/aXKoYi6BjZIINrM77x90Cgp6DjnmaHXEsm8ljA77zdoEMfWSD+fI 3f4bUgA12mwtiRNTtGM3Q13n5EcbuVHKwT8C2ih3iEjeaa9/d4NW/1V0gsbc1ikhBIDI /1LZ5Vzn6deZu3/DnXr2bR20wJJjvM+5C9qPDftdJdgSrwBaTLd+3F3ISpapRW24rpKR y2Lt4zcbxvN74rzniBO05POHASY5jnQlgLyAqNPyp9MtgdgEeV9UXduqimBOYxBDV6BO cn+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=EVShq73FSgP/iPd7sAu/gmu6WN22oBRzfyOsdhWlH7E=; b=umOuDypJHET/6hgmPC55dAbTMncT++gF+q32KdS17o/hbzAnDwSmNM/GnFPFCTOyIZ o9Ss1efnvbdWGqNUyQsRHLOTPd6AN6n+ZXqBpC/ZKS4r4udVJek5lvnZqe8my6EtESGv HvEhgxUspV2j59YswBE++dhJL5ayz387T1yIXgd9g1ZT2E6teZJSVYmu+4EvBQHG3VJh YlhTWx8K7huzbALkS63i7POMmB57qfoMi+K5Dzk0zlHoGXuNPLYKSQCnY666PHTAQiqq Ui/OsNlK+0Oh9fMpVp+ufiqXE6tHg5RgYH8QH/Q6X/gsA9MZuqegjK286fbNMJvcWlL1 7BGg== X-Gm-Message-State: AGi0Pub8qg6aouLlluBOKoVuM0Nrzdw8cDfsxiO7oA65IxQUdfzsXO9v kEhhpfEppaGmfX9FFN3IY1//7g== X-Received: by 2002:a17:906:7e5a:: with SMTP id z26mr17585240ejr.168.1587937791521; Sun, 26 Apr 2020 14:49:51 -0700 (PDT) Received: from ls00508.pb.local ([2001:1438:4010:2540:fab1:56ff:feab:56b1]) by smtp.gmail.com with ESMTPSA id ce18sm2270108ejb.61.2020.04.26.14.49.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Apr 2020 14:49:50 -0700 (PDT) From: Guoqing Jiang To: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Cc: hch@infradead.org, david@fromorbit.com, willy@infradead.org, Guoqing Jiang , Jaegeuk Kim , Chao Yu , linux-f2fs-devel@lists.sourceforge.net Subject: [RFC PATCH 5/9] f2fs: use set/clear_fs_page_private Date: Sun, 26 Apr 2020 23:49:21 +0200 Message-Id: <20200426214925.10970-6-guoqing.jiang@cloud.ionos.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200426214925.10970-1-guoqing.jiang@cloud.ionos.com> References: <20200426214925.10970-1-guoqing.jiang@cloud.ionos.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Since the new pair function is introduced, we can call them to clean the code in f2fs.h. Cc: Jaegeuk Kim Cc: Chao Yu Cc: linux-f2fs-devel@lists.sourceforge.net Signed-off-by: Guoqing Jiang --- fs/f2fs/f2fs.h | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/fs/f2fs/f2fs.h b/fs/f2fs/f2fs.h index ba470d5687fe..70ad8c51e0fc 100644 --- a/fs/f2fs/f2fs.h +++ b/fs/f2fs/f2fs.h @@ -3051,19 +3051,12 @@ static inline void f2fs_set_page_private(struct page *page, if (PagePrivate(page)) return; - get_page(page); - SetPagePrivate(page); - set_page_private(page, data); + set_fs_page_private(page, (void *)data); } static inline void f2fs_clear_page_private(struct page *page) { - if (!PagePrivate(page)) - return; - - set_page_private(page, 0); - ClearPagePrivate(page); - f2fs_put_page(page, 0); + clear_fs_page_private(page); } /* -- 2.17.1