File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change @@ -372,12 +372,11 @@ static bool mtk_drm_get_all_drm_priv(struct device *dev)
372
372
struct mtk_drm_private * temp_drm_priv ;
373
373
struct device_node * phandle = dev -> parent -> of_node ;
374
374
const struct of_device_id * of_id ;
375
- struct device_node * node ;
376
375
struct device * drm_dev ;
377
376
unsigned int cnt = 0 ;
378
377
int i , j ;
379
378
380
- for_each_child_of_node (phandle -> parent , node ) {
379
+ for_each_child_of_node_scoped (phandle -> parent , node ) {
381
380
struct platform_device * pdev ;
382
381
383
382
of_id = of_match_node (mtk_drm_of_ids , node );
@@ -406,10 +405,8 @@ static bool mtk_drm_get_all_drm_priv(struct device *dev)
406
405
if (temp_drm_priv -> mtk_drm_bound )
407
406
cnt ++ ;
408
407
409
- if (cnt == MAX_CRTC ) {
410
- of_node_put (node );
408
+ if (cnt == MAX_CRTC )
411
409
break ;
412
- }
413
410
}
414
411
415
412
if (drm_priv -> data -> mmsys_dev_num == cnt ) {
You can’t perform that action at this time.
0 commit comments