diff options
author | Zhao Hongjiang <zhaohongjiang@huawei.com> | 2013-04-26 11:03:53 +0800 |
---|---|---|
committer | Ben Hutchings <ben@decadent.org.uk> | 2013-05-13 15:02:09 +0100 |
commit | bf0f91c05b5abf5fafa0b1118db4c33fc011fcd1 (patch) | |
tree | 216cdb8259ca19182851e1f3325971aa7d09c2e3 /fs/aio.c | |
parent | 419f4ba0f032c8d906153d24e017f4bee6df26f5 (diff) |
aio: fix possible invalid memory access when DEBUG is enabled
commit 91d80a84bbc8f28375cca7e65ec666577b4209ad upstream.
dprintk() shouldn't access @ring after it's unmapped.
Signed-off-by: Zhao Hongjiang <zhaohongjiang@huawei.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
[bwh: Backported to 3.2: keep the second argument to kunmap_atomic()]
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'fs/aio.c')
-rw-r--r-- | fs/aio.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1112,9 +1112,9 @@ static int aio_read_evt(struct kioctx *ioctx, struct io_event *ent) spin_unlock(&info->ring_lock); out: - kunmap_atomic(ring, KM_USER0); dprintk("leaving aio_read_evt: %d h%lu t%lu\n", ret, (unsigned long)ring->head, (unsigned long)ring->tail); + kunmap_atomic(ring, KM_USER0); return ret; } |