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

[Cluster-devel] cluster/gfs-kernel/src/gfs dir.c ops_address.c ...



CVSROOT:	/cvs/cluster
Module name:	cluster
Branch: 	STABLE
Changes by:	teigland sourceware org	2006-06-29 16:50:41

Modified files:
	gfs-kernel/src/gfs: dir.c ops_address.c ops_file.c ops_fstype.c 

Log message:
	fixes to get compiling on 2.6.17
	don't know if the get_blocks changes are correct

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/dir.c.diff?cvsroot=cluster&only_with_tag=STABLE&r1=1.8.6.1.2.2&r2=1.8.6.1.2.3
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/ops_address.c.diff?cvsroot=cluster&only_with_tag=STABLE&r1=1.5.2.1.4.2.2.1&r2=1.5.2.1.4.2.2.2
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/ops_file.c.diff?cvsroot=cluster&only_with_tag=STABLE&r1=1.16.6.2.2.4&r2=1.16.6.2.2.5
http://sourceware.org/cgi-bin/cvsweb.cgi/cluster/gfs-kernel/src/gfs/ops_fstype.c.diff?cvsroot=cluster&only_with_tag=STABLE&r1=1.13.2.1.4.2.2.2&r2=1.13.2.1.4.2.2.3

--- cluster/gfs-kernel/src/gfs/dir.c	2006/02/20 03:58:05	1.8.6.1.2.2
+++ cluster/gfs-kernel/src/gfs/dir.c	2006/06/29 16:50:41	1.8.6.1.2.3
@@ -59,6 +59,7 @@
 
 #include <linux/sched.h>
 #include <linux/slab.h>
+#include <linux/vmalloc.h>
 #include <linux/smp_lock.h>
 #include <linux/spinlock.h>
 #include <asm/semaphore.h>
--- cluster/gfs-kernel/src/gfs/ops_address.c	2006/06/28 15:58:11	1.5.2.1.4.2.2.1
+++ cluster/gfs-kernel/src/gfs/ops_address.c	2006/06/29 16:50:41	1.5.2.1.4.2.2.2
@@ -104,16 +104,14 @@
 
 static int
 get_blocks(struct inode *inode, sector_t lblock,
-	   unsigned long max_blocks,
 	   struct buffer_head *bh_result, int create)
 {
 	struct gfs_inode *ip = get_v2ip(inode);
 	int new = create;
 	uint64_t dblock;
-	uint32_t extlen;
 	int error;
 
-	error = gfs_block_map(ip, lblock, &new, &dblock, &extlen);
+	error = gfs_block_map(ip, lblock, &new, &dblock, NULL);
 	if (error)
 		return error;
 
@@ -124,13 +122,10 @@
 	if (new)
 		set_buffer_new(bh_result);
 
-	if (extlen > max_blocks)
-		extlen = max_blocks;
-	bh_result->b_size = extlen << inode->i_blkbits;
-
 	return 0;
 }
 
+#if 0
 /**
  * get_blocks_noalloc - 
  * @inode:
@@ -144,12 +139,11 @@
 
 static int
 get_blocks_noalloc(struct inode *inode, sector_t lblock,
-		   unsigned long max_blocks,
 		   struct buffer_head *bh_result, int create)
 {
 	int error;
 
-	error = get_blocks(inode, lblock, max_blocks, bh_result, FALSE);
+	error = get_blocks(inode, lblock, bh_result, FALSE);
 	if (error)
 		return error;
 
@@ -159,6 +153,7 @@
 
 	return 0;
 }
+#endif
 
 /**
  * gfs_writepage - Write complete page
--- cluster/gfs-kernel/src/gfs/ops_file.c	2006/02/13 20:28:26	1.16.6.2.2.4
+++ cluster/gfs-kernel/src/gfs/ops_file.c	2006/06/29 16:50:41	1.16.6.2.2.5
@@ -1465,12 +1465,13 @@
 
 	if (sdp->sd_args.ar_localflocks) {
 		if (IS_GETLK(cmd)) {
-			struct file_lock *tmp;
+			struct file_lock tmp;
+			int ret;
 			lock_kernel();
-			tmp = posix_test_lock(file, fl);
+			ret = posix_test_lock(file, fl, &tmp);
 			fl->fl_type = F_UNLCK;
-			if (tmp)
-				memcpy(fl, tmp, sizeof(struct file_lock));
+			if (ret)
+				memcpy(fl, &tmp, sizeof(struct file_lock));
 			unlock_kernel();
 		        return 0;
 		} else {
--- cluster/gfs-kernel/src/gfs/ops_fstype.c	2006/02/13 21:27:44	1.13.2.1.4.2.2.2
+++ cluster/gfs-kernel/src/gfs/ops_fstype.c	2006/06/29 16:50:41	1.13.2.1.4.2.2.3
@@ -697,9 +697,9 @@
 		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;
 


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