Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1763759AbZDBPls (ORCPT ); Thu, 2 Apr 2009 11:41:48 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753865AbZDBPlf (ORCPT ); Thu, 2 Apr 2009 11:41:35 -0400 Received: from THUNK.ORG ([69.25.196.29]:57983 "EHLO thunker.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752533AbZDBPle (ORCPT ); Thu, 2 Apr 2009 11:41:34 -0400 Date: Thu, 2 Apr 2009 11:41:23 -0400 From: Theodore Tso To: Thiemo Nagel Cc: Alexander Beregalov , Jens Axboe , linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: 2.6.29-git: cannot mount ext4/loop Message-ID: <20090402154123.GG10642@mit.edu> Mail-Followup-To: Theodore Tso , Thiemo Nagel , Alexander Beregalov , Jens Axboe , linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org References: <20090401225351.GA22621@orion> <20090402055356.GC10642@mit.edu> <49D4BDF2.2070102@ph.tum.de> <20090402145436.GF10642@mit.edu> <49D4D74F.1020904@ph.tum.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <49D4D74F.1020904@ph.tum.de> User-Agent: Mutt/1.5.18 (2008-05-17) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: tytso@mit.edu X-SA-Exim-Scanned: No (on thunker.thunk.org); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1529 Lines: 37 On Thu, Apr 02, 2009 at 05:18:39PM +0200, Thiemo Nagel wrote: > Theodore Tso wrote: >> On Thu, Apr 02, 2009 at 03:30:26PM +0200, Thiemo Nagel wrote: >>> When I added the block range checks, initially I was assuming that >>> when EXTENTS_FL is not set, the inode->i_data *always* contains >>> references to further blocks. Ted showed me wrong and added the condition >>> >>> ISREG() || ISDIR() || ( ISLNK() && !is_fast_symlink() ) >>> >>> before that assumption can be made. But maybe we need some further >>> restraints? >> >> It's a endian-problem; we're missing le32_to_cpu() in that patch. >> Sparc is big-endian. > > Sorry for that. Could you also fix the types? bref should have a type of __le32, not unsigned int, and when you pass in the reference to __ext4_check_blockref(), there was an inappropriate cast to unsigned int which hid kernel's natural type checking to catch these sorts of problems. I haven't had time yet to check your other patches; could you also take a quick scan to make sure we have all of the byte-swapping calls needed for proper big-endian checking, that we're using the correct __le32 types and not doing any casts? I should have caught this when I did my review of your patches, so this is also partially my fault. Many thanks, - Ted -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/