mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-08-05 16:54:27 +00:00
intel-iommu: double kfree()
g_iommus is freed after we "goto error;". Found by smatch (http://repo.or.cz/w/smatch.git). Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
This commit is contained in:
parent
0db9b7aebb
commit
86f4d0123b
1 changed files with 0 additions and 1 deletions
|
@ -2224,7 +2224,6 @@ int __init init_dmars(void)
|
||||||
deferred_flush = kzalloc(g_num_of_iommus *
|
deferred_flush = kzalloc(g_num_of_iommus *
|
||||||
sizeof(struct deferred_flush_tables), GFP_KERNEL);
|
sizeof(struct deferred_flush_tables), GFP_KERNEL);
|
||||||
if (!deferred_flush) {
|
if (!deferred_flush) {
|
||||||
kfree(g_iommus);
|
|
||||||
ret = -ENOMEM;
|
ret = -ENOMEM;
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue