aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/mm/mmio-mod.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/mm/mmio-mod.c')
-rw-r--r--arch/x86/mm/mmio-mod.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/x86/mm/mmio-mod.c b/arch/x86/mm/mmio-mod.c
index 635b50e85581..754bd1eaf4f6 100644
--- a/arch/x86/mm/mmio-mod.c
+++ b/arch/x86/mm/mmio-mod.c
@@ -307,8 +307,10 @@ static void ioremap_trace_core(resource_size_t offset, unsigned long size,
307 map.map_id = trace->id; 307 map.map_id = trace->id;
308 308
309 spin_lock_irq(&trace_lock); 309 spin_lock_irq(&trace_lock);
310 if (!is_enabled()) 310 if (!is_enabled()) {
311 kfree(trace);
311 goto not_enabled; 312 goto not_enabled;
313 }
312 314
313 mmio_trace_mapping(&map); 315 mmio_trace_mapping(&map);
314 list_add_tail(&trace->list, &trace_list); 316 list_add_tail(&trace->list, &trace_list);