[Pkg-lustre-svn-commit] r511 - /trunk/debian/patches/bug16680_detect_on_disc_corruption.dpatch

winnie at users.alioth.debian.org winnie at users.alioth.debian.org
Fri Sep 19 20:16:24 UTC 2008


Author: winnie
Date: Fri Sep 19 20:16:24 2008
New Revision: 511

URL: http://svn.debian.org/wsvn/pkg-lustre/?sc=1&rev=511
Log:
Update patch for 1.6.5.1

Modified:
    trunk/debian/patches/bug16680_detect_on_disc_corruption.dpatch

Modified: trunk/debian/patches/bug16680_detect_on_disc_corruption.dpatch
URL: http://svn.debian.org/wsvn/pkg-lustre/trunk/debian/patches/bug16680_detect_on_disc_corruption.dpatch?rev=511&op=diff
==============================================================================
--- trunk/debian/patches/bug16680_detect_on_disc_corruption.dpatch (original)
+++ trunk/debian/patches/bug16680_detect_on_disc_corruption.dpatch Fri Sep 19 20:16:24 2008
@@ -1,176 +1,27 @@
 #! /bin/sh /usr/share/dpatch/dpatch-run
-## lustre_manpatch.dpatch by Patrick Winnert <winnie at debian.org>
+## bug16680_detect_on_disc_corruption.dpatch by Patrick Winnertz <winnie at debian.org>
 ##
 ## All lines beginning with `## DP:' are a description of the patch.
-## DP: registred symbol not allowed.
+## DP: Patch from bug 16680
 
 @DPATCH@
 Index: ldiskfs/kernel_patches/patches/ext3-mballoc3-core.patch
 ===================================================================
 RCS file: /cvsroot/cfs/ldiskfs/kernel_patches/patches/ext3-mballoc3-core.patch,v
-retrieving revision 1.19
-diff -p -u -r1.19 ext3-mballoc3-core.patch
---- ldiskfs/kernel_patches/patches/ext3-mballoc3-core.patch	26 Jul 2008 11:08:13 -0000	1.19
-+++ ldiskfs/kernel_patches/patches/ext3-mballoc3-core.patch	19 Sep 2008 06:54:56 -0000
-@@ -1,8 +1,8 @@
--Index: linux-2.6.5-7.311/include/linux/ext3_fs.h
-+Index: linux-2.6.18-53.1.19/include/linux/ext3_fs.h
+retrieving revision 1.12
+diff -p -u -r1.12 ext3-mballoc3-core.patch
+--- ldiskfs/kernel_patches/patches/ext3-mballoc3-core.patch	6 Mar 2008 04:13:24 -0000	1.12
++++ ldiskfs/kernel_patches/patches/ext3-mballoc3-core.patch	19 Sep 2008 12:20:00 -0000
+@@ -183,7 +183,7 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  ===================================================================
----- linux-2.6.5-7.311.orig/include/linux/ext3_fs.h
--+++ linux-2.6.5-7.311/include/linux/ext3_fs.h
--@@ -57,6 +57,30 @@ struct statfs;
-+--- linux-2.6.18-53.1.19.orig/include/linux/ext3_fs.h	2008-09-18 15:44:26.000000000 +0400
-++++ linux-2.6.18-53.1.19/include/linux/ext3_fs.h	2008-09-18 15:44:26.000000000 +0400
-+@@ -53,6 +53,30 @@
-  #define ext3_debug(f, a...)	do {} while (0)
-  #endif
-  
-@@ -33,7 +33,7 @@ Index: linux-2.6.5-7.311/include/linux/e
-  /*
-   * Special inodes numbers
-   */
--@@ -361,6 +385,14 @@ struct ext3_inode {
-+@@ -398,6 +422,14 @@ struct ext3_inode {
-  #define ext3_find_first_zero_bit	ext2_find_first_zero_bit
-  #define ext3_find_next_zero_bit		ext2_find_next_zero_bit
-  
-@@ -48,7 +48,7 @@ Index: linux-2.6.5-7.311/include/linux/e
-  /*
-   * Maximal mount counts between two filesystem checks
-   */
--@@ -735,6 +767,20 @@ extern unsigned long ext3_count_dirs (st
-+@@ -799,6 +831,20 @@ extern unsigned long ext3_count_dirs (st
-  extern void ext3_check_inodes_bitmap (struct super_block *);
-  extern unsigned long ext3_count_free (struct buffer_head *, unsigned);
-  
-@@ -68,9 +68,9 @@ Index: linux-2.6.5-7.311/include/linux/e
- +
-  
-  /* inode.c */
-- extern int ext3_block_truncate_page(handle_t *, struct page *,
--@@ -769,6 +815,10 @@ extern int ext3_htree_fill_tree(struct f
-- 				__u32 start_minor_hash, __u32 *next_hash);
-+ int ext3_forget(handle_t *handle, int is_metadata, struct inode *inode,
-+@@ -843,6 +889,10 @@ extern int ext3_group_extend(struct supe
-+ 				ext3_fsblk_t n_blocks_count);
-  
-  /* super.c */
- +extern struct proc_dir_entry *proc_root_ext3;
-@@ -80,13 +80,13 @@ Index: linux-2.6.5-7.311/include/linux/e
-  extern void ext3_error (struct super_block *, const char *, const char *, ...)
-  	__attribute__ ((format (printf, 3, 4)));
-  extern void __ext3_std_error (struct super_block *, const char *, int);
--Index: linux-2.6.5-7.311/include/linux/ext3_fs_sb.h
-+Index: linux-2.6.18-53.1.19/include/linux/ext3_fs_sb.h
- ===================================================================
----- linux-2.6.5-7.311.orig/include/linux/ext3_fs_sb.h
--+++ linux-2.6.5-7.311/include/linux/ext3_fs_sb.h
--@@ -78,6 +78,61 @@ struct ext3_sb_info {
-- 	struct timer_list turn_ro_timer;	/* For turning read-only (crash simulation) */
-- 	wait_queue_head_t ro_wait_queue;	/* For people waiting for the fs to go read-only */
-+--- linux-2.6.18-53.1.19.orig/include/linux/ext3_fs_sb.h	2008-09-18 15:44:26.000000000 +0400
-++++ linux-2.6.18-53.1.19/include/linux/ext3_fs_sb.h	2008-09-18 15:44:26.000000000 +0400
-+@@ -88,6 +88,61 @@ struct ext3_sb_info {
-+ 	unsigned long s_ext_blocks;
-+ 	unsigned long s_ext_extents;
-  #endif
- +
- +	/* for buddy allocator */
-@@ -146,11 +146,11 @@ Index: linux-2.6.5-7.311/include/linux/e
- +				 [(group) & (EXT3_DESC_PER_BLOCK(sb) - 1)]
- +
-  #endif	/* _LINUX_EXT3_FS_SB */
--Index: linux-2.6.5-7.311/fs/ext3/super.c
-+Index: linux-2.6.18-53.1.19/fs/ext3/super.c
- ===================================================================
----- linux-2.6.5-7.311.orig/fs/ext3/super.c
--+++ linux-2.6.5-7.311/fs/ext3/super.c
--@@ -389,6 +389,7 @@ void ext3_put_super (struct super_block 
-+--- linux-2.6.18-53.1.19.orig/fs/ext3/super.c	2008-09-18 15:44:26.000000000 +0400
-++++ linux-2.6.18-53.1.19/fs/ext3/super.c	2008-09-18 15:44:26.000000000 +0400
-+@@ -391,6 +391,7 @@ static void ext3_put_super (struct super
-  	struct ext3_super_block *es = sbi->s_es;
-  	int i;
-  
-@@ -158,7 +158,7 @@ Index: linux-2.6.5-7.311/fs/ext3/super.c
-  	ext3_ext_release(sb);
-  	ext3_xattr_put_super(sb);
-  	journal_destroy(sbi->s_journal);
--@@ -428,6 +429,8 @@ void ext3_put_super (struct super_block 
-+@@ -433,6 +434,8 @@ static void ext3_put_super (struct super
-  		invalidate_bdev(sbi->journal_bdev, 0);
-  		ext3_blkdev_remove(sbi);
-  	}
-@@ -167,16 +167,16 @@ Index: linux-2.6.5-7.311/fs/ext3/super.c
-  	sb->s_fs_info = NULL;
-  	kfree(sbi);
-  	return;
--@@ -453,6 +456,8 @@ static struct inode *ext3_alloc_inode(st
-+@@ -458,6 +461,8 @@ static struct inode *ext3_alloc_inode(st
-  	ei->vfs_inode.i_version = 1;
-- 	
-+ 
-  	memset(&ei->i_cached_extent, 0, sizeof(ei->i_cached_extent));
- +	INIT_LIST_HEAD(&ei->i_prealloc_list);
- +	spin_lock_init(&ei->i_prealloc_lock);
-  	return &ei->vfs_inode;
-  }
-  
--@@ -1151,6 +1156,13 @@ static int ext3_fill_super (struct super
-+@@ -1454,6 +1459,13 @@ static int ext3_fill_super (struct super
-  	sbi->s_mount_opt = 0;
-  	sbi->s_resuid = EXT3_DEF_RESUID;
-  	sbi->s_resgid = EXT3_DEF_RESGID;
-@@ -188,9 +188,9 @@ Index: linux-2.6.5-7.311/fs/ext3/super.c
- +		return -ENOMEM;
- +	}
-  
-- 	blocksize = sb_min_blocksize(sb, EXT3_MIN_BLOCK_SIZE);
-- 	if (!blocksize) {
--@@ -1526,6 +1538,8 @@ failed_mount:
-+ 	unlock_kernel();
-+ 
-+@@ -1857,6 +1869,8 @@ failed_mount:
-  	ext3_blkdev_remove(sbi);
-  	brelse(bh);
-  out_fail:
-@@ -198,8 +198,8 @@ Index: linux-2.6.5-7.311/fs/ext3/super.c
- +	sbi->s_dev_proc = NULL;
-  	sb->s_fs_info = NULL;
-  	kfree(sbi);
-- 	return -EINVAL;
--@@ -2158,9 +2172,46 @@ static struct file_system_type ext3_fs_t
-+ 	lock_kernel();
-+@@ -2782,9 +2796,46 @@ static struct file_system_type ext3_fs_t
-  	.fs_flags	= FS_REQUIRES_DEV,
-  };
-  
-@@ -247,7 +247,7 @@ Index: linux-2.6.5-7.311/fs/ext3/super.c
-  	if (err)
-  		return err;
-  	err = init_inodecache();
--@@ -2189,6 +2240,7 @@ static void __exit exit_ext3_fs(void)
-+@@ -2806,6 +2857,7 @@ static void __exit exit_ext3_fs(void)
-  	unregister_filesystem(&ext3_fs_type);
-  	destroy_inodecache();
-  	exit_ext3_xattr();
-@@ -255,11 +255,11 @@ Index: linux-2.6.5-7.311/fs/ext3/super.c
-  }
-  
-  int ext3_map_inode_page(struct inode *inode, struct page *page,
--Index: linux-2.6.5-7.311/fs/ext3/mballoc.c
-+Index: linux-2.6.18-53.1.19/fs/ext3/mballoc.c
- ===================================================================
----- /dev/null
--+++ linux-2.6.5-7.311/fs/ext3/mballoc.c
--@@ -0,0 +1,4385 @@
-+--- linux-2.6.18-53.1.19.orig/fs/ext3/mballoc.c	2008-09-03 21:31:05.040005509 +0400
-++++ linux-2.6.18-53.1.19/fs/ext3/mballoc.c	2008-09-19 10:44:57.000000000 +0400
-+@@ -0,0 +1,4469 @@
+ --- linux-2.6.9-full.orig/fs/ext3/mballoc.c	2007-10-17 21:59:51.072534980 +0400
+ +++ linux-2.6.9-full/fs/ext3/mballoc.c	2007-10-17 23:09:22.000000000 +0400
+-@@ -0,0 +1,4398 @@
++@@ -0,0 +1,4483 @@
  +/*
- + * Copyright 2008 Sun Microsystems, Inc.
+ + * Copyright (c) 2003-2006, Cluster File Systems, Inc, info at clusterfs.com
  + * Written by Alex Tomas <alex at clusterfs.com>
-@@ -589,6 +589,7 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -513,6 +513,7 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +	unsigned short	bb_free;
  +	unsigned short	bb_fragments;
  +	struct		list_head bb_prealloc_list;
@@ -178,7 +29,7 @@
  +#ifdef DOUBLE_CHECK
  +	void		*bb_bitmap;
  +#endif
-@@ -692,7 +693,7 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -616,7 +617,7 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +	__u16 tail;	/* what tail broke some buddy */
  +	__u16 buddy;	/* buddy the tail ^^^ broke */
  +	__u16 flags;
@@ -187,7 +38,7 @@
  +	__u8 op:4;
  +	__u8 merged:1;
  +};
-@@ -725,7 +726,7 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -651,7 +652,7 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +void ext3_mb_release_blocks(struct super_block *, int);
  +void ext3_mb_poll_new_transaction(struct super_block *, handle_t *);
  +void ext3_mb_free_committed_blocks(struct super_block *);
@@ -196,7 +47,7 @@
  +void ext3_mb_free_consumed_preallocations(struct ext3_allocation_context *ac);
  +void ext3_mb_return_to_preallocation(struct inode *inode, struct ext3_buddy *e3b,
  +					sector_t block, int count);
-@@ -1150,8 +1151,12 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -1074,8 +1075,12 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +	grp->bb_fragments = fragments;
  +
  +	if (free != grp->bb_free) {
@@ -211,7 +62,7 @@
  +		grp->bb_free = free;
  +	}
  +
-@@ -1239,8 +1244,9 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -1163,8 +1168,9 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +		if (!buffer_uptodate(bh[i]))
  +			goto out;
  +
@@ -222,7 +73,7 @@
  +		int group;
  +
  +		group = (first_block + i) >> 1;
-@@ -1272,13 +1278,14 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -1196,13 +1202,14 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +			memcpy(data, bitmap, blocksize);
  +
  +			/* mark all preallocated blocks used in in-core bitmap */
@@ -239,7 +90,7 @@
  +
  +out:
  +	if (bh) {
-@@ -2233,6 +2240,8 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -2157,6 +2164,8 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +			hs->result.fe_start, hs->result.fe_len);
  +		seq_printf(seq, "%-5u %-8u %-23s free\n",
  +				hs->pid, hs->ino, buf2);
@@ -248,7 +99,7 @@
  +	}
  +	return 0;
  +}
-@@ -2358,8 +2367,9 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -2282,8 +2291,9 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +static int ext3_mb_seq_groups_show(struct seq_file *seq, void *v)
  +{
  +	struct super_block *sb = seq->private;
@@ -259,7 +110,7 @@
  +	struct ext3_buddy e3b;
  +	struct sg {
  +		struct ext3_group_info info;
-@@ -2368,10 +2378,10 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -2292,10 +2302,10 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +
  +	group--;
  +	if (group == 0)
@@ -272,7 +123,7 @@
  +			   "2^0", "2^1", "2^2", "2^3", "2^4", "2^5","2^6",
  +			   "2^7", "2^8", "2^9", "2^10", "2^11", "2^12", "2^13");
  +
-@@ -2382,13 +2392,20 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -2306,13 +2316,20 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +		seq_printf(seq, "#%-5lu: I/O error\n", group);
  +		return 0;
  +	}
@@ -295,7 +146,7 @@
  +	for (i = 0; i <= 13; i++)
  +		seq_printf(seq, " %-5u", i <= sb->s_blocksize_bits + 1 ?
  +				sg.info.bb_counters[i] : 0);
-@@ -2489,6 +2506,7 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -2413,6 +2430,7 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +	h.result = ac->ac_b_ex;
  +	h.flags = ac->ac_flags;
  +	h.merged = 0;
@@ -303,7 +154,7 @@
  +	if (ac->ac_op == EXT3_MB_HISTORY_ALLOC) {
  +		if (ac->ac_g_ex.fe_start == ac->ac_b_ex.fe_start &&
  +				ac->ac_g_ex.fe_group == ac->ac_b_ex.fe_group)
-@@ -3558,17 +3576,59 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -3498,17 +3516,59 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +}
  +
  +/*
@@ -365,7 +216,7 @@
  +
  + 	/* all form of preallocation discards first load group,
  +	 * so the only competing code is preallocation use.
-@@ -3584,14 +3644,30 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -3524,14 +3584,30 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +		ext3_get_group_no_and_offset(sb, pa->pa_pstart, &groupnr, &start);
  +		len = pa->pa_len;
  +		spin_unlock(&pa->pa_lock);
@@ -397,15 +248,16 @@
  +}
  +
  +#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,5)
-@@ -3651,6 +3727,7 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -3591,6 +3667,8 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +	 */
  +	ext3_lock_group(sb, grp);
  +	list_del_rcu(&pa->pa_group_list);
+++	BUG_ON(EXT3_GROUP_INFO(sb, grp)->bb_prealloc_nr == 0);
 ++	EXT3_GROUP_INFO(sb, grp)->bb_prealloc_nr--;
  +	ext3_unlock_group(sb, grp);
  +
  +	spin_lock(pa->pa_obj_lock);
-@@ -3735,6 +3812,7 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -3675,6 +3753,7 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +
  +	ext3_lock_group(sb, ac->ac_b_ex.fe_group);
  +	list_add_rcu(&pa->pa_group_list, &grp->bb_prealloc_list);
@@ -413,7 +265,7 @@
  +	ext3_unlock_group(sb, ac->ac_b_ex.fe_group);
  +
  +	spin_lock(pa->pa_obj_lock);
-@@ -3792,6 +3870,7 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -3732,6 +3811,7 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +
  +	ext3_lock_group(sb, ac->ac_b_ex.fe_group);
  +	list_add_rcu(&pa->pa_group_list, &grp->bb_prealloc_list);
@@ -421,7 +273,7 @@
  +	ext3_unlock_group(sb, ac->ac_b_ex.fe_group);
  +
  +	spin_lock(pa->pa_obj_lock);
-@@ -3839,6 +3918,7 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -3779,6 +3859,7 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +	ac.ac_sb = sb;
  +	ac.ac_inode = pa->pa_inode;
  +	ac.ac_op = EXT3_MB_HISTORY_DISCARD;
@@ -429,7 +281,7 @@
  +
  +	while (bit < end) {
  +		bit = mb_find_next_zero_bit(bitmap_bh->b_data, end, bit);
-@@ -3965,6 +4045,8 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -3905,6 +3986,8 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +
  +		spin_unlock(&pa->pa_lock);
  +
@@ -438,7 +290,7 @@
  +		list_del_rcu(&pa->pa_group_list);
  +		list_add(&pa->u.pa_tmp_list, &list);
  +	}
-@@ -4086,6 +4168,8 @@ Index: linux-2.6.5-7.311/fs/ext3/mballoc
+@@ -4026,6 +4109,8 @@ Index: linux-2.6.9-full/fs/ext3/mballoc.
  +		bitmap_bh = read_block_bitmap(sb, group);
  +
  +		ext3_lock_group(sb, group);




More information about the Pkg-lustre-svn-commit mailing list