[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150804021949.GA15655@linux>
Date: Tue, 4 Aug 2015 07:49:49 +0530
From: Viresh Kumar <viresh.kumar@...aro.org>
To: Steven Rostedt <rostedt@...dmis.org>
Cc: "Kirill A. Shutemov" <kirill@...temov.name>,
Vlastimil Babka <vbabka@...e.cz>, akpm@...ux-foundation.org,
linaro-kernel@...ts.linaro.org, linux-kernel@...r.kernel.org,
Hans Ulli Kroll <ulli.kroll@...glemail.com>,
Alexandre Belloni <alexandre.belloni@...e-electrons.com>,
Oleg Drokin <oleg.drokin@...el.com>,
Andreas Dilger <andreas.dilger@...el.com>
Subject: Re: [PATCH 00/15] trivial: Drop unlikely before IS_ERR(_OR_NULL)
On 03-08-15, 17:38, Steven Rostedt wrote:
> On Fri, 31 Jul 2015 13:23:10 +0300
> "Kirill A. Shutemov" <kirill@...temov.name> wrote:
> > We have two cases in code:
> >
> > drivers/rtc/rtc-gemini.c: if (likely(IS_ERR(rtc->rtc_dev)))
> > drivers/staging/lustre/lustre/obdclass/lu_object.c: if (likely(IS_ERR(shadow) && PTR_ERR(shadow) == -ENOENT)) {
> >
> > The first one is mistake, I think. Or do we expect rtc_device_register()
> > to fail?
> >
> > The second is redundant. "if (PTR_ERR(shadow) == -ENOENT)" should do the
> > job.
> >
>
> Yep, those look like bugs to me.
Yeah, I have fixed both of them :)
--
viresh
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists