staging: rts5208: fix memleaks on error handling paths in probe
authorEvgeny Novikov <novikov@ispras.ru>
Tue, 23 Jun 2020 14:12:30 +0000 (17:12 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Jun 2020 13:40:27 +0000 (15:40 +0200)
commit11507bf9a8832741db69efd32bf09a2ab26426bf
treec4325663044a2b4bb121ac957156658fc9bc8fef
parent8ce8668bfb64f2973cc1276c54619aceede6498a
staging: rts5208: fix memleaks on error handling paths in probe

rtsx_probe() allocates host, but does not free it on error handling
paths. The patch adds missed scsi_host_put().

Found by Linux Driver Verification project (linuxtesting.org).

Signed-off-by: Evgeny Novikov <novikov@ispras.ru>
Link: https://lore.kernel.org/r/20200623141230.7258-1-novikov@ispras.ru
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rts5208/rtsx.c