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

Commit 4c4f106c authored by Wei Yongjun's avatar Wei Yongjun Committed by Felipe Balbi
Browse files

usb: dwc3: fix missing platform_set_drvdata() in dwc3_of_simple_probe()



Add missing platform_set_drvdata() in dwc3_of_simple_probe(), otherwise
calling platform_get_drvdata() in remove returns NULL.

This is detected by Coccinelle semantic patch.

Signed-off-by: default avatarWei Yongjun <weiyj.lk@gmail.com>
Signed-off-by: default avatarFelipe Balbi <felipe.balbi@linux.intel.com>
parent ec57fcd0
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -61,6 +61,7 @@ static int dwc3_of_simple_probe(struct platform_device *pdev)
	if (!simple->clks)
		return -ENOMEM;

	platform_set_drvdata(pdev, simple);
	simple->dev = dev;

	for (i = 0; i < simple->num_clocks; i++) {