public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
* Re: [PATCH 03/15] drivers: devfreq: Drop unlikely before IS_ERR(_OR_NULL)
@ 2015-08-03  5:10 MyungJoo Ham
  2015-08-03  5:47 ` Viresh Kumar
  0 siblings, 1 reply; 3+ messages in thread
From: MyungJoo Ham @ 2015-08-03  5:10 UTC (permalink / raw)
  To: Viresh Kumar, akpm@linux-foundation.org
  Cc: linaro-kernel@lists.linaro.org, linux-kernel@vger.kernel.org,
	박경민, open list:DEVICE FREQUENCY (DEVFREQ)

> IS_ERR(_OR_NULL) already contain an 'unlikely' compiler flag and there
> is no need to do that again from its callers. Drop it.
> 
> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>

@ from include/linux/err.h
#define IS_ERR_VALUE(x) unlikely((x) >= (unsigned long)-MAX_ERRNO)
...
static inline bool __must_check IS_ERR_OR_NULL(__force const void *ptr)
{
	return !ptr || IS_ERR_VALUE((unsigned long)ptr);
}

"!ptr" appears not covered with IS_ERR_OR_NULL.
(only the IS_ERR part seems covered)


Cheers,
MyungJoo


^ permalink raw reply	[flat|nested] 3+ messages in thread
[parent not found: <cover.1438331416.git.viresh.kumar@linaro.org>]

end of thread, other threads:[~2015-08-03  5:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-03  5:10 [PATCH 03/15] drivers: devfreq: Drop unlikely before IS_ERR(_OR_NULL) MyungJoo Ham
2015-08-03  5:47 ` Viresh Kumar
     [not found] <cover.1438331416.git.viresh.kumar@linaro.org>
2015-07-31  8:38 ` Viresh Kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox