Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9680b60e authored by Torsten Fleischer's avatar Torsten Fleischer Committed by Greg Kroah-Hartman
Browse files

usb: chipidea: Fix oops when removing the ci_hdrc module



The call of 'kfree(ci->hw_bank.regmap)' in ci_hdrc_remove() sometimes causes
a kernel oops when removing the ci_hdrc module.

Since there is no separate memory allocated for the ci->hw_bank.regmap array,
there is no need to free it.

Cc: v3.14+ <stable@@vger.kernel.org>
Signed-off-by: default avatarTorsten Fleischer <to-fleischer@t-online.de>
Signed-off-by: default avatarPeter Chen <peter.chen@freescale.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 8071e6f8
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -742,7 +742,6 @@ static int ci_hdrc_remove(struct platform_device *pdev)
	ci_role_destroy(ci);
	ci_hdrc_enter_lpm(ci, true);
	usb_phy_shutdown(ci->transceiver);
	kfree(ci->hw_bank.regmap);

	return 0;
}