hostfs_kern.c (ec2447c278ee973d35f38e53ca16ba7f965ae33d) hostfs_kern.c (fa0d7e3de6d6fc5004ad9dea0dd6b286af8f03e9)
1/*
2 * Copyright (C) 2000 - 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com)
3 * Licensed under the GPL
4 *
5 * Ported the filesystem routines to 2.5.
6 * 2003-02-10 Petr Baudis <pasky@ucw.cz>
7 */
8

--- 233 unchanged lines hidden (view full) ---

242 truncate_inode_pages(&inode->i_data, 0);
243 end_writeback(inode);
244 if (HOSTFS_I(inode)->fd != -1) {
245 close_file(&HOSTFS_I(inode)->fd);
246 HOSTFS_I(inode)->fd = -1;
247 }
248}
249
1/*
2 * Copyright (C) 2000 - 2007 Jeff Dike (jdike@{addtoit,linux.intel}.com)
3 * Licensed under the GPL
4 *
5 * Ported the filesystem routines to 2.5.
6 * 2003-02-10 Petr Baudis <pasky@ucw.cz>
7 */
8

--- 233 unchanged lines hidden (view full) ---

242 truncate_inode_pages(&inode->i_data, 0);
243 end_writeback(inode);
244 if (HOSTFS_I(inode)->fd != -1) {
245 close_file(&HOSTFS_I(inode)->fd);
246 HOSTFS_I(inode)->fd = -1;
247 }
248}
249
250static void hostfs_destroy_inode(struct inode *inode)
250static void hostfs_i_callback(struct rcu_head *head)
251{
251{
252 struct inode *inode = container_of(head, struct inode, i_rcu);
253 INIT_LIST_HEAD(&inode->i_dentry);
252 kfree(HOSTFS_I(inode));
253}
254
254 kfree(HOSTFS_I(inode));
255}
256
257static void hostfs_destroy_inode(struct inode *inode)
258{
259 call_rcu(&inode->i_rcu, hostfs_i_callback);
260}
261
255static int hostfs_show_options(struct seq_file *seq, struct vfsmount *vfs)
256{
257 const char *root_path = vfs->mnt_sb->s_fs_info;
258 size_t offset = strlen(root_ino) + 1;
259
260 if (strlen(root_path) > offset)
261 seq_printf(seq, ",%s", root_path + offset);
262

--- 732 unchanged lines hidden ---
262static int hostfs_show_options(struct seq_file *seq, struct vfsmount *vfs)
263{
264 const char *root_path = vfs->mnt_sb->s_fs_info;
265 size_t offset = strlen(root_ino) + 1;
266
267 if (strlen(root_path) > offset)
268 seq_printf(seq, ",%s", root_path + offset);
269

--- 732 unchanged lines hidden ---