We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0583bc7 commit 791cd7aCopy full SHA for 791cd7a
drivers/usb/dwc3/dwc3-rtk.c
@@ -183,10 +183,13 @@ static enum usb_device_speed __get_dwc3_maximum_speed(struct device_node *np)
183
184
ret = of_property_read_string(dwc3_np, "maximum-speed", &maximum_speed);
185
if (ret < 0)
186
- return USB_SPEED_UNKNOWN;
+ goto out;
187
188
ret = match_string(speed_names, ARRAY_SIZE(speed_names), maximum_speed);
189
190
+out:
191
+ of_node_put(dwc3_np);
192
+
193
return (ret < 0) ? USB_SPEED_UNKNOWN : ret;
194
}
195
@@ -339,6 +342,9 @@ static int dwc3_rtk_probe_dwc3_core(struct dwc3_rtk *rtk)
339
342
340
343
switch_usb2_role(rtk, rtk->cur_role);
341
344
345
+ platform_device_put(dwc3_pdev);
346
+ of_node_put(dwc3_node);
347
348
return 0;
349
350
err_pdev_put:
0 commit comments