From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Subject: Re: [PATCH] Fix journal detection on HFS+. Date: Wed, 5 Nov 2008 09:09:37 -0500 Message-ID: <20081105140937.GA27438@infradead.org> References: <1225872026-13484-1-git-send-email-wt@penguintechs.org> <1225872026-13484-2-git-send-email-wt@penguintechs.org> <1225872026-13484-3-git-send-email-wt@penguintechs.org> <20081105104054.GA6561@logfs.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Warren Turkal , linux-fsdevel , Roman Zippel To: J??rn Engel Return-path: Received: from bombadil.infradead.org ([18.85.46.34]:36559 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752044AbYKEOJk (ORCPT ); Wed, 5 Nov 2008 09:09:40 -0500 Content-Disposition: inline In-Reply-To: <20081105104054.GA6561@logfs.org> Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Wed, Nov 05, 2008 at 11:40:54AM +0100, J??rn Engel wrote: > On Wed, 5 November 2008 00:00:26 -0800, Warren Turkal wrote: > > > > + vhdr->journal_info_block != cpu_to_be32(0)) { > > 0 doesn't need explicit cpu_to_be32(). You can drop the whole > != cpu_to_be32(0) > > > + (be32_to_cpu(vhdr->journal_info_block) != 0) && > > Same here. Yeah. In addition adding a little helper that checks both the journal flag and the non-zeroness of journal_info_block would be useful so that everyone adding more checks like this in the future get it right.