Received: by 10.223.185.116 with SMTP id b49csp4140215wrg; Mon, 19 Feb 2018 11:54:27 -0800 (PST) X-Google-Smtp-Source: AH8x226tq8phxvzGTrrIMqAupuxE6DOA3PFLGvqpIer8rjfFh3k8RYZchwr4A2QEyogAyAybAKz8 X-Received: by 10.98.94.71 with SMTP id s68mr15631606pfb.135.1519070067387; Mon, 19 Feb 2018 11:54:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519070067; cv=none; d=google.com; s=arc-20160816; b=T11VnVC4w4OYS40PnJkVxCWUo2qVCA+/yJsOWbu/S3h8ugxLVN58x6kW49snNc/a1d bAE+hV8yus/13TU9fEBY2uWmVXNN+Ij9pmQcxEZUm2oVdG1sS2k0cXkYl2qYLLnY5o3+ A/LaJi92DehvZkZmuBYoCjD+Q0HeQVNgVVGH8AJB6XHLvHxhJxv/C+NHcpE+zxGmlvSc XqmTONTCXg7cjL240gY1w/LI86NaC2ApjXMrZcDm00JbsHsZ5mXp5YDQAUhn62zYajjm aATEwtQaf5LtG71MIrEXKS4f4f+dWljgW86wY1whVNkz6DNhsz5cElCkVAeVoszpI7Gm LHgg== 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:arc-authentication-results; bh=ycIvFSFPZbnn8cZkpJ5kRnBkAPj+SBqL7nOKiYR/ssc=; b=Bmdmq3gRRqHnD9FDzQgLSh/WduLjCx/tmmw4J6Bhfxk3XC1qPw2PvkWVV710zZToFj xkYaX8wnlwqNoZlbXpUrxZtdEWNzamxLP3mTnzNyjl0heJn3Gv/ZWuI2FRAQMV1THHml S4obwEnGsui+s7LvO+3+90yv+a1IAJaE13ZfCpJ6VXcCGcryDWtFrt91rwbMCe93mpH+ a5tiokLEiESUi+TGYMOBj2Ym62cBuRutuN4B3+tM7VsJ7xvnGWF26CdlmN1mqP0SuQwS RaC8CW5laRSNE2Xyeg3YCVmmPb0T0Fvcqhb4O+o1X/o0exB0dAX33V7AJzfIReDHmh2G r+hA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=e1BmqqVu; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d2si4074242pgc.758.2018.02.19.11.54.13; Mon, 19 Feb 2018 11:54:27 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=e1BmqqVu; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753978AbeBSTwW (ORCPT + 99 others); Mon, 19 Feb 2018 14:52:22 -0500 Received: from bombadil.infradead.org ([198.137.202.133]:44942 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753717AbeBSTqZ (ORCPT ); Mon, 19 Feb 2018 14:46:25 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=References:In-Reply-To:Message-Id: Date:Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=ycIvFSFPZbnn8cZkpJ5kRnBkAPj+SBqL7nOKiYR/ssc=; b=e1BmqqVutkFf7l2Bsb019m81Y l00I3iRFJ3oyy5EMfH0C8p06F7vqAu9wmlefvJ2S6N1OetiOWsWCvXDNiYORsZm4UXplSjcPEkNKL qK3oWJMi48clDdYu/lg4Sc4tISz+z66bwgAS8aPgx8XjP04u1PTBqT8ABV5NURWucVYcGNFpkr7d6 mxQn0zg0UAWMdpgIk08MieS06hchDhLkAhbbdWu9IhzwrY/47WPRTj/2T2OdpsadFoyPJlpjKMdXO kaTrjSMMVFs2o4mOzUH6gYEQ7X8ywEfXzEWbzu5F8cKPxE1ZnvBTKbTfU0IYjZ+LEM55y0BoXfWNc RF+O47tHA==; Received: from willy by bombadil.infradead.org with local (Exim 4.89 #1 (Red Hat Linux)) id 1enrOK-0001tA-5N; Mon, 19 Feb 2018 19:46:24 +0000 From: Matthew Wilcox To: Andrew Morton Cc: Matthew Wilcox , linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org Subject: [PATCH v7 43/61] pagevec: Use xa_tag_t Date: Mon, 19 Feb 2018 11:45:38 -0800 Message-Id: <20180219194556.6575-44-willy@infradead.org> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20180219194556.6575-1-willy@infradead.org> References: <20180219194556.6575-1-willy@infradead.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Matthew Wilcox Removes sparse warnings. Signed-off-by: Matthew Wilcox --- fs/btrfs/extent_io.c | 4 ++-- fs/ext4/inode.c | 2 +- fs/f2fs/data.c | 2 +- fs/gfs2/aops.c | 2 +- include/linux/pagevec.h | 8 +++++--- mm/swap.c | 4 ++-- 6 files changed, 12 insertions(+), 10 deletions(-) diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index 1f2739702518..54cef60dd79b 100644 --- a/fs/btrfs/extent_io.c +++ b/fs/btrfs/extent_io.c @@ -3789,7 +3789,7 @@ int btree_write_cache_pages(struct address_space *mapping, pgoff_t index; pgoff_t end; /* Inclusive */ int scanned = 0; - int tag; + xa_tag_t tag; pagevec_init(&pvec); if (wbc->range_cyclic) { @@ -3914,7 +3914,7 @@ static int extent_write_cache_pages(struct address_space *mapping, pgoff_t done_index; int range_whole = 0; int scanned = 0; - int tag; + xa_tag_t tag; /* * We have to hold onto the inode so that ordered extents can do their diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index c94780075b04..40000331fe5b 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4/inode.c @@ -2615,7 +2615,7 @@ static int mpage_prepare_extent_to_map(struct mpage_da_data *mpd) long left = mpd->wbc->nr_to_write; pgoff_t index = mpd->first_page; pgoff_t end = mpd->last_page; - int tag; + xa_tag_t tag; int i, err = 0; int blkbits = mpd->inode->i_blkbits; ext4_lblk_t lblk; diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c index 4eee39befc67..ce029060acd0 100644 --- a/fs/f2fs/data.c +++ b/fs/f2fs/data.c @@ -1848,7 +1848,7 @@ static int f2fs_write_cache_pages(struct address_space *mapping, pgoff_t last_idx = ULONG_MAX; int cycled; int range_whole = 0; - int tag; + xa_tag_t tag; pagevec_init(&pvec); diff --git a/fs/gfs2/aops.c b/fs/gfs2/aops.c index 2f725b4a386b..e85ed63b87d6 100644 --- a/fs/gfs2/aops.c +++ b/fs/gfs2/aops.c @@ -371,7 +371,7 @@ static int gfs2_write_cache_jdata(struct address_space *mapping, pgoff_t done_index; int cycled; int range_whole = 0; - int tag; + xa_tag_t tag; pagevec_init(&pvec); if (wbc->range_cyclic) { diff --git a/include/linux/pagevec.h b/include/linux/pagevec.h index 6dc456ac6136..955bd6425903 100644 --- a/include/linux/pagevec.h +++ b/include/linux/pagevec.h @@ -9,6 +9,8 @@ #ifndef _LINUX_PAGEVEC_H #define _LINUX_PAGEVEC_H +#include + /* 15 pointers + header align the pagevec structure to a power of two */ #define PAGEVEC_SIZE 15 @@ -40,12 +42,12 @@ static inline unsigned pagevec_lookup(struct pagevec *pvec, unsigned pagevec_lookup_range_tag(struct pagevec *pvec, struct address_space *mapping, pgoff_t *index, pgoff_t end, - int tag); + xa_tag_t tag); unsigned pagevec_lookup_range_nr_tag(struct pagevec *pvec, struct address_space *mapping, pgoff_t *index, pgoff_t end, - int tag, unsigned max_pages); + xa_tag_t tag, unsigned max_pages); static inline unsigned pagevec_lookup_tag(struct pagevec *pvec, - struct address_space *mapping, pgoff_t *index, int tag) + struct address_space *mapping, pgoff_t *index, xa_tag_t tag) { return pagevec_lookup_range_tag(pvec, mapping, index, (pgoff_t)-1, tag); } diff --git a/mm/swap.c b/mm/swap.c index f62c5c7198f2..10c94ff9e542 100644 --- a/mm/swap.c +++ b/mm/swap.c @@ -990,7 +990,7 @@ EXPORT_SYMBOL(pagevec_lookup_range); unsigned pagevec_lookup_range_tag(struct pagevec *pvec, struct address_space *mapping, pgoff_t *index, pgoff_t end, - int tag) + xa_tag_t tag) { pvec->nr = find_get_pages_range_tag(mapping, index, end, tag, PAGEVEC_SIZE, pvec->pages); @@ -1000,7 +1000,7 @@ EXPORT_SYMBOL(pagevec_lookup_range_tag); unsigned pagevec_lookup_range_nr_tag(struct pagevec *pvec, struct address_space *mapping, pgoff_t *index, pgoff_t end, - int tag, unsigned max_pages) + xa_tag_t tag, unsigned max_pages) { pvec->nr = find_get_pages_range_tag(mapping, index, end, tag, min_t(unsigned int, max_pages, PAGEVEC_SIZE), pvec->pages); -- 2.16.1