aio: fix possible invalid memory access when DEBUG is enabled
dprintk() shouldn't access @ring after it's unmapped. Signed-off-by: Zhao Hongjiang <zhaohongjiang@huawei.com> Cc: stable@vger.kernel.org Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
697dfd8844
commit
91d80a84bb
1 changed files with 1 additions and 1 deletions
2
fs/aio.c
2
fs/aio.c
|
@ -1029,9 +1029,9 @@ static int aio_read_evt(struct kioctx *ioctx, struct io_event *ent)
|
|||
spin_unlock(&info->ring_lock);
|
||||
|
||||
out:
|
||||
kunmap_atomic(ring);
|
||||
dprintk("leaving aio_read_evt: %d h%lu t%lu\n", ret,
|
||||
(unsigned long)ring->head, (unsigned long)ring->tail);
|
||||
kunmap_atomic(ring);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue