diff options
Diffstat (limited to 'include/linux/fs.h')
-rw-r--r-- | include/linux/fs.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h index 1393742bba9b..2fe920774abf 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -779,7 +779,7 @@ struct inode { | |||
779 | struct timespec i_ctime; | 779 | struct timespec i_ctime; |
780 | blkcnt_t i_blocks; | 780 | blkcnt_t i_blocks; |
781 | unsigned short i_bytes; | 781 | unsigned short i_bytes; |
782 | struct rw_semaphore i_alloc_sem; | 782 | atomic_t i_dio_count; |
783 | const struct file_operations *i_fop; /* former ->i_op->default_file_ops */ | 783 | const struct file_operations *i_fop; /* former ->i_op->default_file_ops */ |
784 | struct file_lock *i_flock; | 784 | struct file_lock *i_flock; |
785 | struct address_space *i_mapping; | 785 | struct address_space *i_mapping; |
@@ -1705,6 +1705,10 @@ struct super_operations { | |||
1705 | * set during data writeback, and cleared with a wakeup | 1705 | * set during data writeback, and cleared with a wakeup |
1706 | * on the bit address once it is done. | 1706 | * on the bit address once it is done. |
1707 | * | 1707 | * |
1708 | * I_REFERENCED Marks the inode as recently references on the LRU list. | ||
1709 | * | ||
1710 | * I_DIO_WAKEUP Never set. Only used as a key for wait_on_bit(). | ||
1711 | * | ||
1708 | * Q: What is the difference between I_WILL_FREE and I_FREEING? | 1712 | * Q: What is the difference between I_WILL_FREE and I_FREEING? |
1709 | */ | 1713 | */ |
1710 | #define I_DIRTY_SYNC (1 << 0) | 1714 | #define I_DIRTY_SYNC (1 << 0) |
@@ -1718,6 +1722,8 @@ struct super_operations { | |||
1718 | #define __I_SYNC 7 | 1722 | #define __I_SYNC 7 |
1719 | #define I_SYNC (1 << __I_SYNC) | 1723 | #define I_SYNC (1 << __I_SYNC) |
1720 | #define I_REFERENCED (1 << 8) | 1724 | #define I_REFERENCED (1 << 8) |
1725 | #define __I_DIO_WAKEUP 9 | ||
1726 | #define I_DIO_WAKEUP (1 << I_DIO_WAKEUP) | ||
1721 | 1727 | ||
1722 | #define I_DIRTY (I_DIRTY_SYNC | I_DIRTY_DATASYNC | I_DIRTY_PAGES) | 1728 | #define I_DIRTY (I_DIRTY_SYNC | I_DIRTY_DATASYNC | I_DIRTY_PAGES) |
1723 | 1729 | ||
@@ -1828,7 +1834,6 @@ struct file_system_type { | |||
1828 | struct lock_class_key i_lock_key; | 1834 | struct lock_class_key i_lock_key; |
1829 | struct lock_class_key i_mutex_key; | 1835 | struct lock_class_key i_mutex_key; |
1830 | struct lock_class_key i_mutex_dir_key; | 1836 | struct lock_class_key i_mutex_dir_key; |
1831 | struct lock_class_key i_alloc_sem_key; | ||
1832 | }; | 1837 | }; |
1833 | 1838 | ||
1834 | extern struct dentry *mount_ns(struct file_system_type *fs_type, int flags, | 1839 | extern struct dentry *mount_ns(struct file_system_type *fs_type, int flags, |
@@ -2404,6 +2409,8 @@ enum { | |||
2404 | }; | 2409 | }; |
2405 | 2410 | ||
2406 | void dio_end_io(struct bio *bio, int error); | 2411 | void dio_end_io(struct bio *bio, int error); |
2412 | void inode_dio_wait(struct inode *inode); | ||
2413 | void inode_dio_done(struct inode *inode); | ||
2407 | 2414 | ||
2408 | ssize_t __blockdev_direct_IO(int rw, struct kiocb *iocb, struct inode *inode, | 2415 | ssize_t __blockdev_direct_IO(int rw, struct kiocb *iocb, struct inode *inode, |
2409 | struct block_device *bdev, const struct iovec *iov, loff_t offset, | 2416 | struct block_device *bdev, const struct iovec *iov, loff_t offset, |