[PATCH] cobalt/synch: uapi: silence pedantic warning (signed/unsigned)

Jan Kiszka jan.kiszka at siemens.com
Fri Dec 11 07:44:38 CET 2020


On 04.12.20 16:07, Philippe Gerum wrote:
> From: Philippe Gerum <rpm at xenomai.org>
> 
> Signed-off-by: Philippe Gerum <rpm at xenomai.org>
> ---
>  include/cobalt/uapi/kernel/synch.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/cobalt/uapi/kernel/synch.h b/include/cobalt/uapi/kernel/synch.h
> index 33d7ab3c7..a21eb965e 100644
> --- a/include/cobalt/uapi/kernel/synch.h
> +++ b/include/cobalt/uapi/kernel/synch.h
> @@ -71,7 +71,7 @@ int xnsynch_fast_acquire(atomic_t *fastlock, xnhandle_t new_ownerh)
>  static inline
>  int xnsynch_fast_release(atomic_t *fastlock, xnhandle_t cur_ownerh)
>  {
> -	return atomic_cmpxchg(fastlock, cur_ownerh, XN_NO_HANDLE)
> +	return (xnhandle_t)atomic_cmpxchg(fastlock, cur_ownerh, XN_NO_HANDLE)
>  		== cur_ownerh;
>  }
>  
> 

Thanks, applied.

Jan

-- 
Siemens AG, T RDA IOT
Corporate Competence Center Embedded Linux



More information about the Xenomai mailing list