lkml.org 
[lkml]   [2006]   [Sep]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] fix suspend to disk swap_type_of() function
The attached patch fixes swap_type_of() for the case the suspend device
is not the first swap device. This looks like a cut'n'paste fix. Patch
is against 2.6.17.8.
--
Andreas Steinmetz SPAMmers use robotrap@domdv.de
--- linux.orig/mm/swapfile.c 2006-09-12 19:33:51.000000000 +0200
+++ linux/mm/swapfile.c 2006-09-12 19:34:58.000000000 +0200
@@ -444,7 +444,7 @@ int swap_type_of(dev_t device)
spin_unlock(&swap_lock);
return i;
}
- inode = swap_info->swap_file->f_dentry->d_inode;
+ inode = swap_info[i].swap_file->f_dentry->d_inode;
if (S_ISBLK(inode->i_mode) &&
device == MKDEV(imajor(inode), iminor(inode))) {
spin_unlock(&swap_lock);
\
 
 \ /
  Last update: 2006-09-12 19:51    [W:0.024 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site