diff options
author | 2020-11-13 19:05:37 +0300 | |
---|---|---|
committer | 2020-12-10 22:37:32 +0100 | |
commit | 8c293f545419c0d3da9a2a70df0311aa4027a820 (patch) | |
tree | 686a6c8291e7112d359085608ba4aaedd7101961 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | mtd: onenand: Use mtd->oops_panic_write as condition (diff) | |
download | wireguard-linux-8c293f545419c0d3da9a2a70df0311aa4027a820.tar.xz wireguard-linux-8c293f545419c0d3da9a2a70df0311aa4027a820.zip |
mtd: plat-ram: correctly free memory on error path in platram_probe()
If an error happens in mtd_device_parse_register or mtd_device_register,
memory allocated for struct platram_info is leaked.
Make platram_probe() call platram_remove() on all error paths
after struct platram_info allocation to correctly free resources.
Found by Linux Driver Verification project (linuxtesting.org).
Signed-off-by: Baskov Evgeiny <baskov@ispras.ru>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20201113160537.899-1-baskov@ispras.ru
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions