Re: [PATCH net-next v2] af_unix: Fix undefined 'other' error
From: Joe Damato
Date: Mon Feb 10 2025 - 12:51:40 EST
On Mon, Feb 10, 2025 at 01:20:06PM +0530, Purva Yeshi wrote:
> Fix issue detected by smatch tool:
> An "undefined 'other'" error occur in __releases() annotation.
>
> Fix an undefined 'other' error in unix_wait_for_peer() caused by
> __releases(&unix_sk(other)->lock) being placed before 'other' is in
> scope. Since AF_UNIX does not use Sparse annotations, remove it to fix
> the issue.
>
> Eliminate the error without affecting functionality.
>
> Signed-off-by: Purva Yeshi <purvayeshi550@xxxxxxxxx>
> ---
> V1 - https://lore.kernel.org/lkml/20250209184355.16257-1-purvayeshi550@xxxxxxxxx/
> V2 - Remove __releases() annotation as AF_UNIX does not use Sparse annotations.
> net/unix/af_unix.c | 1 -
> 1 file changed, 1 deletion(-)
>
Reviewed-by: Joe Damato <jdamato@xxxxxxxxxx>