All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] extcon: trivial: kfree missed from remove path
@ 2012-10-21  4:58 anish kumar
  2012-10-22  1:12 ` Chanwoo Choi
  0 siblings, 1 reply; 2+ messages in thread
From: anish kumar @ 2012-10-21  4:58 UTC (permalink / raw)
  To: gregkh, myungjoo.ham, cw00.choi; +Cc: linux-kernel, anish kumar

From: anish kumar <anish198519851985@gmail.com>

Extcon core doesn't free the memory when we do unregister.
Kfree is added in the remove path as it was missing.

Signed-off-by: anish kumar <anish198519851985@gmail.com>
---
 drivers/extcon/extcon-max77693.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/extcon/extcon-max77693.c b/drivers/extcon/extcon-max77693.c
index e21387e..67bc9ab 100644
--- a/drivers/extcon/extcon-max77693.c
+++ b/drivers/extcon/extcon-max77693.c
@@ -762,6 +762,7 @@ static int __devexit max77693_muic_remove(struct platform_device *pdev)
 		free_irq(muic_irqs[i].virq, info);
 	cancel_work_sync(&info->irq_work);
 	extcon_dev_unregister(info->edev);
+	kfree(info->edev);
 	kfree(info);
 
 	return 0;
-- 
1.7.1


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

end of thread, other threads:[~2012-10-22  1:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-21  4:58 [PATCH] extcon: trivial: kfree missed from remove path anish kumar
2012-10-22  1:12 ` Chanwoo Choi

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.