mirror of
https://github.com/fail0verflow/switch-linux.git
synced 2025-05-04 02:34:21 -04:00
regmap: Clean up hwspinlock on regmap exit
We should free any hwspinlocks when we destroy the regmap, do so. Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
267f3e4f18
commit
e8419c40a5
1 changed files with 2 additions and 0 deletions
|
@ -1305,6 +1305,8 @@ void regmap_exit(struct regmap *map)
|
||||||
kfree(async->work_buf);
|
kfree(async->work_buf);
|
||||||
kfree(async);
|
kfree(async);
|
||||||
}
|
}
|
||||||
|
if (IS_ENABLED(REGMAP_HWSPINLOCK) && map->hwlock)
|
||||||
|
hwspin_lock_free(map->hwlock);
|
||||||
kfree(map);
|
kfree(map);
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL_GPL(regmap_exit);
|
EXPORT_SYMBOL_GPL(regmap_exit);
|
||||||
|
|
Loading…
Add table
Reference in a new issue