]> git.baikalelectronics.ru Git - kernel.git/commit
swiotlb-xen: avoid double free
authorJan Beulich <jbeulich@suse.com>
Tue, 7 Sep 2021 12:04:25 +0000 (14:04 +0200)
committerJuergen Gross <jgross@suse.com>
Wed, 15 Sep 2021 06:42:04 +0000 (08:42 +0200)
commit1cd838ac72386ff288ed965c904cc640325b6549
treea021d2ff413df93a31f6296dcdefaa0f05dfb506
parent051dea296f572e4c2c9588ba6c83920d8789efe8
swiotlb-xen: avoid double free

Of the two paths leading to the "error" label in xen_swiotlb_init() one
didn't allocate anything, while the other did already free what was
allocated.

Fixes: 51afb8af9803 ("xen/swiotlb: Use the swiotlb_late_init_with_tbl to init Xen-SWIOTLB late when PV PCI is used")
Signed-off-by: Jan Beulich <jbeulich@suse.com>
Cc: stable@vger.kernel.org
Reviewed-by: Christoph Hellwig <hch@lst.de>
Link: https://lore.kernel.org/r/ce9c2adb-8a52-6293-982a-0d6ece943ac6@suse.com
Signed-off-by: Juergen Gross <jgross@suse.com>
drivers/xen/swiotlb-xen.c