forked from Mirrors/opensbi
		
	platform: generic: check if CPU node is enabled
Ignore CPU nodes in FDT which are not enabled. Signed-off-by: Jan Remes <jan.remes@codasip.com> Reviewed-by: Xiang W <wxjstz@126.com> Reviewed-by: Anup Patel <anup@brainfault.org>
This commit is contained in:
		@@ -103,6 +103,9 @@ unsigned long fw_platform_init(unsigned long arg0, unsigned long arg1,
 | 
			
		||||
		if (SBI_HARTMASK_MAX_BITS <= hartid)
 | 
			
		||||
			continue;
 | 
			
		||||
 | 
			
		||||
		if (!fdt_node_is_enabled(fdt, cpu_offset))
 | 
			
		||||
			continue;
 | 
			
		||||
 | 
			
		||||
		generic_hart_index2id[hart_count++] = hartid;
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user