Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3289958pxk; Mon, 21 Sep 2020 09:48:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyW4B5zLsFkSsRl6Gc6HENjtee5GwZHT6oOCiLR6RsA2BPwcCf9v7hyqL9mXGK7s6/IZR1s X-Received: by 2002:a50:9355:: with SMTP id n21mr528263eda.237.1600706923446; Mon, 21 Sep 2020 09:48:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600706923; cv=none; d=google.com; s=arc-20160816; b=om55z7QQWHYMdTSoo6WkJSHxNWQzDHZ96YiX1zyBCOzN5e2yBMAr0yiWEJDzoEAIBn 9pB+OSKqBzMouvw7mIzTD3KuEZT2KBumIAzcFMnx2YeNAS0bsp+uUlxUkEEKynXMIcik stac2cTluSnBJBy3O1Z0uUkin2CI6JTRWIN2L8++GyfprGEcfn6uG1NcgGQKdoQLIuec TjTBEy8o/dcfkxh1MfgsgoV6AwPj2Li6U1FX1jwWWlBqAdmJeTHF3nyHSwaKj17WqDb7 arPOqwl6/2XU0Xh1NFkwaCeVdM/P7ZhSN1cQJbBYp7TanGIRsYYksGyDAQXK7ZX/VlXj SY8Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=9DbEBx0s9v5StdsViv8pFQGX93ZBR3vVlg9phWrofkE=; b=QhciUVblU136un7yKcMk8PN1qWG4CNlCC7kk+Tptrl3eYIasHSs8D/McpfGRYY4zjF JqowK5Sa+J0LUyxQ9QoPiz69wH63wIEaqkhZMFH6fHeLq2kxUOQkhe33BJ+GlxkjeeEX 9taBgn21anPRfosfTffibvLPKRtMBai817TRgxs27KURdiV4cVhCKIFGAm/DBJyxVW2q Ls5ODLsPYBtvUM5gCaMriaL/aA0wF+6Y8hWYsDCQX0Qz1i4P/ag851iZBuMzse+PbVCq 2v+laG0bW0Jblzcd6w/reeC5XFOjgrXYE2VrgIbTeYovRCRcswzu3b9qOCnwGmiokOxF aMhQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="nzXmq/n+"; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c15si8492351eds.227.2020.09.21.09.48.19; Mon, 21 Sep 2020 09:48:43 -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=@kernel.org header.s=default header.b="nzXmq/n+"; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729770AbgIUQr3 (ORCPT + 99 others); Mon, 21 Sep 2020 12:47:29 -0400 Received: from mail.kernel.org ([198.145.29.99]:54268 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728955AbgIUQrY (ORCPT ); Mon, 21 Sep 2020 12:47:24 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 275602223E; Mon, 21 Sep 2020 16:47:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1600706843; bh=IMKosS4jtrY102X+h47hgsWXTzCkkvPOzN0nyzCo/OE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nzXmq/n+RiFJ0CTJHu/qAdtSzq1G+USvBkrpCliY0vNMOBqv9fVX8EQDB2L1CkPAG jDaks8+ArcOjz2pxmOcM7QPnGOWzwR5kD0EgriU0/QFH6u3AYw//y+CEFKmkjg2d5R i7wr/ALAsu3sgAdsZGe3NiPNsH5hcHXrUvyY+0kk= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Geert Uytterhoeven , Naresh Kamboju , kernel test robot , Jan Kara , Dan Williams Subject: [PATCH 5.8 116/118] dax: Fix compilation for CONFIG_DAX && !CONFIG_FS_DAX Date: Mon, 21 Sep 2020 18:28:48 +0200 Message-Id: <20200921162041.784022784@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200921162036.324813383@linuxfoundation.org> References: <20200921162036.324813383@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jan Kara commit 88b67edd7247466bc47f01e1dc539b0d0d4b931e upstream. dax_supported() is defined whenever CONFIG_DAX is enabled. So dummy implementation should be defined only in !CONFIG_DAX case, not in !CONFIG_FS_DAX case. Fixes: e2ec51282545 ("dm: Call proper helper to determine dax support") Cc: Reported-by: Geert Uytterhoeven Reported-by: Naresh Kamboju Reported-by: kernel test robot Signed-off-by: Jan Kara Signed-off-by: Dan Williams Signed-off-by: Greg Kroah-Hartman --- include/linux/dax.h | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) --- a/include/linux/dax.h +++ b/include/linux/dax.h @@ -58,6 +58,8 @@ static inline void set_dax_synchronous(s { __set_dax_synchronous(dax_dev); } +bool dax_supported(struct dax_device *dax_dev, struct block_device *bdev, + int blocksize, sector_t start, sector_t len); /* * Check if given mapping is supported by the file / underlying device. */ @@ -104,6 +106,12 @@ static inline bool dax_synchronous(struc static inline void set_dax_synchronous(struct dax_device *dax_dev) { } +static inline bool dax_supported(struct dax_device *dax_dev, + struct block_device *bdev, int blocksize, sector_t start, + sector_t len) +{ + return false; +} static inline bool daxdev_mapping_supported(struct vm_area_struct *vma, struct dax_device *dax_dev) { @@ -130,8 +138,6 @@ static inline bool generic_fsdax_support return __generic_fsdax_supported(dax_dev, bdev, blocksize, start, sectors); } -bool dax_supported(struct dax_device *dax_dev, struct block_device *bdev, - int blocksize, sector_t start, sector_t len); static inline void fs_put_dax(struct dax_device *dax_dev) { @@ -158,13 +164,6 @@ static inline bool generic_fsdax_support { return false; } - -static inline bool dax_supported(struct dax_device *dax_dev, - struct block_device *bdev, int blocksize, sector_t start, - sector_t len) -{ - return false; -} static inline void fs_put_dax(struct dax_device *dax_dev) {