Skip to content
Commit 14d4c4fa authored by Qinglang Miao's avatar Qinglang Miao Committed by Heiko Carstens
Browse files

s390/cio: fix use-after-free in ccw_device_destroy_console



Use of sch->dev reference after the put_device() call could trigger
the use-after-free bugs.

Fix this by simply adjusting the position of put_device.

Fixes: 37db8985 ("s390/cio: add basic protected virtualization support")
Reported-by: default avatarHulk Robot <hulkci@huawei.com>
Suggested-by: default avatarCornelia Huck <cohuck@redhat.com>
Signed-off-by: default avatarQinglang Miao <miaoqinglang@huawei.com>
Reviewed-by: default avatarCornelia Huck <cohuck@redhat.com>
Reviewed-by: default avatarVineeth Vijayan <vneethv@linux.ibm.com>
[vneethv@linux.ibm.com: Slight modification in the commit-message]
Signed-off-by: default avatarVineeth Vijayan <vneethv@linux.ibm.com>
Signed-off-by: default avatarHeiko Carstens <hca@linux.ibm.com>
parent 8cc0dcfd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment