[PATCH] ufs: Use str_enable_disable-like helpers
Bart Van Assche
bvanassche at acm.org
Wed Jan 15 09:53:33 PST 2025
On 1/14/25 12:07 PM, Krzysztof Kozlowski wrote:
> 2. Is slightly shorter thus also easier to read.
Does this change really make code easier to read? It forces readers
of the code to look up a function definition. Isn't there a general
preference in the Linux kernel to inline function definitions if the
function body is shorter than or close to the length of the function
name? I'm referring to functions like this one:
static inline const char *str_up_down(bool v)
{
return v ? "up" : "down";
}
Bart.
More information about the Linux-mediatek
mailing list