]> git.baikalelectronics.ru Git - kernel.git/commit
fuse: fix time_to_jiffies nsec sanity check
authorDavid Sheets <david.sheets@docker.com>
Fri, 13 Jan 2017 15:58:30 +0000 (15:58 +0000)
committerMiklos Szeredi <mszeredi@redhat.com>
Fri, 13 Jan 2017 16:20:47 +0000 (17:20 +0100)
commit5eae4a898981c1f626653368d9172d78dfb92e37
treeca9b10adc7030707f1c7f010e48388efdde0d6fa
parent2d405c4c8d8ba6357f28a479f6112629d5f9f592
fuse: fix time_to_jiffies nsec sanity check

Commit d135074f96ae ("fuse: use timespec64") introduced clamped nsec values
in time_to_jiffies but used the max of nsec and NSEC_PER_SEC - 1 instead of
the min. Because of this, dentries would stay in the cache longer than
requested and go stale in scenarios that relied on their timely eviction.

Fixes: d135074f96ae ("fuse: use timespec64")
Signed-off-by: David Sheets <dsheets@docker.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Cc: <stable@vger.kernel.org> # 4.9
fs/fuse/dir.c