]> git.baikalelectronics.ru Git - kernel.git/commit
fat: Fix _fat_bmap() race
authorOGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Thu, 6 Nov 2008 20:53:56 +0000 (12:53 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 6 Nov 2008 23:41:21 +0000 (15:41 -0800)
commita666b8ec7d696a05b2af42b2defa3915cfc5d303
tree2950aa2baa218493329873a61aa234c7fcc5d83e
parent59eca039669485c1064f02d3846bb131d09ae12d
fat: Fix _fat_bmap() race

fat_get_cluster() assumes the requested blocknr isn't truncated during
read. _fat_bmap() doesn't follow this rule.

This protects it by ->i_mutex.

Signed-off-by: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/fat/inode.c