]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
soc: fsl: dpio: Use after free in dpaa2_dpio_remove()
authorDan Carpenter <dan.carpenter@oracle.com>
Mon, 4 Feb 2019 14:10:05 +0000 (17:10 +0300)
committerLi Yang <leoyang.li@nxp.com>
Mon, 4 Feb 2019 20:58:49 +0000 (14:58 -0600)
commitc1959066ac02bd123201352ff5a8c506469a1645
tree7c0fb14ecf94c4c233878effcaea1aaf6b280a62
parent3c0d64e867ed78a782a8a00d3b519396d9c5a2db
soc: fsl: dpio: Use after free in dpaa2_dpio_remove()

The dpaa2_io_down(priv->io) call frees "priv->io" so I've shifted the
code around a little bit to avoid the use after free.

Fixes: 991e873223e9 ("soc: fsl: dpio: use a cpumask to identify which cpus are unused")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Li Yang <leoyang.li@nxp.com>
drivers/soc/fsl/dpio/dpio-driver.c