1
0
Fork 0
alistair23-linux/drivers/s390
Qinglang Miao 857b1403c3 s390/cio: fix use-after-free in ccw_device_destroy_console
[ Upstream commit 14d4c4fa46 ]

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: 37db8985b2 ("s390/cio: add basic protected virtualization support")
Reported-by: Hulk Robot <hulkci@huawei.com>
Suggested-by: Cornelia Huck <cohuck@redhat.com>
Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Vineeth Vijayan <vneethv@linux.ibm.com>
[vneethv@linux.ibm.com: Slight modification in the commit-message]
Signed-off-by: Vineeth Vijayan <vneethv@linux.ibm.com>
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2020-12-30 11:51:23 +01:00
..
block s390/dasd: fix null pointer dereference for ERP requests 2020-11-24 13:29:23 +01:00
char s390 updates for the 5.4 merge window 2019-09-17 14:04:43 -07:00
cio s390/cio: fix use-after-free in ccw_device_destroy_console 2020-12-30 11:51:23 +01:00
crypto s390/pkey: fix paes selftest failure with paes and pkey static build 2020-11-10 12:37:32 +01:00
net s390/qeth: fix tear down of async TX buffers 2020-12-02 08:49:51 +01:00
scsi scsi: zfcp: Fix use-after-free in request timeout handlers 2020-08-26 10:40:52 +02:00
virtio virtio/s390: fix race on airq_areas[] 2019-07-26 13:36:18 +02:00
Makefile s390: remove pointless drivers-y in drivers/s390/Makefile 2019-09-16 13:21:51 +02:00