summaryrefslogtreecommitdiff
path: root/scripts/gdb/linux/utils.py
diff options
context:
space:
mode:
authorYuan Can <yuancan@huawei.com>2022-11-22 04:57:51 +0300
committerMartin K. Petersen <martin.petersen@oracle.com>2022-11-24 06:44:44 +0300
commit9c9ff300e0de07475796495d86f449340d454a0c (patch)
treef016975531a5658882889e5d9a4b5c9e9af8ccb3 /scripts/gdb/linux/utils.py
parentcfee29ffb45b1c9798011b19d454637d1b0fe87d (diff)
downloadlinux-9c9ff300e0de07475796495d86f449340d454a0c.tar.xz
scsi: hpsa: Fix possible memory leak in hpsa_init_one()
The hpda_alloc_ctlr_info() allocates h and its field reply_map. However, in hpsa_init_one(), if alloc_percpu() failed, the hpsa_init_one() jumps to clean1 directly, which frees h and leaks the h->reply_map. Fix by calling hpda_free_ctlr_info() to release h->replay_map and h instead free h directly. Fixes: 8b834bff1b73 ("scsi: hpsa: fix selection of reply queue") Signed-off-by: Yuan Can <yuancan@huawei.com> Link: https://lore.kernel.org/r/20221122015751.87284-1-yuancan@huawei.com Reviewed-by: Ming Lei <ming.lei@redhat.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'scripts/gdb/linux/utils.py')
0 files changed, 0 insertions, 0 deletions