The symbol 'private_data' is commonly used and makes grep'ing for specific uses difficult. Introduce the wrapper functions file_get_privdata and file_set_privdata to help with the struct file uses. Signed-off-by: H Hartley Sweeten <hsweeten@xxxxxxxxxxxxxxxxxxx> Cc: Matthew Wilcox <matthew@xxxxxx> --- diff --git a/include/linux/fs.h b/include/linux/fs.h index 9a96b4d..b357a17 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h @@ -961,6 +961,16 @@ extern spinlock_t files_lock; #define fput_atomic(x) atomic_long_add_unless(&(x)->f_count, -1, 1) #define file_count(x) atomic_long_read(&(x)->f_count) +static inline void *file_get_privdata(struct file *file) +{ + return file->private_data; +} + +static inline void file_set_privdata(struct file *file, void *data) +{ + file->private_data = data; +} + #ifdef CONFIG_DEBUG_WRITECOUNT static inline void file_take_write(struct file *f) { -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html