From mboxrd@z Thu Jan 1 00:00:00 1970 From: Joe Perches Subject: Re: [PATCH 1/2] hfs/hfsplus: Convert dprint to hfs_dbg Date: Sun, 14 Apr 2013 19:06:19 -0700 Message-ID: <1365991579.1878.26.camel@joe-AO722> References: <1365990973.28177.YahooMailClassic@web172303.mail.ir2.yahoo.com> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit Cc: Vyacheslav Dubeyko , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org To: htl10@users.sourceforge.net Return-path: In-Reply-To: <1365990973.28177.YahooMailClassic@web172303.mail.ir2.yahoo.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org On Mon, 2013-04-15 at 02:56 +0100, Hin-Tak Leung wrote: > --- On Mon, 15/4/13, Joe Perches wrote: > > On Mon, 2013-04-15 at 01:53 +0100, > > Hin-Tak Leung wrote: > > > --- On Mon, 8/4/13, Joe Perches wrote: > > > > Use a more current logging style. > > [] > > > I have been sitting on a patch which changes this part > > of the code to dynamic debugging, and it is much simplier. [] > > This change wouldn't work well as it would make a mess > > of output that uses no prefix (ie: emits at KERN_DEFAULT) > > with output that uses KERN_DEBUG > > > > That's the reason for _dbg and _dbg_cont. > > Hmm, I don't get it. Is there any *existing* use of dprint > in the hfplus code which is affected by your comment? Code like this prints out currently on a single line at KERN_DEFAULT. @@ -138,16 +138,16 @@ void hfs_bnode_dump(struct hfs_bnode *node) [] for (i = be16_to_cpu(desc.num_recs); i >= 0; off -= 2, i--) { key_off = hfs_bnode_read_u16(node, off); - dprint(DBG_BNODE_MOD, " %d", key_off); + hfs_dbg_cont(BNODE_MOD, " %d", key_off); By converting this dprint() to pr_debug(), it would print out on a multiple lines, one for each read. That's why it should use a mechanism like dbg_cont. btw: there is no current pr_debug_cont mechanism.