Re: IS_ERR Threshold Value

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 2 Jul 2006 17:15:20 +0100 Ralf Baechle wrote:

> So MAX_ERRNO of EMAXERRNO which was also being used in assembler code.
> Other architectures may have the same issue, so I propose wrapping the
> C parts with #ifndef __ASSEMBLY__ to keep as happy.

Ack, fixes 'as' whinging for me.


> Signed-off-by: Ralf Baechle <[email protected]>
> 
> diff --git a/include/linux/err.h b/include/linux/err.h
> index cd3b367..1ab1d44 100644
> --- a/include/linux/err.h
> +++ b/include/linux/err.h
> @@ -15,6 +15,8 @@ #include <asm/errno.h>
>   */
>  #define MAX_ERRNO	4095
>  
> +#ifndef __ASSEMBLY__
> +
>  #define IS_ERR_VALUE(x) unlikely((x) >= (unsigned long)-MAX_ERRNO)
>  
>  static inline void *ERR_PTR(long error)
> @@ -32,4 +34,6 @@ static inline long IS_ERR(const void *pt
>  	return IS_ERR_VALUE((unsigned long)ptr);
>  }
>  
> +#endif
> +
>  #endif /* _LINUX_ERR_H */
> -


---
~Randy
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux