Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1162244AbWKPCok (ORCPT ); Wed, 15 Nov 2006 21:44:40 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1162241AbWKPCoj (ORCPT ); Wed, 15 Nov 2006 21:44:39 -0500 Received: from 216-99-217-87.dsl.aracnet.com ([216.99.217.87]:30863 "EHLO sous-sol.org") by vger.kernel.org with ESMTP id S1162244AbWKPCoY (ORCPT ); Wed, 15 Nov 2006 21:44:24 -0500 Message-Id: <20061116024524.487362000@sous-sol.org> References: <20061116024332.124753000@sous-sol.org> User-Agent: quilt/0.45-1 Date: Wed, 15 Nov 2006 18:43:40 -0800 From: Chris Wright To: linux-kernel@vger.kernel.org, stable@kernel.org Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Dave Jones , Chuck Wolber , Chris Wedgwood , Michael Krufky , torvalds@osdl.org, akpm@osdl.org, alan@lxorguk.ukuu.org.uk, Eric Sandeen , Evgeniy Dushistov Subject: [patch 08/30] fix UFS superblock alignment issues Content-Disposition: inline; filename=fix-ufs-superblock-alignment-issues.patch Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1547 Lines: 41 -stable review patch. If anyone has any objections, please let us know. ------------------ From: Eric Sandeen ufs2 fails to mount on x86_64, claiming bad magic. This is because ufs_super_block_third's fs_un1 member is padded out by 4 bytes for 8-byte alignment, pushing down the rest of the struct. Forcing this to be packed solves it. I took a quick look over other on-disk structures and didn't immediately find other problems. I was able to mount & ls a populated ufs2 filesystem w/ this change. Signed-off-by: Eric Sandeen Cc: Evgeniy Dushistov Cc: Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Chris Wright --- include/linux/ufs_fs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- linux-2.6.18.2.orig/include/linux/ufs_fs.h +++ linux-2.6.18.2/include/linux/ufs_fs.h @@ -900,7 +900,7 @@ struct ufs_super_block_third { __fs64 fs_csaddr; /* blk addr of cyl grp summary area */ __fs64 fs_pendingblocks;/* blocks in process of being freed */ __fs32 fs_pendinginodes;/*inodes in process of being freed */ - } fs_u2; + } __attribute__ ((packed)) fs_u2; } fs_un1; union { struct { -- - 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/