Skip to contentSkip to conversation

freeze/thaw fs when BLOCK=n

PATCH In review Randy Dunlap 2 participants 2 messages Nov 17, 2006

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 freeze/thaw fs when BLOCK=n

From: Randy Dunlap <[email protected]>

Fix freeze/thaw filesystems with CONFIG_BLOCK disabled:
kernel/power/process.c:124: warning: implicit declaration of function 'freeze_fil esystems'
kernel/power/process.c:189: warning: implicit declaration of function 'thaw_files ystems'

---
 include/linux/buffer_head.h |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
include/linux/buffer_head.h +2 -1
@@ -314,7 +314,8 @@ static inline void invalidate_inode_buff
 static inline int remove_inode_buffers(struct inode *inode) { return 1; }
 static inline int sync_mapping_buffers(struct address_space *mapping) { return 0; }
 static inline void invalidate_bdev(struct block_device *bdev, int destroy_dirty_buffers) {}
-
+static inline void freeze_filesystems(void) {}
+static inline void thaw_filesystems(void) {}
 
 #endif /* CONFIG_BLOCK */
 #endif /* _LINUX_BUFFER_HEAD_H */

---

#1 lore raw

Hi!

Quoted 9 lines

From: Randy Dunlap <[email protected]>

Fix freeze/thaw filesystems with CONFIG_BLOCK disabled:
kernel/power/process.c:124: warning: implicit declaration of function 'freeze_fil esystems'
kernel/power/process.c:189: warning: implicit declaration of function 'thaw_files ystems'

I believe we'll simply want to remove {thaw,freeze}_filesystems. XFS problem is solved with freezeable workqueues, and {thaw,freeze}_filesystems has problems if someone is creating dm snapshots in the meantime.
Pavel

Quoted 19 lines
---
 include/linux/buffer_head.h |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
include/linux/buffer_head.h +2 -2
@@ -314,7 +314,8 @@ static inline void invalidate_inode_buff
 static inline int remove_inode_buffers(struct inode *inode) { return 1; }
 static inline int sync_mapping_buffers(struct address_space *mapping) { return 0; }
 static inline void invalidate_bdev(struct block_device *bdev, int destroy_dirty_buffers) {}
-
+static inline void freeze_filesystems(void) {}
+static inline void thaw_filesystems(void) {}
 
 #endif /* CONFIG_BLOCK */
 #endif /* _LINUX_BUFFER_HEAD_H */
 
 
---
Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html