From patchwork Thu Oct 19 14:21:23 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 116400 Delivered-To: patch@linaro.org Received: by 10.140.22.164 with SMTP id 33csp555388qgn; Thu, 19 Oct 2017 07:22:21 -0700 (PDT) X-Google-Smtp-Source: ABhQp+TQcQz55NqD2eg393R4K6euMwq0pGLGRpqdPVIk5Bg9p7ZUICu9rEZO3Nm/5v62Z28mUTcV X-Received: by 10.101.76.139 with SMTP id m11mr1541948pgt.103.1508422941229; Thu, 19 Oct 2017 07:22:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1508422941; cv=none; d=google.com; s=arc-20160816; b=D/6tFpmtSF00XY5KsET+aUIzHFkmsNmCgUrx4spcFzvhdjfHSCB4eoQyb62rNfeV2V GyPHHRO0oVT46e+s1iSyuVEV13UJmXlmqATQ0c6kR13qE9IgcojQ0r717o5El1nzMOiF 6YpI7aWqh4ZLuUC0t7L4CNSaP8NXgXf8hutO9LiwMCdqMYziKSL+A2atd3ReY5UvCHok fpY3E4JXGs2Yy5lvr1w1hThaIeT+l/k0oS0CueIaVHkUR3mVJuVegwvsij652ccQ15d7 J9mUe33ktLYTczMM/Fohir+QtvYXncjMzccsClAHpSvExsO2G0PG3VX3Qi0yrw9sZL4X nReQ== 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=+plr8y8owU1skCHrZuCW+EDP3VPH+JdqYeNtf082nRA=; b=IhfPApamW2FymWrFUFkB1Na8ZCWC12RHyYnVG8ZXGe7pKNxUQBw5fIogV+G3vEX4IU X56g5EK0wz4OnsqVnhuz+Y000h6lX4Ir+1EAEPRbIOFAbRNH9QEwaBK2A6JbMhk8tvp3 sMr1XAwVmrfg6CDR0upcZFtowzq34gtPkTc/LLNn+TimlpHTxosxh5SCpscctx4HeOcU l3RwulCdVRB3NnVS+zYZdOrB7pfN29q6ZAer7nqfTMxSrPK8EbrRQFGG/4tl2IS5nWdj YslqHuQYesipN4SWKQ30j9whuoTL+OCclAfo1n9tOFVm1Gv+6FU8h+GlpBHmICX5gk/u I8jA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=PmXZp4li; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-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 e12si9725220plj.21.2017.10.19.07.22.21; Thu, 19 Oct 2017 07:22:21 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of stable-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=PmXZp4li; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=stable-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754208AbdJSOWU (ORCPT + 9 others); Thu, 19 Oct 2017 10:22:20 -0400 Received: from bombadil.infradead.org ([65.50.211.133]:43831 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753984AbdJSOWS (ORCPT ); Thu, 19 Oct 2017 10:22:18 -0400 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=+plr8y8owU1skCHrZuCW+EDP3VPH+JdqYeNtf082nRA=; b=PmXZp4li7zRkV4gEDRltNp/OJ 2flhtz+Gd32pMM7U3+EIjzWEZw8lxPCWrIBxndiVvj8aBbKXb1n8tGe92g7o/sB5Icxbt38Y+QHW5 jO8Wp0XCW1Ge2qnYAW/010zf2kJ9E2De9jeRCu+SISdAzrcoLOkT/twIN/yXHcZLPhKAm5YnUaebX WJTu4Gu3atcdyq/am/DWwosHMxavsu2TKNIvjLlQEPW43aRXXdPO3FG6EKp5/I2ozMtYKx4sFLJfs ak+iG8jHccj1vNYupB0mEzH1Wv/zR1BnEceUjRFz3fTAHDa6f/5S/2rrb5ielgVh2Oo4hG2An7mfW cEyz2yXRg==; Received: from clnet-p099-196.ikbnet.co.at ([83.175.99.196] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.87 #1 (Red Hat Linux)) id 1e5BiD-0004h6-Fw; Thu, 19 Oct 2017 14:22:17 +0000 From: Christoph Hellwig To: stable@vger.kernel.org Cc: linux-xfs@vger.kernel.org, Arnd Bergmann , "Darrick J . Wong" Subject: [PATCH 18/18] xfs: move two more RT specific functions into CONFIG_XFS_RT Date: Thu, 19 Oct 2017 16:21:23 +0200 Message-Id: <20171019142123.18109-19-hch@lst.de> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20171019142123.18109-1-hch@lst.de> References: <20171019142123.18109-1-hch@lst.de> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Arnd Bergmann commit 785545c8982604fe3ba79d16409e83993be77d5e upstream. The last cleanup introduced two harmless warnings: fs/xfs/xfs_fsmap.c:480:1: warning: '__xfs_getfsmap_rtdev' defined but not used fs/xfs/xfs_fsmap.c:372:1: warning: 'xfs_getfsmap_rtdev_rtbitmap_helper' defined but not used This moves those two functions as well. Fixes: bb9c2e543325 ("xfs: move more RT specific code under CONFIG_XFS_RT") Signed-off-by: Arnd Bergmann Reviewed-by: Brian Foster Acked-by: Geert Uytterhoeven Reviewed-by: Darrick J. Wong Signed-off-by: Darrick J. Wong --- fs/xfs/xfs_fsmap.c | 48 ++++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 24 deletions(-) -- 2.14.2 diff --git a/fs/xfs/xfs_fsmap.c b/fs/xfs/xfs_fsmap.c index 560e0b40ac1b..43cfc07996a4 100644 --- a/fs/xfs/xfs_fsmap.c +++ b/fs/xfs/xfs_fsmap.c @@ -367,29 +367,6 @@ xfs_getfsmap_datadev_helper( return xfs_getfsmap_helper(cur->bc_tp, info, rec, rec_daddr); } -/* Transform a rtbitmap "record" into a fsmap */ -STATIC int -xfs_getfsmap_rtdev_rtbitmap_helper( - struct xfs_trans *tp, - struct xfs_rtalloc_rec *rec, - void *priv) -{ - struct xfs_mount *mp = tp->t_mountp; - struct xfs_getfsmap_info *info = priv; - struct xfs_rmap_irec irec; - xfs_daddr_t rec_daddr; - - rec_daddr = XFS_FSB_TO_BB(mp, rec->ar_startblock); - - irec.rm_startblock = rec->ar_startblock; - irec.rm_blockcount = rec->ar_blockcount; - irec.rm_owner = XFS_RMAP_OWN_NULL; /* "free" */ - irec.rm_offset = 0; - irec.rm_flags = 0; - - return xfs_getfsmap_helper(tp, info, &irec, rec_daddr); -} - /* Transform a bnobt irec into a fsmap */ STATIC int xfs_getfsmap_datadev_bnobt_helper( @@ -475,6 +452,30 @@ xfs_getfsmap_logdev( return xfs_getfsmap_helper(tp, info, &rmap, 0); } +#ifdef CONFIG_XFS_RT +/* Transform a rtbitmap "record" into a fsmap */ +STATIC int +xfs_getfsmap_rtdev_rtbitmap_helper( + struct xfs_trans *tp, + struct xfs_rtalloc_rec *rec, + void *priv) +{ + struct xfs_mount *mp = tp->t_mountp; + struct xfs_getfsmap_info *info = priv; + struct xfs_rmap_irec irec; + xfs_daddr_t rec_daddr; + + rec_daddr = XFS_FSB_TO_BB(mp, rec->ar_startblock); + + irec.rm_startblock = rec->ar_startblock; + irec.rm_blockcount = rec->ar_blockcount; + irec.rm_owner = XFS_RMAP_OWN_NULL; /* "free" */ + irec.rm_offset = 0; + irec.rm_flags = 0; + + return xfs_getfsmap_helper(tp, info, &irec, rec_daddr); +} + /* Execute a getfsmap query against the realtime device. */ STATIC int __xfs_getfsmap_rtdev( @@ -521,7 +522,6 @@ __xfs_getfsmap_rtdev( return query_fn(tp, info); } -#ifdef CONFIG_XFS_RT /* Actually query the realtime bitmap. */ STATIC int xfs_getfsmap_rtdev_rtbitmap_query(