diff options
author | Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com> | 2019-06-17 13:36:41 +0200 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2019-06-25 15:33:21 +0100 |
commit | 6ee927f2f014668c5fe920d0fd1a6ad48671bfce (patch) | |
tree | ee1916a45d0c4019e96ff0727711344ac627307b /arch/sparc | |
parent | e79986ce50d65f490c6eab3aaea1ff2ab5df5d04 (diff) |
ASoC: Intel: Skylake: Fix NULL ptr dereference when unloading clk dev
When driver is probed, we iterate over NHLT and check if clk entries are
present. For each such entry we call register_skl_clk and keep the
result in data->clk[].
Currently data->clk is sparsely indexed using NHLT table iterator, while
when freeing we use number of registered entries. Let's just use
data->avail_clk_cnt as index, so it can be reset back in
unregister_src_clk.
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'arch/sparc')
0 files changed, 0 insertions, 0 deletions