[Skiboot] [PATCH] core/opal: Fix address-cells in opal node in DT

Maxim Polyakov m.polyakov at yadro.com
Mon Apr 15 22:21:24 AEST 2019



09.04.2019 19:36, Vasant Hegde пишет:
> On 03/27/2019 06:03 PM, Maxim Polyakov wrote:
>> This patch fix this FWTS warning:
>>
>> Warning (reg_format): "reg" property in /ibm,opal/flash at 0 has
>> invalid length (8 bytes) (#address-cells == 0, #size-cells == 0)
>>
>> See more in https://github.com/open-power/skiboot/issues/47
>>
>> It has been tested on Vesnin P8 server.
>>
>> Signed-off-by: Maxim Polyakov <m.polyakov at yadro.com>
>> ---
>>   core/opal.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/core/opal.c b/core/opal.c
>> index 624e2a2..9271b07 100644
>> --- a/core/opal.c
>> +++ b/core/opal.c
>> @@ -406,7 +406,7 @@ void add_opal_node(void)
>>           (uint64_t)(cpu_max_pir + 1) * STACK_SIZE) - SKIBOOT_BASE;
>>
>>       opal_node = dt_new_check(dt_root, "ibm,opal");
>> -    dt_add_property_cells(opal_node, "#address-cells", 0);
>> +    dt_add_property_cells(opal_node, "#address-cells", 1);
> 
> Well, it will help to silence dtc warning. But as mentioned in github, `reg` property inside
> `flash` node has just `size` no address.  So this is not correct.
> 
> But if we add "#size-cells" = 1 then its like telling you have `size` without address.. which is also wrong.
> 
> May be we can just add this patch to keep dtc happy.

It would be great for us, because this patch will solve our problem with firmware certification.

> 
> @jk, any thoughts?

?

> 
> -Vasant
> 
>>       dt_add_property_cells(opal_node, "#size-cells", 0);
>>
>>       if (proc_gen < proc_gen_p9)
>>
> 

-- 
Regards,
Maxim Polyakov 
Software Engineer, YADRO.


More information about the Skiboot mailing list