mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-16 18:26:42 +00:00
- Fix memory leak when freeing dm zoned target device
- Update dm-devel mailing list address in MAINTAINERS -----BEGIN PGP SIGNATURE----- iQEzBAABCAAdFiEEJfWUX4UqZ4x1O2wixSPxCi2dA1oFAmUglFMACgkQxSPxCi2d A1rOswf/T5nqpzFrbrzYj80DpRIQZj+nvTvPTId8X2kWQZ6uJqOpXSA1QP8DHeQj ycn88TEK8sbXn+wvXXWoPuMrh6FVJoZASvdlhq5QhnwpCT0riwRrnh7XQIrl3Ktn EQNmAoiKPMF/pZe653BalW/SnRJEa6603RhjHFBuGLKVS7i38oWrmbfcVEdQ+/nf Pq7gIWoFHtL9LgvhfCLHDg/EYO+brNTJtCnqt5t67iILkK6A//BO9y3O6f2QIj8C 9Y5wGduZyaZ0uOj+LuU3sEqMfr8S6q+0vbJn4yQPDhSM0msLfB20hnYN1Nl2TGIx B0k3YBScNq6u+pmPjKZMcnRXJnKPaA== =p6BS -----END PGP SIGNATURE----- Merge tag 'for-6.6/dm-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm Pull device mapper fixes from Mike Snitzer: - Fix memory leak when freeing dm zoned target device - Update dm-devel mailing list address in MAINTAINERS * tag 'for-6.6/dm-fixes-2' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm: MAINTAINERS: update the dm-devel mailing list dm zoned: free dmz->ddev array in dmz_put_zoned_devices
This commit is contained in:
commit
4aef108a4d
@ -5984,8 +5984,8 @@ F: include/linux/devm-helpers.h
|
||||
DEVICE-MAPPER (LVM)
|
||||
M: Alasdair Kergon <agk@redhat.com>
|
||||
M: Mike Snitzer <snitzer@kernel.org>
|
||||
M: dm-devel@redhat.com
|
||||
L: dm-devel@redhat.com
|
||||
M: dm-devel@lists.linux.dev
|
||||
L: dm-devel@lists.linux.dev
|
||||
S: Maintained
|
||||
W: http://sources.redhat.com/dm
|
||||
Q: http://patchwork.kernel.org/project/dm-devel/list/
|
||||
|
@ -748,17 +748,16 @@ err:
|
||||
/*
|
||||
* Cleanup zoned device information.
|
||||
*/
|
||||
static void dmz_put_zoned_device(struct dm_target *ti)
|
||||
static void dmz_put_zoned_devices(struct dm_target *ti)
|
||||
{
|
||||
struct dmz_target *dmz = ti->private;
|
||||
int i;
|
||||
|
||||
for (i = 0; i < dmz->nr_ddevs; i++) {
|
||||
if (dmz->ddev[i]) {
|
||||
for (i = 0; i < dmz->nr_ddevs; i++)
|
||||
if (dmz->ddev[i])
|
||||
dm_put_device(ti, dmz->ddev[i]);
|
||||
dmz->ddev[i] = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
kfree(dmz->ddev);
|
||||
}
|
||||
|
||||
static int dmz_fixup_devices(struct dm_target *ti)
|
||||
@ -948,7 +947,7 @@ err_bio:
|
||||
err_meta:
|
||||
dmz_dtr_metadata(dmz->metadata);
|
||||
err_dev:
|
||||
dmz_put_zoned_device(ti);
|
||||
dmz_put_zoned_devices(ti);
|
||||
err:
|
||||
kfree(dmz->dev);
|
||||
kfree(dmz);
|
||||
@ -978,7 +977,7 @@ static void dmz_dtr(struct dm_target *ti)
|
||||
|
||||
bioset_exit(&dmz->bio_set);
|
||||
|
||||
dmz_put_zoned_device(ti);
|
||||
dmz_put_zoned_devices(ti);
|
||||
|
||||
mutex_destroy(&dmz->chunk_lock);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user