File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -548,15 +548,16 @@ int of_platform_device_destroy(struct device *dev, void *data)
548
548
if (of_node_check_flag (dev -> of_node , OF_POPULATED_BUS ))
549
549
device_for_each_child (dev , NULL , of_platform_device_destroy );
550
550
551
+ of_node_clear_flag (dev -> of_node , OF_POPULATED );
552
+ of_node_clear_flag (dev -> of_node , OF_POPULATED_BUS );
553
+
551
554
if (dev -> bus == & platform_bus_type )
552
555
platform_device_unregister (to_platform_device (dev ));
553
556
#ifdef CONFIG_ARM_AMBA
554
557
else if (dev -> bus == & amba_bustype )
555
558
amba_device_unregister (to_amba_device (dev ));
556
559
#endif
557
560
558
- of_node_clear_flag (dev -> of_node , OF_POPULATED );
559
- of_node_clear_flag (dev -> of_node , OF_POPULATED_BUS );
560
561
return 0 ;
561
562
}
562
563
EXPORT_SYMBOL_GPL (of_platform_device_destroy );
You can’t perform that action at this time.
0 commit comments