diff options
| author | Meng Wang <mwang@codeaurora.org> | 2016-07-27 15:55:05 +0800 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2016-08-10 23:22:22 -0700 |
| commit | 115b1e7c4e7d1d58de4e96f0d64056dde6ebebb1 (patch) | |
| tree | c7f26578e83d468f034e2a68f0aed0e66daf8d21 | |
| parent | 59ff3301d529ed74f414f15b69365a0c7babb7d5 (diff) | |
ASoC: wcd9xxx: set pointer to null after kfree
In wcd core drivers, some pointers are not set as NULL
after the memory is freed, which will leave many
dangling pointers. Set them to NULL explicitly to
avoid potential risk.
CRs-Fixed: 997062
Change-Id: I5dd4a9dd8f757d0850d75575d7e522e2a22f46f3
Signed-off-by: Meng Wang <mwang@codeaurora.org>
| -rw-r--r-- | drivers/mfd/wcd9xxx-irq.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/mfd/wcd9xxx-irq.c b/drivers/mfd/wcd9xxx-irq.c index 1b93c83ae98e..0c5754341991 100644 --- a/drivers/mfd/wcd9xxx-irq.c +++ b/drivers/mfd/wcd9xxx-irq.c @@ -741,6 +741,7 @@ static int wcd9xxx_irq_remove(struct platform_device *pdev) wmb(); irq_domain_remove(data->domain); kfree(data); + domain->host_data = NULL; return 0; } |
