Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2011305pxb; Fri, 5 Mar 2021 05:26:36 -0800 (PST) X-Google-Smtp-Source: ABdhPJyIwi7nZvGCIpvUfm2QKy7m09Wa0YY0lp7ZmDQ04GvRClwpBuZh+XL7tAZTxjQKDNyLIQBi X-Received: by 2002:a17:906:5689:: with SMTP id am9mr2111292ejc.298.1614950795647; Fri, 05 Mar 2021 05:26:35 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614950795; cv=none; d=google.com; s=arc-20160816; b=VFyhffzp2wZcmQfws2c7YIGgpemhr9BGCjKVDtwvvj/lNY1iTWxGIvXBRaXhkwmuPe /z4TmyiLEkLH0Cg/FQokrEulivVkkigVKgyEJBRDAzHta/j1UqLKhWUbdXRSlK9IHEXQ qz+aBbCD/PXYzTgbtP97VbQ0D1A5Bw8VRL9D6g5cYameEumiWoLdPEF0GaKeElOKB40v q+8Zr4QqRB8TDp8WKwL68eMzC0avmE3Igtv/DIhPNFivks4tXnn7a97zJsjangnLSG98 lCUc6eQX9uw0bZ+kkQNJZ9/pGZ27d1Il50965a8cb5GKfeL/RVfb0beq+ZWqIFAO9I06 pKEg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=LU7Uu/G6L4J+ZP2q9hkO7t01RT9Z+lkkDmGXsim3zm4=; b=ClYyYGkS2MGSidveK0DCJ78ta2sTFlmNPB7rrl3fotADtG8I+x3fpX1bnDez2HmhV2 IQ4J09jlkaHJe+71jQaj2WFLPRTh3Zp2FQHw1zXQUPFgTtGkwwP839dL7EVBJFFSavW+ PJMZmD3qgn1Y/aR6gL5Tm6YTuGexvYuJ1RoBnAD4oXpc7B/TmJ3mQJB+tXmv1t72ABzW noQ8NHtTZY80ewptPMzl/Od29GReDOKI7loKGKzy87fVQ0KggUZBuMCEg26uowiuogW2 Zymw1/zPfxXyglVcNIU2C7XwkCtbH+7fXk21GJsRgqx2rUQMNg8xx8l6VjDI3SdWxnmf Ypcw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=casper.20170209 header.b=hJku25DC; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j7si1289926ejx.732.2021.03.05.05.26.05; Fri, 05 Mar 2021 05:26:35 -0800 (PST) Received-SPF: pass (google.com: domain of linux-ext4-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=@infradead.org header.s=casper.20170209 header.b=hJku25DC; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229711AbhCENZc (ORCPT + 99 others); Fri, 5 Mar 2021 08:25:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48732 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229929AbhCENZF (ORCPT ); Fri, 5 Mar 2021 08:25:05 -0500 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E123EC061574; Fri, 5 Mar 2021 05:25:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=LU7Uu/G6L4J+ZP2q9hkO7t01RT9Z+lkkDmGXsim3zm4=; b=hJku25DCrH+D7uuuce2/DcyXyC Eq1edJUK/ISmJ0lPxZUUFcNuy2uh/2a26AZ0V6+uNPNj2s0jrQ73tfDs2pL2YUlJbcKhBJy8bBb9H ljpNQnFih8suino8V+gwYXSgor9rU3lHEKu+AAcO/9cYqF4S/K+WelSXox3eEoO08pwCPiEhkflAS o5IpQirkHyGs2gkIBt73gEEUwyJIToYWDDKA6eBvVC1n+KqVEawesyx+R4Z8nhUppERa6J9Npvx3v h12yu7wViZakuEszwGHBXWKK2QF08MtkaGdAUBDto2xLh+Hq+iAZAIuWcm8YBsTFIL6gd8xM1uzzi C03Nt5+A==; Received: from hch by casper.infradead.org with local (Exim 4.94 #2 (Red Hat Linux)) id 1lIARe-00BkvL-AN; Fri, 05 Mar 2021 13:24:46 +0000 Date: Fri, 5 Mar 2021 13:24:42 +0000 From: Christoph Hellwig To: Jan Kara Cc: "zhangyi (F)" , linux-fsdevel@vger.kernel.org, linux-ext4@vger.kernel.org, tytso@mit.edu, viro@zeniv.linux.org.uk Subject: Re: [PATCH] block_dump: don't put the last refcount when marking inode dirty Message-ID: <20210305132442.GA2801131@infradead.org> References: <20210226103103.3048803-1-yi.zhang@huawei.com> <20210301112102.GD25026@quack2.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210301112102.GD25026@quack2.suse.cz> X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Mon, Mar 01, 2021 at 12:21:02PM +0100, Jan Kara wrote: > Hrm, ok. Honestly, I wanted to just delete that code for a long time. IMO > tracepoints (and we have one in __mark_inode_dirty) are much more useful > for tracing anyway. This code exists only because it was there much before > tracepoints existed... Do you have a strong reason why are you using > block_dump instead of tracepoint trace_writeback_mark_inode_dirty() for > your monitoring? Let me play devils advocate here, the downside of the writeback tracepoints is that they only trace the inode number and not a file name (component). Which is also the reason they avoid this problem. That being said block_dump is a horrible hack, and trace points are the proper replacement.