On 06.12.2024 05:41, Denis Mukhin via B4 Relay wrote:
> From: Denis Mukhin <dmuk...@ford.com>
> 
> The code now inspects d->is_console flag to decide whether the console focus
> should move to the domain w/ console after administrator presses <Ctrl+aaa>.
> 
> Console owner domain switch logic updated accordingly.
> 
> Signed-off-by: Denis Mukhin <dmuk...@ford.com>

Just as a remark, as it's a pre-existing problem: I'm unconvinced that
"is_console" is a good name here.

> @@ -509,14 +509,20 @@ static void console_find_owner(void)
>              domid = get_initial_domain_id();
>          else
>              domid = next_rx - 1;
> +
>          d = rcu_lock_domain_by_id(domid);
> -        if ( d )
> +        if ( d == NULL )

Seeing the original code, the more "natural" transformation would be to
!d (as we use elsewhere as well, to keep code short).

Jan

Reply via email to