[Skiboot] [PATCH 1/7 v3] external/opal-prd: Allow instance numbers for PRD ranges

Jeremy Kerr jk at ozlabs.org
Mon Aug 17 17:36:26 AEST 2015

Hi Stewart,

>> diff --git a/external/opal-prd/hostboot-interface.h b/external/opal-prd/hostboot-interface.h
>> index a518f50..3c162aa 100644
>> --- a/external/opal-prd/hostboot-interface.h
>> +++ b/external/opal-prd/hostboot-interface.h
>> @@ -117,10 +117,11 @@ struct host_interfaces {
>>   	 *  name.
>>   	 *
>>   	 *  @param[in] Devtree name (ex. "ibm,hbrt-vpd-image")
>> +	 *  @param[in] Devtree instance
>>   	 *  @return physical address of region (or NULL).
>>   	 *  @platform FSP,OpenPOWER
>>   	 */
>> -	uint64_t (*get_reserved_mem)(const char*);
>> +	uint64_t (*get_reserved_mem)(const char *name, uint32_t instance);
>>   	/**
>>   	 * @brief  Force a core to be awake, or clear the force
> Not exactly sure how adding a parameter like this without bumping the
> hostboot interface version ends up being compatible... but hey, at least
> it's the same as the HB side.

I've proposed a version bump to the HBRT folks, but they'd prefer to 
keep it as-is.

We'll never use the instance value on a single-socket machine, and 
multiple-socket PRD doesn't currently work (without this patch).

So, any time we refer to this instance value (ie, we have multiple 
ranges), we should be being called by a HBRT that is specifying this 
argument in r4 (ie, has support for multiple ranges).

We will see odd instance values in the logs, if we have an old HBRT 
calling this new interface, but that's fairly harmless.

I can send a patch to minimise the logging that uses that passed value, 
if you like.



More information about the Skiboot mailing list