[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[Cluster-devel] untested patches to allow cluster tree (stable branch) to compile on 2.6.17



 brassow

Index: cluster-stable/gfs-kernel/src/gfs/diaper.c
===================================================================
--- cluster-stable.orig/gfs-kernel/src/gfs/diaper.c	2005-05-05
18:24:16.000000000 -0500
+++ cluster-stable/gfs-kernel/src/gfs/diaper.c	2006-06-19
16:52:58.000000000 -0500
@@ -232,9 +232,9 @@ get_dummy_sb(struct diaper_holder *dh)
 	struct inode *inode;
 	int error;
 
-	down(&real->bd_mount_sem);
+	mutex_lock(&real->bd_mount_mutex);
 	sb = sget(&gfs_fs_type, gfs_test_bdev_super, gfs_set_bdev_super,
real);
-	up(&real->bd_mount_sem);
+	mutex_unlock(&real->bd_mount_mutex);
 	if (IS_ERR(sb))
 		return PTR_ERR(sb);
 
@@ -363,7 +363,7 @@ diaper_get(struct block_device *real, in
 	if (!diaper)
 		goto fail_remove;
 
-	down(&diaper->bd_sem);
+	mutex_lock(&diaper->bd_mutex);
 	if (!diaper->bd_openers) {
 		diaper->bd_disk = gd;
 		diaper->bd_contains = diaper;
@@ -372,7 +372,7 @@ diaper_get(struct block_device *real, in
 	} else
 		printk("GFS: diaper: reopening\n");
 	diaper->bd_openers++;
-	up(&diaper->bd_sem);
+	mutex_unlock(&diaper->bd_mutex);
 
 	dh->dh_mempool = mempool_create(512,
 					mempool_alloc_slab, mempool_free_slab,
@@ -395,14 +395,14 @@ diaper_get(struct block_device *real, in
 	mempool_destroy(dh->dh_mempool);
 
  fail_bdput:
-	down(&diaper->bd_sem);
+	mutex_lock(&diaper->bd_mutex);
 	if (!--diaper->bd_openers) {
 		invalidate_bdev(diaper, 1);
 		diaper->bd_contains = NULL;
 		diaper->bd_disk = NULL;
 	} else
 		printk("GFS: diaper: not closed\n");
-	up(&diaper->bd_sem);
+	mutex_unlock(&diaper->bd_mutex);
 	bdput(diaper);	
 
  fail_remove:
@@ -437,14 +437,14 @@ diaper_put(struct diaper_holder *dh)
 
 	mempool_destroy(dh->dh_mempool);
 
-	down(&diaper->bd_sem);
+	mutex_lock(&diaper->bd_mutex);
 	if (!--diaper->bd_openers) {
 		invalidate_bdev(diaper, 1);
 		diaper->bd_contains = NULL;
 		diaper->bd_disk = NULL;
 	} else
 		printk("GFS: diaper: not closed\n");
-	up(&diaper->bd_sem);
+	mutex_unlock(&diaper->bd_mutex);
 
 	bdput(diaper);
 	del_gendisk(gd);
Index: cluster-stable/gfs-kernel/src/gfs/ops_address.c
===================================================================
--- cluster-stable.orig/gfs-kernel/src/gfs/ops_address.c	2005-05-11
18:19:59.000000000 -0500
+++ cluster-stable/gfs-kernel/src/gfs/ops_address.c	2006-06-19
17:08:44.000000000 -0500
@@ -451,7 +451,7 @@ gfs_direct_IO(int rw, struct kiocb *iocb
 	struct inode *inode = file->f_mapping->host;
 	struct gfs_inode *ip = get_v2ip(inode);
 	struct gfs_sbd *sdp = ip->i_sbd;
-	get_blocks_t *gb = get_blocks;
+	get_block_t *gb = get_block;
 
 	atomic_inc(&sdp->sd_ops_address);
 
@@ -460,7 +460,7 @@ gfs_direct_IO(int rw, struct kiocb *iocb
 		return -EINVAL;
 
 	if (rw == WRITE && !get_transaction)
-		gb = get_blocks_noalloc;
+		gb = get_block_noalloc;
 
 	return blockdev_direct_IO(rw, iocb, inode,
 				  inode->i_sb->s_bdev, iov,
Index: cluster-stable/gfs-kernel/src/nolock/main.c
===================================================================
--- cluster-stable.orig/gfs-kernel/src/nolock/main.c	2005-04-26
13:32:37.000000000 -0500
+++ cluster-stable/gfs-kernel/src/nolock/main.c	2006-06-19
17:24:54.000000000 -0500
@@ -243,13 +243,14 @@ nolock_plock_get(lm_lockspace_t *lockspa
 		 struct lm_lockname *name,
 		 struct file *file, struct file_lock *fl)
 {
-	struct file_lock *tmp;
+	int r;
+	struct file_lock tmp;
 
 	lock_kernel();
-	tmp = posix_test_lock(file, fl);
+	r = posix_test_lock(file, fl, &tmp);
 	fl->fl_type = F_UNLCK;
-	if (tmp)
-		memcpy(fl, tmp, sizeof(struct file_lock));
+	if (r)
+		memcpy(fl, &tmp, sizeof(struct file_lock));
 	unlock_kernel();
 
 	return 0;
Index: cluster-stable/gfs-kernel/src/gfs/ops_file.c
===================================================================
--- cluster-stable.orig/gfs-kernel/src/gfs/ops_file.c	2006-02-13
14:28:26.000000000 -0600
+++ cluster-stable/gfs-kernel/src/gfs/ops_file.c	2006-06-19
17:24:37.000000000 -0500
@@ -1465,12 +1465,13 @@ gfs_lock(struct file *file, int cmd, str
 
 	if (sdp->sd_args.ar_localflocks) {
 		if (IS_GETLK(cmd)) {
-			struct file_lock *tmp;
+			int r;
+			struct file_lock tmp;
 			lock_kernel();
-			tmp = posix_test_lock(file, fl);
+			r = posix_test_lock(file, fl, &tmp);
 			fl->fl_type = F_UNLCK;
-			if (tmp)
-				memcpy(fl, tmp, sizeof(struct file_lock));
+			if (r)
+				memcpy(fl, &tmp, sizeof(struct file_lock));
 			unlock_kernel();
 		        return 0;
 		} else {
Index: cluster-stable/gfs-kernel/src/gfs/ops_fstype.c
===================================================================
--- cluster-stable.orig/gfs-kernel/src/gfs/ops_fstype.c	2006-02-13
15:27:44.000000000 -0600
+++ cluster-stable/gfs-kernel/src/gfs/ops_fstype.c	2006-06-19
17:26:42.000000000 -0500
@@ -697,9 +697,9 @@ gfs_get_sb(struct file_system_type *fs_t
 		return (struct super_block *)diaper;
 	}
 
-	down(&diaper->bd_mount_sem);
+	mutex_lock(&diaper->bd_mount_mutex);
 	sb = sget(fs_type, gfs_test_bdev_super, gfs_set_bdev_super, diaper);
-	up(&diaper->bd_mount_sem);
+	mutex_unlock(&diaper->bd_mount_mutex);
 	if (IS_ERR(sb))
 		goto out;
 
Index: cluster-stable/gnbd-kernel/src/gnbd.c
===================================================================
--- cluster-stable.orig/gnbd-kernel/src/gnbd.c	2006-02-13
14:34:17.000000000 -0600
+++ cluster-stable/gnbd-kernel/src/gnbd.c	2006-06-19 17:30:35.000000000
-0500
@@ -1047,7 +1047,3 @@ module_exit(gnbd_cleanup);
 MODULE_DESCRIPTION("Network Block Device");
 MODULE_LICENSE("GPL");
 
-#ifndef NDEBUG
-MODULE_PARM(debugflags, "i");
-MODULE_PARM_DESC(debugflags, "flags for controlling debug output");
-#endif



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]