diff options
-rw-r--r-- | include/linux/err.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/err.h b/include/linux/err.h index 221fcfb676c4..15f92e072450 100644 --- a/include/linux/err.h +++ b/include/linux/err.h | |||
@@ -52,7 +52,7 @@ static inline void * __must_check ERR_CAST(__force const void *ptr) | |||
52 | return (void *) ptr; | 52 | return (void *) ptr; |
53 | } | 53 | } |
54 | 54 | ||
55 | static inline int __must_check PTR_RET(__force const void *ptr) | 55 | static inline int __must_check PTR_ERR_OR_ZERO(__force const void *ptr) |
56 | { | 56 | { |
57 | if (IS_ERR(ptr)) | 57 | if (IS_ERR(ptr)) |
58 | return PTR_ERR(ptr); | 58 | return PTR_ERR(ptr); |
@@ -60,6 +60,9 @@ static inline int __must_check PTR_RET(__force const void *ptr) | |||
60 | return 0; | 60 | return 0; |
61 | } | 61 | } |
62 | 62 | ||
63 | /* Deprecated */ | ||
64 | #define PTR_RET(p) PTR_ERR_OR_ZERO(p) | ||
65 | |||
63 | #endif | 66 | #endif |
64 | 67 | ||
65 | #endif /* _LINUX_ERR_H */ | 68 | #endif /* _LINUX_ERR_H */ |