Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp6041443ybp; Tue, 15 Oct 2019 08:45:27 -0700 (PDT) X-Google-Smtp-Source: APXvYqyf3MHH1FY5Y/0oYBnfd0SniUsXpkT5LqRBCh8Af5prWhDCyyOggrXgV9+rvgakGVKNKv9+ X-Received: by 2002:a05:6402:296:: with SMTP id l22mr34394104edv.86.1571154327383; Tue, 15 Oct 2019 08:45:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571154327; cv=none; d=google.com; s=arc-20160816; b=svFV2CpX8k+cjJMXyUrqXoKGtMDMbmw4iqYoiOMcFQAXZIgghJfmgtVP2PRcpeN146 RemtVN6Gfgf6RxOsqV0rhcrtDohnzSKUnYltR//+YHpo5Td2p35u3/q08uhQsMO6lgJD +2jNhSBRhY0diuuPtTLR09kIA8odlpXY4dCrag1EJ+wuXZygBj445mmZKMcvq7GYpANV F1nWPcssFk9t6J1XVWmBJBGIvcpQ0eYRQkC1YrKqMYKDK3+mwoKwtaI/p8fwIePuLGVk nBxbdFRLyn9biQPORrq5GXzBLduIlhn+L484sgdEK3h8C/SreqVZD3p0c+iKYsShe4jt YbNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=UQClik6/4MZfQYaE239NcvruKho6tpvdEmg1H7mZrSs=; b=ep3QWbUjMuAPQhDnp3g1qyOxPQzAYntCJQ+n5MMxHHJjjmBKvw6a5cBfkqtbe2M81n F3x6r8Sbz+uUSwA3+iUEto/wqIJGCDPtZWrQqgMd2XuqNB2yjNhkowt5ZC+aRXqe2IUr +yeb8/FddYYNWyT7ep5RvEOvEGY32qGWDVw1BjkiJmpfXWh6zNwHPVFeJzHaRWsMdXbj /K8cL9XTtJ4o+Fn5aacwSyIXhWdivjBTbCJ1MFE7Ud+8yPERiGxpeBXGvw7CuPimqyV1 tolk8SmIExcjNY+LRe0bcPlBOsXEquU+cIYmgXYsd0CcTKrQr3yLcMHpPRJJQLv/YR7d ookQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=dysEGvQf; 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 y28si11270554edb.162.2019.10.15.08.45.04; Tue, 15 Oct 2019 08:45:27 -0700 (PDT) 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=dysEGvQf; 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 S2387718AbfJOPo0 (ORCPT + 99 others); Tue, 15 Oct 2019 11:44:26 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:48158 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387650AbfJOPoZ (ORCPT ); Tue, 15 Oct 2019 11:44:25 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type: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=UQClik6/4MZfQYaE239NcvruKho6tpvdEmg1H7mZrSs=; b=dysEGvQfhqOCtu8JcqvS9C3IG/ 46Sv4IwEQBvvb+3AGGCpfBXzZUVSN+G7UBfIf8NhtkIWcgt8Mb0ZBfOFaQ2t7ZnJhlhKSGtBPkHnY nkrUYBK+JDWRBFW7diyu92B9MxDBpBhggj9+cjfvOM9+AsvLfaLWt+QAMNwGoWeUuPuVfgPqXz8h2 A0flPM18IFG9YoIgt1I7LhvDcQg/sFX47xknOft3AShZZMKLGBRqoWFTA9TXqOj+BBIuLoukv958a NchD1sBJjd7w2d0VScOU7zrvRLLOQQSM7VVuowiww0aHWPXAACZpUbVpwc4zuasbUMc38B9WRI84I kdafBvDw==; Received: from [2001:4bb8:18c:d7b:c70:4a89:bc61:3] (helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1iKOzn-00080H-BY; Tue, 15 Oct 2019 15:44:23 +0000 From: Christoph Hellwig To: "Darrick J . Wong" Cc: Damien Le Moal , Andreas Gruenbacher , linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, Carlos Maiolino Subject: [PATCH 11/12] iomap: move struct iomap_page out of iomap.h Date: Tue, 15 Oct 2019 17:43:44 +0200 Message-Id: <20191015154345.13052-12-hch@lst.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191015154345.13052-1-hch@lst.de> References: <20191015154345.13052-1-hch@lst.de> 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 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Now that all the writepage code is in the iomap code there is no need to keep this structure public. Signed-off-by: Christoph Hellwig Reviewed-by: Carlos Maiolino Reviewed-by: Darrick J. Wong --- fs/iomap/buffered-io.c | 17 +++++++++++++++++ include/linux/iomap.h | 17 ----------------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/fs/iomap/buffered-io.c b/fs/iomap/buffered-io.c index 76e72576f307..c57acc3d3120 100644 --- a/fs/iomap/buffered-io.c +++ b/fs/iomap/buffered-io.c @@ -21,6 +21,23 @@ #include "../internal.h" +/* + * Structure allocated for each page when block size < PAGE_SIZE to track + * sub-page uptodate status and I/O completions. + */ +struct iomap_page { + atomic_t read_count; + atomic_t write_count; + DECLARE_BITMAP(uptodate, PAGE_SIZE / 512); +}; + +static inline struct iomap_page *to_iomap_page(struct page *page) +{ + if (page_has_private(page)) + return (struct iomap_page *)page_private(page); + return NULL; +} + static struct bio_set iomap_ioend_bioset; static struct iomap_page * diff --git a/include/linux/iomap.h b/include/linux/iomap.h index 0b399718c387..46ce730b1590 100644 --- a/include/linux/iomap.h +++ b/include/linux/iomap.h @@ -134,23 +134,6 @@ loff_t iomap_apply(struct inode *inode, loff_t pos, loff_t length, unsigned flags, const struct iomap_ops *ops, void *data, iomap_actor_t actor); -/* - * Structure allocate for each page when block size < PAGE_SIZE to track - * sub-page uptodate status and I/O completions. - */ -struct iomap_page { - atomic_t read_count; - atomic_t write_count; - DECLARE_BITMAP(uptodate, PAGE_SIZE / 512); -}; - -static inline struct iomap_page *to_iomap_page(struct page *page) -{ - if (page_has_private(page)) - return (struct iomap_page *)page_private(page); - return NULL; -} - ssize_t iomap_file_buffered_write(struct kiocb *iocb, struct iov_iter *from, const struct iomap_ops *ops); int iomap_readpage(struct page *page, const struct iomap_ops *ops); -- 2.20.1