usb: gadget: pch_udc: fix use after free
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Wed, 6 Nov 2019 20:28:21 +0000 (14:28 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 7 Nov 2019 10:14:51 +0000 (11:14 +0100)
commit66d1b0c0580b7f1b1850ee4423f32ac42afa2e92
tree3fbaef7be14feefc43af971dbd021437a9da1d76
parent51d11d0a9ea46203241e25651af90ca4c5e2d71a
usb: gadget: pch_udc: fix use after free

Remove pointer dereference after free.

pci_pool_free doesn't care about contents of td.
It's just a void* for it

Addresses-Coverity-ID: 1091173 ("Use after free")
Cc: stable@vger.kernel.org
Acked-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Link: https://lore.kernel.org/r/20191106202821.GA20347@embeddedor
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/gadget/udc/pch_udc.c