[PATCH 5/8] powerpc/rtas: rename va_rtas_call_unlocked() to va_rtas_call()

Michael Ellerman mpe at ellerman.id.au
Wed Mar 29 23:24:27 AEDT 2023


Nathan Lynch via B4 Relay <devnull+nathanl.linux.ibm.com at kernel.org>
writes:
> From: Nathan Lynch <nathanl at linux.ibm.com>
>
> The function name va_rtas_call_unlocked() is confusing: it may be
> called with or without rtas_lock held. Rename it to va_rtas_call().

I'm not sure about this one.

The "unlocked" is meant to convey that it doesn't do any locking. The
caller has to be OK with that, or do its own locking.

Andrew is right that the common naming pattern is foo() that takes the
lock and __foo() that doesn't - but I agree that's not very pretty.

Can we just leave it as-is?

cheers


More information about the Linuxppc-dev mailing list