Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

switch sysfs to ->evict_inode()

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>

Al Viro 01cd9fef 8267952b

+5 -5
+3 -3
fs/sysfs/inode.c
··· 312 312 * The sysfs_dirent serves as both an inode and a directory entry for sysfs. 313 313 * To prevent the sysfs inode numbers from being freed prematurely we take a 314 314 * reference to sysfs_dirent from the sysfs inode. A 315 - * super_operations.delete_inode() implementation is needed to drop that 315 + * super_operations.evict_inode() implementation is needed to drop that 316 316 * reference upon inode destruction. 317 317 */ 318 - void sysfs_delete_inode(struct inode *inode) 318 + void sysfs_evict_inode(struct inode *inode) 319 319 { 320 320 struct sysfs_dirent *sd = inode->i_private; 321 321 322 322 truncate_inode_pages(&inode->i_data, 0); 323 - clear_inode(inode); 323 + end_writeback(inode); 324 324 sysfs_put(sd); 325 325 } 326 326
+1 -1
fs/sysfs/mount.c
··· 29 29 static const struct super_operations sysfs_ops = { 30 30 .statfs = simple_statfs, 31 31 .drop_inode = generic_delete_inode, 32 - .delete_inode = sysfs_delete_inode, 32 + .evict_inode = sysfs_evict_inode, 33 33 }; 34 34 35 35 struct sysfs_dirent sysfs_root = {
+1 -1
fs/sysfs/sysfs.h
··· 198 198 * inode.c 199 199 */ 200 200 struct inode *sysfs_get_inode(struct super_block *sb, struct sysfs_dirent *sd); 201 - void sysfs_delete_inode(struct inode *inode); 201 + void sysfs_evict_inode(struct inode *inode); 202 202 int sysfs_sd_setattr(struct sysfs_dirent *sd, struct iattr *iattr); 203 203 int sysfs_permission(struct inode *inode, int mask); 204 204 int sysfs_setattr(struct dentry *dentry, struct iattr *iattr);