[Skiboot] [PATCH v3 03/10] opal-msg: Pass parameter size to _opal_queue_msg()

Vasant Hegde hegdevasant at linux.vnet.ibm.com
Fri May 17 02:52:15 AEST 2019


On 05/16/2019 11:57 AM, Jeremy Kerr wrote:
> Hi Vasant,
> 
>> Currently _opal_queue_msg() takes number of parameters. So far this
>> was
>> fine as opal_queue_msg() was supporting only fixed number of
>> parameters
>> (8 * 8 bytes). Soon we are going to introduce variable size parameter.
>> Hence num_params -> params_size.
> 
> Looks good to me.
> 
> Acked-by Jeremy Kerr <jk at ozlabs.org>

Thanks!

> 
> ... with just one suggestion, if you end up re-rolling for other
> reasons:
> 
>> --- a/core/hmi.c
>> +++ b/core/hmi.c
>> @@ -331,13 +331,13 @@ static int queue_hmi_event(struct OpalHMIEvent *hmi_evt, int recover, uint64_t *
>>   	 * num_params divide the struct size by 8 bytes to get exact
>>   	 * num_params value.
>>   	 */
>> -	num_params = ALIGN_UP(sizeof(*hmi_evt), sizeof(u64)) / sizeof(u64);
>> +	num_params = ALIGN_UP(sizeof(*hmi_evt), sizeof(u64));
> 
> Maybe rename this to `size`, as it's no longer the number of parameters.

Makes sense. Will fix ti in v4.

-Vasant



More information about the Skiboot mailing list