mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* efi/esrt: use memunmap rather kfree to free the remapping
@ 2017-10-29 14:51 Pan Bian
  2017-12-05 18:08 ` Ard Biesheuvel
  0 siblings, 1 reply; 2+ messages in thread
From: Pan Bian @ 2017-10-29 14:51 UTC (permalink / raw)
  To: Matt Fleming, Ard Biesheuvel; +Cc: linux-efi, linux-kernel, Pan Bian

The remapping result of memremap should be freed with memunmap, not
kfree.

Signed-off-by: Pan Bian <bianpan2016@163.com>
---
 drivers/firmware/efi/esrt.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/firmware/efi/esrt.c b/drivers/firmware/efi/esrt.c
index bd7ed3c..3ef7001 100644
--- a/drivers/firmware/efi/esrt.c
+++ b/drivers/firmware/efi/esrt.c
@@ -431,7 +431,7 @@ static int __init esrt_sysfs_init(void)
 err_remove_esrt:
 	kobject_put(esrt_kobj);
 err:
-	kfree(esrt);
+	memunmap(esrt);
 	esrt = NULL;
 	return error;
 }
-- 
1.9.1

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-12-05 18:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-29 14:51 efi/esrt: use memunmap rather kfree to free the remapping Pan Bian
2017-12-05 18:08 ` Ard Biesheuvel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®