summaryrefslogtreecommitdiff
path: root/drivers/staging/lustre/include
diff options
context:
space:
mode:
authorViresh Kumar <viresh.kumar@linaro.org>2015-07-31 14:08:30 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-07-31 16:18:43 -0700
commit7f44cb0ba88b40c09c5bdfc46186e09f42b1a9b0 (patch)
treea4e0177377ccf9baf3c888e99bb8f71e8ed98e5e /drivers/staging/lustre/include
parentb3c1a61744d02ca2c249dae04c8eb8f5b0822bc3 (diff)
drivers: staging: Drop unlikely before IS_ERR(_OR_NULL)
IS_ERR(_OR_NULL) already contain an 'unlikely' compiler flag and there is no need to do that again from its callers. Drop it. This also replaces an IS_ERR(x) + (x == NULL) check to IS_ERR_OR_NULL check. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/lustre/include')
-rw-r--r--drivers/staging/lustre/include/linux/libcfs/libcfs.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/lustre/include/linux/libcfs/libcfs.h b/drivers/staging/lustre/include/linux/libcfs/libcfs.h
index 5dd9cdfae30c..d585041041c7 100644
--- a/drivers/staging/lustre/include/linux/libcfs/libcfs.h
+++ b/drivers/staging/lustre/include/linux/libcfs/libcfs.h
@@ -134,7 +134,7 @@ void cfs_get_random_bytes(void *buf, int size);
/* container_of depends on "likely" which is defined in libcfs_private.h */
static inline void *__container_of(void *ptr, unsigned long shift)
{
- if (unlikely(IS_ERR(ptr) || ptr == NULL))
+ if (IS_ERR_OR_NULL(ptr))
return ptr;
return (char *)ptr - shift;
}