From patchwork Thu Oct 7 22:30:17 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Wysochanski X-Patchwork-Id: 12543687 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B0C3DC433EF for ; Thu, 7 Oct 2021 22:30:48 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 91D0961058 for ; Thu, 7 Oct 2021 22:30:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238370AbhJGWcl (ORCPT ); Thu, 7 Oct 2021 18:32:41 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:49733 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237789AbhJGWcl (ORCPT ); Thu, 7 Oct 2021 18:32:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1633645846; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:in-reply-to:in-reply-to:references:references; bh=V45i+FwReE6kj3/yFzuyX5hCruxHTg+35FI4Ypm3l6I=; b=YRoquI+6sqJ0KjTD3A5dFkPSveaSeVi5hzNVuDr7iHR20d4R2VP0BQy5vGcebMKOmPBOLe 7YzdSdoGnKveo79h4z4KafIrKuzP/L3AAgZmuseh7hjn4lXO1QLyG5hoaLiuEpspBJIxvT yjLNsQF3/fg4EueBH9G/SAKVU3n1gx4= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-392-ZHRRVDZrPcSmxYE6wX_CXA-1; Thu, 07 Oct 2021 18:30:45 -0400 X-MC-Unique: ZHRRVDZrPcSmxYE6wX_CXA-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 91E52801AC3; Thu, 7 Oct 2021 22:30:44 +0000 (UTC) Received: from dwysocha.rdu.csb (unknown [10.22.8.139]) by smtp.corp.redhat.com (Postfix) with ESMTPS id F36CE5D9C6; Thu, 7 Oct 2021 22:30:43 +0000 (UTC) From: Dave Wysochanski To: Trond Myklebust , Anna Schumaker , David Howells Cc: linux-cachefs@redhat.com, linux-nfs@vger.kernel.org Subject: [PATCH v2 1/7] NFS: Use nfs_i_fscache() consistently within NFS fscache code Date: Thu, 7 Oct 2021 18:30:17 -0400 Message-Id: <1633645823-31235-2-git-send-email-dwysocha@redhat.com> In-Reply-To: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> References: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org The nfs_i_fscache() is the API defined to check whether fscache is enabled on an NFS inode or not, so use it consistently through the code. Signed-off-by: Dave Wysochanski --- fs/nfs/fscache.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fs/nfs/fscache.h b/fs/nfs/fscache.h index 679055720dae..f4deea2908e9 100644 --- a/fs/nfs/fscache.h +++ b/fs/nfs/fscache.h @@ -105,7 +105,7 @@ extern void __nfs_read_completion_to_fscache(struct nfs_pgio_header *hdr, static inline int nfs_readpage_from_fscache(struct inode *inode, struct page *page) { - if (NFS_I(inode)->fscache) + if (nfs_i_fscache(inode)) return __nfs_readpage_from_fscache(inode, page); return -ENOBUFS; } @@ -117,7 +117,7 @@ static inline int nfs_readpage_from_fscache(struct inode *inode, static inline void nfs_readpage_to_fscache(struct inode *inode, struct page *page) { - if (NFS_I(inode)->fscache) + if (nfs_i_fscache(inode)) __nfs_readpage_to_fscache(inode, page); } @@ -126,7 +126,7 @@ static inline void nfs_readpage_to_fscache(struct inode *inode, */ static inline void nfs_fscache_invalidate(struct inode *inode) { - fscache_invalidate(NFS_I(inode)->fscache); + fscache_invalidate(nfs_i_fscache(inode)); } /* @@ -134,7 +134,7 @@ static inline void nfs_fscache_invalidate(struct inode *inode) */ static inline void nfs_fscache_wait_on_invalidate(struct inode *inode) { - fscache_wait_on_invalidate(NFS_I(inode)->fscache); + fscache_wait_on_invalidate(nfs_i_fscache(inode)); } /* From patchwork Thu Oct 7 22:30:18 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Wysochanski X-Patchwork-Id: 12543689 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8D094C4332F for ; Thu, 7 Oct 2021 22:30:49 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 73F1461058 for ; Thu, 7 Oct 2021 22:30:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237789AbhJGWcm (ORCPT ); Thu, 7 Oct 2021 18:32:42 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:57239 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237851AbhJGWcm (ORCPT ); Thu, 7 Oct 2021 18:32:42 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1633645847; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:in-reply-to:in-reply-to:references:references; bh=VwP53MOpEB/A+FJpyjVAhqtYpx2FWz2rkQMWE88KFTw=; b=VCdAn4nGbN0ODOQHvT2hXNZjgT+kvSYy8p/8txed+nbPkWYiTjMjeaCLmsUvPA7L18XC1/ yYfkxGEr+9ElNnTgBt/nhuW++w9zSjTn0bJ0GeWpaqGDwQD9K8EnxsWNx6aWGs+CsKS8zA +GpeakMqk8QWRjBZlHxrDbHb15bNOIw= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-380-moFmOo0lMDGtz7gnWylcfA-1; Thu, 07 Oct 2021 18:30:46 -0400 X-MC-Unique: moFmOo0lMDGtz7gnWylcfA-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 527D91005E53; Thu, 7 Oct 2021 22:30:45 +0000 (UTC) Received: from dwysocha.rdu.csb (unknown [10.22.8.139]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B59155D9C6; Thu, 7 Oct 2021 22:30:44 +0000 (UTC) From: Dave Wysochanski To: Trond Myklebust , Anna Schumaker , David Howells Cc: linux-cachefs@redhat.com, linux-nfs@vger.kernel.org Subject: [PATCH v2 2/7] NFS: Cleanup usage of nfs_inode in fscache interface and handle i_size properly Date: Thu, 7 Oct 2021 18:30:18 -0400 Message-Id: <1633645823-31235-3-git-send-email-dwysocha@redhat.com> In-Reply-To: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> References: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org A number of places in the fscache interface used nfs_inode when inode could be used, simplifying the code. Also, handle the read of i_size properly by utilizing the i_size_read() interface. Signed-off-by: Dave Wysochanski --- fs/nfs/fscache.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/fs/nfs/fscache.c b/fs/nfs/fscache.c index 68e266a37675..6764938eca2d 100644 --- a/fs/nfs/fscache.c +++ b/fs/nfs/fscache.c @@ -226,16 +226,16 @@ void nfs_fscache_release_super_cookie(struct super_block *sb) } static void nfs_fscache_update_auxdata(struct nfs_fscache_inode_auxdata *auxdata, - struct nfs_inode *nfsi) + struct inode *inode) { memset(auxdata, 0, sizeof(*auxdata)); - auxdata->mtime_sec = nfsi->vfs_inode.i_mtime.tv_sec; - auxdata->mtime_nsec = nfsi->vfs_inode.i_mtime.tv_nsec; - auxdata->ctime_sec = nfsi->vfs_inode.i_ctime.tv_sec; - auxdata->ctime_nsec = nfsi->vfs_inode.i_ctime.tv_nsec; + auxdata->mtime_sec = inode->i_mtime.tv_sec; + auxdata->mtime_nsec = inode->i_mtime.tv_nsec; + auxdata->ctime_sec = inode->i_ctime.tv_sec; + auxdata->ctime_nsec = inode->i_ctime.tv_nsec; - if (NFS_SERVER(&nfsi->vfs_inode)->nfs_client->rpc_ops->version == 4) - auxdata->change_attr = inode_peek_iversion_raw(&nfsi->vfs_inode); + if (NFS_SERVER(inode)->nfs_client->rpc_ops->version == 4) + auxdata->change_attr = inode_peek_iversion_raw(inode); } /* @@ -251,13 +251,13 @@ void nfs_fscache_init_inode(struct inode *inode) if (!(nfss->fscache && S_ISREG(inode->i_mode))) return; - nfs_fscache_update_auxdata(&auxdata, nfsi); + nfs_fscache_update_auxdata(&auxdata, inode); nfsi->fscache = fscache_acquire_cookie(NFS_SB(inode->i_sb)->fscache, &nfs_fscache_inode_object_def, nfsi->fh.data, nfsi->fh.size, &auxdata, sizeof(auxdata), - nfsi, nfsi->vfs_inode.i_size, false); + nfsi, i_size_read(inode), false); } /* @@ -271,7 +271,7 @@ void nfs_fscache_clear_inode(struct inode *inode) dfprintk(FSCACHE, "NFS: clear cookie (0x%p/0x%p)\n", nfsi, cookie); - nfs_fscache_update_auxdata(&auxdata, nfsi); + nfs_fscache_update_auxdata(&auxdata, inode); fscache_relinquish_cookie(cookie, &auxdata, false); nfsi->fscache = NULL; } @@ -311,7 +311,7 @@ void nfs_fscache_open_file(struct inode *inode, struct file *filp) if (!fscache_cookie_valid(cookie)) return; - nfs_fscache_update_auxdata(&auxdata, nfsi); + nfs_fscache_update_auxdata(&auxdata, inode); if (inode_is_open_for_write(inode)) { dfprintk(FSCACHE, "NFS: nfsi 0x%p disabling cache\n", nfsi); @@ -319,7 +319,7 @@ void nfs_fscache_open_file(struct inode *inode, struct file *filp) fscache_disable_cookie(cookie, &auxdata, true); } else { dfprintk(FSCACHE, "NFS: nfsi 0x%p enabling cache\n", nfsi); - fscache_enable_cookie(cookie, &auxdata, nfsi->vfs_inode.i_size, + fscache_enable_cookie(cookie, &auxdata, i_size_read(inode), nfs_fscache_can_enable, inode); if (fscache_cookie_enabled(cookie)) set_bit(NFS_INO_FSCACHE, &NFS_I(inode)->flags); From patchwork Thu Oct 7 22:30:19 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Wysochanski X-Patchwork-Id: 12543695 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 87EB9C433EF for ; Thu, 7 Oct 2021 22:30:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 72E08610C8 for ; Thu, 7 Oct 2021 22:30:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238673AbhJGWcs (ORCPT ); Thu, 7 Oct 2021 18:32:48 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:27133 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233370AbhJGWcs (ORCPT ); Thu, 7 Oct 2021 18:32:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1633645853; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:in-reply-to:in-reply-to:references:references; bh=mz2hPiZW43Ml1iJmYyn9808jlklT92BinqlidQSptIE=; b=aQm/GT4DuZfbWtIjPmGYlo9E2rZNdbG6x/flMHmrsCo8J5kZ3XPx6MdrqLK/2jDB/9OjH6 dowdqKqkImbndrfNdMXDj1XEwtM5aBKG+OmKtrZn38lBOpPcr0IkcirKBBWnR53gkvR1sZ MBO/EeRAFnEZVSZtM4Pqll8jEVIFL7Y= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-441-Ts52FDTXNLykI84-ijJ7vA-1; Thu, 07 Oct 2021 18:30:47 -0400 X-MC-Unique: Ts52FDTXNLykI84-ijJ7vA-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 1583E1923762; Thu, 7 Oct 2021 22:30:46 +0000 (UTC) Received: from dwysocha.rdu.csb (unknown [10.22.8.139]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 76C205D9C6; Thu, 7 Oct 2021 22:30:45 +0000 (UTC) From: Dave Wysochanski To: Trond Myklebust , Anna Schumaker , David Howells Cc: linux-cachefs@redhat.com, linux-nfs@vger.kernel.org Subject: [PATCH v2 3/7] NFS: Convert NFS fscache enable/disable dfprintks to tracepoints Date: Thu, 7 Oct 2021 18:30:19 -0400 Message-Id: <1633645823-31235-4-git-send-email-dwysocha@redhat.com> In-Reply-To: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> References: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org Convert the enable / disable NFS fscache dfprintks to tracepoints. Utilize the existing NFS inode trace event class, which allows us to keep the same output format to other NFS inode tracepoints. Start the names of the tracepoints with "nfs_fscache" for easy identification. Signed-off-by: Dave Wysochanski --- fs/nfs/fscache.c | 5 +++-- fs/nfs/nfstrace.h | 2 ++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/fs/nfs/fscache.c b/fs/nfs/fscache.c index 6764938eca2d..5f9be4a1b5f8 100644 --- a/fs/nfs/fscache.c +++ b/fs/nfs/fscache.c @@ -19,6 +19,7 @@ #include "internal.h" #include "iostat.h" #include "fscache.h" +#include "nfstrace.h" #define NFSDBG_FACILITY NFSDBG_FSCACHE @@ -314,11 +315,11 @@ void nfs_fscache_open_file(struct inode *inode, struct file *filp) nfs_fscache_update_auxdata(&auxdata, inode); if (inode_is_open_for_write(inode)) { - dfprintk(FSCACHE, "NFS: nfsi 0x%p disabling cache\n", nfsi); + trace_nfs_fscache_disable_inode(inode); clear_bit(NFS_INO_FSCACHE, &nfsi->flags); fscache_disable_cookie(cookie, &auxdata, true); } else { - dfprintk(FSCACHE, "NFS: nfsi 0x%p enabling cache\n", nfsi); + trace_nfs_fscache_enable_inode(inode); fscache_enable_cookie(cookie, &auxdata, i_size_read(inode), nfs_fscache_can_enable, inode); if (fscache_cookie_enabled(cookie)) diff --git a/fs/nfs/nfstrace.h b/fs/nfs/nfstrace.h index 8a224871be74..b79f5fe2e39d 100644 --- a/fs/nfs/nfstrace.h +++ b/fs/nfs/nfstrace.h @@ -209,6 +209,8 @@ DEFINE_NFS_INODE_EVENT(nfs_fsync_enter); DEFINE_NFS_INODE_EVENT_DONE(nfs_fsync_exit); DEFINE_NFS_INODE_EVENT(nfs_access_enter); +DEFINE_NFS_INODE_EVENT(nfs_fscache_enable_inode); +DEFINE_NFS_INODE_EVENT(nfs_fscache_disable_inode); TRACE_EVENT(nfs_access_exit, TP_PROTO( From patchwork Thu Oct 7 22:30:20 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Wysochanski X-Patchwork-Id: 12543697 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 916A0C433EF for ; Thu, 7 Oct 2021 22:30:58 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 7C4A5610C8 for ; Thu, 7 Oct 2021 22:30:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241270AbhJGWcv (ORCPT ); Thu, 7 Oct 2021 18:32:51 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:34919 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240809AbhJGWcu (ORCPT ); Thu, 7 Oct 2021 18:32:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1633645855; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:in-reply-to:in-reply-to:references:references; bh=MEo8GUP9+zCWYYHUjC1q3ticNz8MZfaRuvNyfJRbAus=; b=D+LaIg2RppWGjCZev+VsL+6TOzXADPjMrGa+VLtqdynIiPZD3q3bmV790BE59CZxrdRI0Y VTvj2dD/B4L7rMTg0kLZ9UgKFS2DqVcoQzkjBxeBURTkzXZDC5p2O/67gO7Wnrhg9XBjHb QxAXJCmzOHNgeGyrtLgVq4/I3LyEBVQ= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-327-ZrcSbyJ3M8ydpVnvJTEJEA-1; Thu, 07 Oct 2021 18:30:47 -0400 X-MC-Unique: ZrcSbyJ3M8ydpVnvJTEJEA-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id CC8F5801AA7; Thu, 7 Oct 2021 22:30:46 +0000 (UTC) Received: from dwysocha.rdu.csb (unknown [10.22.8.139]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 3A4195D9C6; Thu, 7 Oct 2021 22:30:46 +0000 (UTC) From: Dave Wysochanski To: Trond Myklebust , Anna Schumaker , David Howells Cc: linux-cachefs@redhat.com, linux-nfs@vger.kernel.org Subject: [PATCH v2 4/7] NFS: Rename fscache read and write pages functions Date: Thu, 7 Oct 2021 18:30:20 -0400 Message-Id: <1633645823-31235-5-git-send-email-dwysocha@redhat.com> In-Reply-To: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> References: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org Rename NFS fscache functions to read from and write to the cache to better reflect the new fscache fallback API naming. Signed-off-by: Dave Wysochanski --- fs/nfs/fscache.c | 4 ++-- fs/nfs/fscache.h | 17 ++++++++--------- fs/nfs/read.c | 4 ++-- 3 files changed, 12 insertions(+), 13 deletions(-) diff --git a/fs/nfs/fscache.c b/fs/nfs/fscache.c index 5f9be4a1b5f8..50d68cb946c8 100644 --- a/fs/nfs/fscache.c +++ b/fs/nfs/fscache.c @@ -331,7 +331,7 @@ void nfs_fscache_open_file(struct inode *inode, struct file *filp) /* * Retrieve a page from fscache */ -int __nfs_readpage_from_fscache(struct inode *inode, struct page *page) +int __nfs_fscache_read_page(struct inode *inode, struct page *page) { int ret; @@ -364,7 +364,7 @@ int __nfs_readpage_from_fscache(struct inode *inode, struct page *page) /* * Store a newly fetched page in fscache */ -void __nfs_readpage_to_fscache(struct inode *inode, struct page *page) +void __nfs_fscache_write_page(struct inode *inode, struct page *page) { int ret; diff --git a/fs/nfs/fscache.h b/fs/nfs/fscache.h index f4deea2908e9..a2c669ce8217 100644 --- a/fs/nfs/fscache.h +++ b/fs/nfs/fscache.h @@ -94,19 +94,18 @@ struct nfs_fscache_inode_auxdata { extern void nfs_fscache_clear_inode(struct inode *); extern void nfs_fscache_open_file(struct inode *, struct file *); -extern int __nfs_readpage_from_fscache(struct inode *, struct page *); +extern int __nfs_fscache_read_page(struct inode *, struct page *); extern void __nfs_read_completion_to_fscache(struct nfs_pgio_header *hdr, unsigned long bytes); -extern void __nfs_readpage_to_fscache(struct inode *, struct page *); +extern void __nfs_fscache_write_page(struct inode *, struct page *); /* * Retrieve a page from an inode data storage object. */ -static inline int nfs_readpage_from_fscache(struct inode *inode, - struct page *page) +static inline int nfs_fscache_read_page(struct inode *inode, struct page *page) { if (nfs_i_fscache(inode)) - return __nfs_readpage_from_fscache(inode, page); + return __nfs_fscache_read_page(inode, page); return -ENOBUFS; } @@ -114,11 +113,11 @@ static inline int nfs_readpage_from_fscache(struct inode *inode, * Store a page newly fetched from the server in an inode data storage object * in the cache. */ -static inline void nfs_readpage_to_fscache(struct inode *inode, +static inline void nfs_fscache_write_page(struct inode *inode, struct page *page) { if (nfs_i_fscache(inode)) - __nfs_readpage_to_fscache(inode, page); + __nfs_fscache_write_page(inode, page); } /* @@ -161,12 +160,12 @@ static inline void nfs_fscache_clear_inode(struct inode *inode) {} static inline void nfs_fscache_open_file(struct inode *inode, struct file *filp) {} -static inline int nfs_readpage_from_fscache(struct inode *inode, +static inline int nfs_fscache_read_page(struct inode *inode, struct page *page) { return -ENOBUFS; } -static inline void nfs_readpage_to_fscache(struct inode *inode, +static inline void nfs_fscache_write_page(struct inode *inode, struct page *page) {} diff --git a/fs/nfs/read.c b/fs/nfs/read.c index 06ed827a67e8..c65663f217a4 100644 --- a/fs/nfs/read.c +++ b/fs/nfs/read.c @@ -123,7 +123,7 @@ static void nfs_readpage_release(struct nfs_page *req, int error) struct address_space *mapping = page_file_mapping(page); if (PageUptodate(page)) - nfs_readpage_to_fscache(inode, page); + nfs_fscache_write_page(inode, page); else if (!PageError(page) && !PagePrivate(page)) generic_error_remove_page(mapping, page); unlock_page(page); @@ -306,7 +306,7 @@ static void nfs_readpage_result(struct rpc_task *task, aligned_len = min_t(unsigned int, ALIGN(len, rsize), PAGE_SIZE); if (!IS_SYNC(page->mapping->host)) { - error = nfs_readpage_from_fscache(page->mapping->host, page); + error = nfs_fscache_read_page(page->mapping->host, page); if (error == 0) goto out_unlock; } From patchwork Thu Oct 7 22:30:21 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Wysochanski X-Patchwork-Id: 12543691 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2C0A1C433F5 for ; Thu, 7 Oct 2021 22:30:52 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 14022610C8 for ; Thu, 7 Oct 2021 22:30:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238478AbhJGWco (ORCPT ); Thu, 7 Oct 2021 18:32:44 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:35558 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237851AbhJGWcn (ORCPT ); Thu, 7 Oct 2021 18:32:43 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1633645849; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:in-reply-to:in-reply-to:references:references; bh=dSbrdFbXZqha7P0aVddzpey9GeHmdmHkhSqVP6OSMgE=; b=Pkl5UovnGlSbhrF/UuLHmEKwuNjDi+wXZsk0jY+NV+xI6P68gJx0rqXBCxHMRiILC69K06 0VbwEtgWtqFuVzPEDDb00YMBghIdPIUfzt2SZzAGNgldgCHDHp8cEc/WMFzNfVXgiis572 NIput9coq4fEhK7JW1hZXNHlCuhQfdE= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-68-sBAe6yQhOJybspL-l-SiSw-1; Thu, 07 Oct 2021 18:30:48 -0400 X-MC-Unique: sBAe6yQhOJybspL-l-SiSw-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 8DF11824FA9; Thu, 7 Oct 2021 22:30:47 +0000 (UTC) Received: from dwysocha.rdu.csb (unknown [10.22.8.139]) by smtp.corp.redhat.com (Postfix) with ESMTPS id F11B75D9C6; Thu, 7 Oct 2021 22:30:46 +0000 (UTC) From: Dave Wysochanski To: Trond Myklebust , Anna Schumaker , David Howells Cc: linux-cachefs@redhat.com, linux-nfs@vger.kernel.org Subject: [PATCH v2 5/7] NFS: Replace dfprintks with tracepoints in read and write page functions Date: Thu, 7 Oct 2021 18:30:21 -0400 Message-Id: <1633645823-31235-6-git-send-email-dwysocha@redhat.com> In-Reply-To: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> References: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org Most of fscache and other NFS IO paths are now using tracepoints. Remove the dfprintks in the NFS fscache read/write page functions and replace with tracepoints at the begin and end of the functions. Signed-off-by: Dave Wysochanski --- fs/nfs/fscache.c | 29 ++++++----------- fs/nfs/nfstrace.h | 96 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 106 insertions(+), 19 deletions(-) diff --git a/fs/nfs/fscache.c b/fs/nfs/fscache.c index 50d68cb946c8..7dbe3a404f34 100644 --- a/fs/nfs/fscache.c +++ b/fs/nfs/fscache.c @@ -335,30 +335,27 @@ int __nfs_fscache_read_page(struct inode *inode, struct page *page) { int ret; - dfprintk(FSCACHE, - "NFS: readpage_from_fscache(fsc:%p/p:%p(i:%lx f:%lx)/0x%p)\n", - nfs_i_fscache(inode), page, page->index, page->flags, inode); - + trace_nfs_fscache_read_page(inode, page); if (PageChecked(page)) { - dfprintk(FSCACHE, "NFS: readpage_from_fscache: PageChecked\n"); ClearPageChecked(page); - return 1; + ret = 1; + goto out; } ret = fscache_fallback_read_page(nfs_i_fscache(inode), page); if (ret < 0) { nfs_inc_fscache_stats(inode, NFSIOS_FSCACHE_PAGES_READ_FAIL); - dfprintk(FSCACHE, - "NFS: readpage_from_fscache failed %d\n", ret); SetPageChecked(page); - return ret; + goto out; } /* Read completed synchronously */ - dfprintk(FSCACHE, "NFS: readpage_from_fscache: read successful\n"); nfs_inc_fscache_stats(inode, NFSIOS_FSCACHE_PAGES_READ_OK); SetPageUptodate(page); - return 0; + ret = 0; +out: + trace_nfs_fscache_read_page_done(inode, page, ret); + return ret; } /* @@ -368,20 +365,14 @@ void __nfs_fscache_write_page(struct inode *inode, struct page *page) { int ret; - dfprintk(FSCACHE, - "NFS: readpage_to_fscache(fsc:%p/p:%p(i:%lx f:%lx))\n", - nfs_i_fscache(inode), page, page->index, page->flags); - + trace_nfs_fscache_write_page(inode, page); ret = fscache_fallback_write_page(nfs_i_fscache(inode), page); - dfprintk(FSCACHE, - "NFS: readpage_to_fscache: p:%p(i:%lu f:%lx) ret %d\n", - page, page->index, page->flags, ret); - if (ret != 0) { nfs_inc_fscache_stats(inode, NFSIOS_FSCACHE_PAGES_WRITTEN_FAIL); nfs_inc_fscache_stats(inode, NFSIOS_FSCACHE_PAGES_UNCACHED); } else { nfs_inc_fscache_stats(inode, NFSIOS_FSCACHE_PAGES_WRITTEN_OK); } + trace_nfs_fscache_write_page_done(inode, page, ret); } diff --git a/fs/nfs/nfstrace.h b/fs/nfs/nfstrace.h index b79f5fe2e39d..f751d841868c 100644 --- a/fs/nfs/nfstrace.h +++ b/fs/nfs/nfstrace.h @@ -1012,6 +1012,102 @@ ) ); +DECLARE_EVENT_CLASS(nfs_fscache_page_event, + TP_PROTO( + const struct inode *inode, + const struct page *page + ), + + TP_ARGS(inode, page), + + TP_STRUCT__entry( + __field(dev_t, dev) + __field(u32, fhandle) + __field(u64, fileid) + __field(loff_t, offset) + __field(u32, count) + ), + + TP_fast_assign( + const struct nfs_inode *nfsi = NFS_I(inode); + const struct nfs_fh *fh = &nfsi->fh; + + __entry->offset = page->index << PAGE_SHIFT; + __entry->count = 4096; + __entry->dev = inode->i_sb->s_dev; + __entry->fileid = nfsi->fileid; + __entry->fhandle = nfs_fhandle_hash(fh); + ), + + TP_printk( + "fileid=%02x:%02x:%llu fhandle=0x%08x " + "offset=%lld count=%u", + MAJOR(__entry->dev), MINOR(__entry->dev), + (unsigned long long)__entry->fileid, + __entry->fhandle, + (long long)__entry->offset, __entry->count + ) +); +DECLARE_EVENT_CLASS(nfs_fscache_page_event_done, + TP_PROTO( + const struct inode *inode, + const struct page *page, + int error + ), + + TP_ARGS(inode, page, error), + + TP_STRUCT__entry( + __field(int, error) + __field(dev_t, dev) + __field(u32, fhandle) + __field(u64, fileid) + __field(loff_t, offset) + __field(u32, count) + ), + + TP_fast_assign( + const struct nfs_inode *nfsi = NFS_I(inode); + const struct nfs_fh *fh = &nfsi->fh; + + __entry->offset = page->index << PAGE_SHIFT; + __entry->count = 4096; + __entry->dev = inode->i_sb->s_dev; + __entry->fileid = nfsi->fileid; + __entry->fhandle = nfs_fhandle_hash(fh); + __entry->error = error; + ), + + TP_printk( + "fileid=%02x:%02x:%llu fhandle=0x%08x " + "offset=%lld count=%u error=%d", + MAJOR(__entry->dev), MINOR(__entry->dev), + (unsigned long long)__entry->fileid, + __entry->fhandle, + (long long)__entry->offset, __entry->count, + __entry->error + ) +); +#define DEFINE_NFS_FSCACHE_PAGE_EVENT(name) \ + DEFINE_EVENT(nfs_fscache_page_event, name, \ + TP_PROTO( \ + const struct inode *inode, \ + const struct page *page \ + ), \ + TP_ARGS(inode, page)) +#define DEFINE_NFS_FSCACHE_PAGE_EVENT_DONE(name) \ + DEFINE_EVENT(nfs_fscache_page_event_done, name, \ + TP_PROTO( \ + const struct inode *inode, \ + const struct page *page, \ + int error \ + ), \ + TP_ARGS(inode, page, error)) +DEFINE_NFS_FSCACHE_PAGE_EVENT(nfs_fscache_read_page); +DEFINE_NFS_FSCACHE_PAGE_EVENT_DONE(nfs_fscache_read_page_done); +DEFINE_NFS_FSCACHE_PAGE_EVENT(nfs_fscache_write_page); +DEFINE_NFS_FSCACHE_PAGE_EVENT_DONE(nfs_fscache_write_page_done); + TRACE_EVENT(nfs_pgio_error, TP_PROTO( const struct nfs_pgio_header *hdr, From patchwork Thu Oct 7 22:30:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Wysochanski X-Patchwork-Id: 12543699 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0C6FBC433FE for ; Thu, 7 Oct 2021 22:32:44 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E6640610A0 for ; Thu, 7 Oct 2021 22:32:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241362AbhJGWef (ORCPT ); Thu, 7 Oct 2021 18:34:35 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:32315 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241497AbhJGWee (ORCPT ); Thu, 7 Oct 2021 18:34:34 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1633645960; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:in-reply-to:in-reply-to:references:references; bh=qB8O/AxLxFhDos55i0zRL7BIqJtlqTpIhhJqS56NxPs=; b=ShTeoWMKB4jeT+JCSnfMrhyHKkW7rL8huSkV1H/x9KmiBDjVNZhvXisCddFQng3LoP12fM VYEufjQp0ghAVKZ9As6pulejmtFbdej/MVauLx761OX4tK+rfM5CKuJJWVwz0fIv+w+UHD srG+bulO9aFeBAJWAFi02dIQzRil/Ho= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-4-zkqeEeuCPGyO-xs3OyB0Hg-1; Thu, 07 Oct 2021 18:30:49 -0400 X-MC-Unique: zkqeEeuCPGyO-xs3OyB0Hg-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 5055110A8E02; Thu, 7 Oct 2021 22:30:48 +0000 (UTC) Received: from dwysocha.rdu.csb (unknown [10.22.8.139]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B26BE5D9C6; Thu, 7 Oct 2021 22:30:47 +0000 (UTC) From: Dave Wysochanski To: Trond Myklebust , Anna Schumaker , David Howells Cc: linux-cachefs@redhat.com, linux-nfs@vger.kernel.org Subject: [PATCH v2 6/7] NFS: Remove remaining dfprintks related to fscache cookies Date: Thu, 7 Oct 2021 18:30:22 -0400 Message-Id: <1633645823-31235-7-git-send-email-dwysocha@redhat.com> In-Reply-To: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> References: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org The fscache cookie APIs including fscache_acquire_cookie() and fscache_relinquish_cookie() now have very good tracing. Thus, there is no real need for dfprintks in the NFS fscache interface. Signed-off-by: Dave Wysochanski --- fs/nfs/fscache.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/fs/nfs/fscache.c b/fs/nfs/fscache.c index 7dbe3a404f34..06c4d8ee7281 100644 --- a/fs/nfs/fscache.c +++ b/fs/nfs/fscache.c @@ -21,7 +21,7 @@ #include "fscache.h" #include "nfstrace.h" -#define NFSDBG_FACILITY NFSDBG_FSCACHE +#define NFSDBG_FACILITY NFSDBG_FSCACHE static struct rb_root nfs_fscache_keys = RB_ROOT; static DEFINE_SPINLOCK(nfs_fscache_keys_lock); @@ -86,8 +86,6 @@ void nfs_fscache_get_client_cookie(struct nfs_client *clp) &key, len, NULL, 0, clp, 0, true); - dfprintk(FSCACHE, "NFS: get client cookie (0x%p/0x%p)\n", - clp, clp->fscache); } /* @@ -95,9 +93,6 @@ void nfs_fscache_get_client_cookie(struct nfs_client *clp) */ void nfs_fscache_release_client_cookie(struct nfs_client *clp) { - dfprintk(FSCACHE, "NFS: releasing client cookie (0x%p/0x%p)\n", - clp, clp->fscache); - fscache_relinquish_cookie(clp->fscache, NULL, false); clp->fscache = NULL; } @@ -191,8 +186,6 @@ void nfs_fscache_get_super_cookie(struct super_block *sb, const char *uniq, int sizeof(key->key) + ulen, NULL, 0, nfss, 0, true); - dfprintk(FSCACHE, "NFS: get superblock cookie (0x%p/0x%p)\n", - nfss, nfss->fscache); return; non_unique: @@ -211,9 +204,6 @@ void nfs_fscache_release_super_cookie(struct super_block *sb) { struct nfs_server *nfss = NFS_SB(sb); - dfprintk(FSCACHE, "NFS: releasing superblock cookie (0x%p/0x%p)\n", - nfss, nfss->fscache); - fscache_relinquish_cookie(nfss->fscache, NULL, false); nfss->fscache = NULL; @@ -270,8 +260,6 @@ void nfs_fscache_clear_inode(struct inode *inode) struct nfs_inode *nfsi = NFS_I(inode); struct fscache_cookie *cookie = nfs_i_fscache(inode); - dfprintk(FSCACHE, "NFS: clear cookie (0x%p/0x%p)\n", nfsi, cookie); - nfs_fscache_update_auxdata(&auxdata, inode); fscache_relinquish_cookie(cookie, &auxdata, false); nfsi->fscache = NULL; From patchwork Thu Oct 7 22:30:23 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Wysochanski X-Patchwork-Id: 12543693 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D60F1C433FE for ; Thu, 7 Oct 2021 22:30:52 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C3C266105A for ; Thu, 7 Oct 2021 22:30:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237851AbhJGWcq (ORCPT ); Thu, 7 Oct 2021 18:32:46 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:26097 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233370AbhJGWcp (ORCPT ); Thu, 7 Oct 2021 18:32:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1633645851; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:in-reply-to:in-reply-to:references:references; bh=Yh48u7kZGpMcWIBMnksUa2p1rEHfVEL82DyEpqEquZE=; b=BneSNKTNXIFEyO1RNmeLj0E9b0I3VukYcOGDnZxtkhGvdEHoeEyvdkrSXrCTOsVaUtcxtx dmtAC+evZe9gBcO1JA3pykcIVP+FhGVMQbgY0N0VuHfK8DxdvXd4EOKyWRqvU9K7WYJROR iVNQGzxntE6xNVQJW9F7F2wxS2I15eg= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-188-8ykm1hUfM8eAFX7edqWD9w-1; Thu, 07 Oct 2021 18:30:50 -0400 X-MC-Unique: 8ykm1hUfM8eAFX7edqWD9w-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 12D3C1005E68; Thu, 7 Oct 2021 22:30:49 +0000 (UTC) Received: from dwysocha.rdu.csb (unknown [10.22.8.139]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 741215D9C6; Thu, 7 Oct 2021 22:30:48 +0000 (UTC) From: Dave Wysochanski To: Trond Myklebust , Anna Schumaker , David Howells Cc: linux-cachefs@redhat.com, linux-nfs@vger.kernel.org Subject: [PATCH v2 7/7] NFS: Remove remaining usages of NFSDBG_FSCACHE Date: Thu, 7 Oct 2021 18:30:23 -0400 Message-Id: <1633645823-31235-8-git-send-email-dwysocha@redhat.com> In-Reply-To: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> References: <1633645823-31235-1-git-send-email-dwysocha@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org The NFS fscache interface has removed all dfprintks so remove the NFSDBG_FSCACHE defines. Signed-off-by: Dave Wysochanski --- fs/nfs/fscache-index.c | 2 -- fs/nfs/fscache.c | 2 -- include/uapi/linux/nfs_fs.h | 2 +- 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/fs/nfs/fscache-index.c b/fs/nfs/fscache-index.c index 4bd5ce736193..71bb4270641f 100644 --- a/fs/nfs/fscache-index.c +++ b/fs/nfs/fscache-index.c @@ -17,8 +17,6 @@ #include "internal.h" #include "fscache.h" -#define NFSDBG_FACILITY NFSDBG_FSCACHE - /* * Define the NFS filesystem for FS-Cache. Upon registration FS-Cache sticks * the cookie for the top-level index object for NFS into here. The top-level diff --git a/fs/nfs/fscache.c b/fs/nfs/fscache.c index 06c4d8ee7281..57cc242ae916 100644 --- a/fs/nfs/fscache.c +++ b/fs/nfs/fscache.c @@ -21,8 +21,6 @@ #include "fscache.h" #include "nfstrace.h" -#define NFSDBG_FACILITY NFSDBG_FSCACHE - static struct rb_root nfs_fscache_keys = RB_ROOT; static DEFINE_SPINLOCK(nfs_fscache_keys_lock); diff --git a/include/uapi/linux/nfs_fs.h b/include/uapi/linux/nfs_fs.h index 3afe3767c55d..ae0de165c014 100644 --- a/include/uapi/linux/nfs_fs.h +++ b/include/uapi/linux/nfs_fs.h @@ -52,7 +52,7 @@ #define NFSDBG_CALLBACK 0x0100 #define NFSDBG_CLIENT 0x0200 #define NFSDBG_MOUNT 0x0400 -#define NFSDBG_FSCACHE 0x0800 +#define NFSDBG_FSCACHE 0x0800 /* unused */ #define NFSDBG_PNFS 0x1000 #define NFSDBG_PNFS_LD 0x2000 #define NFSDBG_STATE 0x4000