[PATCH v4 05/13] powerpc/rtas: Facilitate high-level call sequences

Nathan Lynch nathanl at linux.ibm.com
Wed Nov 29 02:35:33 AEDT 2023

"Aneesh Kumar K.V (IBM)" <aneesh.kumar at kernel.org> writes:
> Nathan Lynch via B4 Relay <devnull+nathanl.linux.ibm.com at kernel.org>
> writes:
>> There should be no perceivable change introduced here except that
>> concurrent callers of the same RTAS function via sys_rtas() may block
>> on a mutex instead of spinning on rtas_lock. Changes to follow will
>> add rtas_function_lock()/unlock() pairs to kernel-based call
>> sequences.
> Can you add an example of the last part. I did look at to find 06 to
> find the details
> 	rtas_function_lock(RTAS_FN_IBM_ACTIVATE_FIRMWARE);
> 	do {
> 		fwrc = rtas_call(token, 0, 1, NULL);
> 	} while (rtas_busy_delay(fwrc));
> 	rtas_function_unlock(RTAS_FN_IBM_ACTIVATE_FIRMWARE);

Sure, I'll add a simple example of the API usage in the commit message,

More information about the Linuxppc-dev mailing list