Allow the ERR_CAST() function in the LinuxKPI to take a const void pointer.
No functional change. MFC after: 1 week Sponsored by: Mellanox Technologies
This commit is contained in:
parent
0fbdc3726a
commit
47c0672b08
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=360115
@ -31,6 +31,8 @@
|
|||||||
#ifndef _LINUX_ERR_H_
|
#ifndef _LINUX_ERR_H_
|
||||||
#define _LINUX_ERR_H_
|
#define _LINUX_ERR_H_
|
||||||
|
|
||||||
|
#include <sys/types.h>
|
||||||
|
|
||||||
#include <linux/compiler.h>
|
#include <linux/compiler.h>
|
||||||
|
|
||||||
#define MAX_ERRNO 4095
|
#define MAX_ERRNO 4095
|
||||||
@ -62,9 +64,9 @@ IS_ERR_OR_NULL(const void *ptr)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static inline void *
|
static inline void *
|
||||||
ERR_CAST(void *ptr)
|
ERR_CAST(const void *ptr)
|
||||||
{
|
{
|
||||||
return (void *)ptr;
|
return __DECONST(void *, ptr);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline int
|
static inline int
|
||||||
|
Loading…
Reference in New Issue
Block a user