diff options
author | J. Bruce Fields <bfields@citi.umich.edu> | 2007-07-19 01:49:18 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-19 10:04:52 -0700 |
commit | a280df32db291f41b3922ac218674be526af5b9b (patch) | |
tree | 133e80664abd69ad14b3951112d2916e26f51680 /fs/ufs/balloc.c | |
parent | d688abf50bd5a30d2c44dea2a72dd59052cd3cce (diff) | |
download | op-kernel-dev-a280df32db291f41b3922ac218674be526af5b9b.zip op-kernel-dev-a280df32db291f41b3922ac218674be526af5b9b.tar.gz |
nfsd: fix possible read-ahead cache and export table corruption
The value of nperbucket calculated here is too small--we should be rounding up
instead of down--with the result that the index j in the following loop can
overflow the raparm_hash array. At least in my case, the next thing in memory
turns out to be export_table, so the symptoms I see are crashes caused by the
appearance of four zeroed-out export entries in the first bucket of the hash
table of exports (which were actually entries in the readahead cache, a
pointer to which had been written to the export table in this initialization
code).
It looks like the bug was probably introduced with commit
fce1456a19f5c08b688c29f00ef90fdfa074c79b ("knfsd: make the readahead params
cache SMP-friendly").
Cc: <stable@kernel.org>
Cc: Greg Banks <gnb@melbourne.sgi.com>
Signed-off-by: "J. Bruce Fields" <bfields@citi.umich.edu>
Acked-by: NeilBrown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/ufs/balloc.c')
0 files changed, 0 insertions, 0 deletions