tuxonice-head fuse compile error

Woody Suwalski <[email protected]> Thu, 20 Sep 2012 22:21:58 -0400
Newsgroups gmane.linux.swsusp.devel
Message-ID <[email protected]>
I have hit the same problem trying to build 3.6 kernels...
Here is the fuse fix:
--- linux-3.6/fs/fuse/fuse.h.old    2012-08-28 18:38:25.000000000 -0400
+++ linux-3.6/fs/fuse/fuse.h    2012-08-28 18:38:58.000000000 -0400
@@ -1,7 +1,7 @@
  #define FUSE_MIGHT_FREEZE(superblock, desc) \
  do { \
      int printed = 0; \
-    while (superblock->s_frozen != SB_UNFROZEN) { \
+    while (superblock->s_writers.frozen != SB_UNFROZEN) { \
          if (!printed) { \
              printk(KERN_INFO "%d frozen in " desc ".\n", \
                          current->pid); \


I also submit the patch (very unofficial) which I am using on top of 
current TOI to build 3.6.

Woody

_______________________________________________
TuxOnIce-devel mailing list
[email protected]
http://lists.tuxonice.net/listinfo/tuxonice-devel
049_toi_fix.patch (text/x-diff, 2.3 KB)
--- linux-3.6/fs/fuse/fuse.h.old	2012-08-28 18:38:25.000000000 -0400
+++ linux-3.6/fs/fuse/fuse.h	2012-08-28 18:38:58.000000000 -0400
@@ -1,7 +1,7 @@
 #define FUSE_MIGHT_FREEZE(superblock, desc) \
 do { \
 	int printed = 0; \
-	while (superblock->s_frozen != SB_UNFROZEN) { \
+	while (superblock->s_writers.frozen != SB_UNFROZEN) { \
 		if (!printed) { \
 			printk(KERN_INFO "%d frozen in " desc ".\n", \
 						current->pid); \
--- linux-3.6/kernel/power/tuxonice_builtin.c.old	2012-08-28 18:06:44.000000000 -0400
+++ linux-3.6/kernel/power/tuxonice_builtin.c	2012-08-28 18:12:11.000000000 -0400
@@ -61,24 +61,22 @@ static void copyback_high(void)
 	if (!pbe_page)
 		return;
 
-	this_pbe = (struct pbe *) kmap_atomic(pbe_page, KM_BOUNCE_READ);
+	this_pbe = (struct pbe *) kmap_atomic(pbe_page);
 	first_pbe = this_pbe;
 
 	while (this_pbe) {
 		int loop = (PAGE_SIZE / sizeof(unsigned long)) - 1;
 
-		origpage = kmap_atomic(pfn_to_page((unsigned long) this_pbe->orig_address),
-			KM_BIO_DST_IRQ);
-		copypage = kmap_atomic((struct page *) this_pbe->address,
-			KM_BIO_SRC_IRQ);
+		origpage = kmap_atomic(pfn_to_page((unsigned long) this_pbe->orig_address));
+		copypage = kmap_atomic((struct page *) this_pbe->address);
 
 		while (loop >= 0) {
 			*(origpage + loop) = *(copypage + loop);
 			loop--;
 		}
 
-		kunmap_atomic(origpage, KM_BIO_DST_IRQ);
-		kunmap_atomic(copypage, KM_BIO_SRC_IRQ);
+		kunmap_atomic(origpage);
+		kunmap_atomic(copypage);
 
 		if (!this_pbe->next)
 			break;
@@ -88,16 +86,15 @@ static void copyback_high(void)
 			pbe_index++;
 		} else {
 			pbe_page = (struct page *) this_pbe->next;
-			kunmap_atomic(first_pbe, KM_BOUNCE_READ);
+			kunmap_atomic(first_pbe);
 			if (!pbe_page)
 				return;
-			this_pbe = (struct pbe *) kmap_atomic(pbe_page,
-					KM_BOUNCE_READ);
+			this_pbe = (struct pbe *) kmap_atomic(pbe_page);
 			first_pbe = this_pbe;
 			pbe_index = 1;
 		}
 	}
-	kunmap_atomic(first_pbe, KM_BOUNCE_READ);
+	kunmap_atomic(first_pbe);
 }
 
 #else /* CONFIG_HIGHMEM */
--- linux-3.6/mm/swapfile.c.old	2012-08-28 22:46:35.000000000 -0400
+++ linux-3.6/mm/swapfile.c	2012-08-28 22:48:22.000000000 -0400
@@ -2303,6 +2303,7 @@ pgoff_t __page_file_index(struct page *p
 	VM_BUG_ON(!PageSwapCache(page));
 	return swp_offset(swap);
 }
+EXPORT_SYMBOL_GPL(__page_file_index);
 
 struct swap_info_struct *get_swap_info_struct(unsigned type)
 {