Re: [PATCH resend4 3/3] itimers: simplify arm_timer() code a bit

From: Thomas Gleixner
Date: Fri May 22 2009 - 13:00:26 EST


On Fri, 22 May 2009, Stanislaw Gruszka wrote:
> On Fri, 22 May 2009 16:30:09 +0200 (CEST)
> Thomas Gleixner <tglx@xxxxxxxxxxxxx> wrote:
>
> > On Fri, 22 May 2009, Stanislaw Gruszka wrote:
> > > case CPUCLOCK_PROF:
> > > - if (cputime_eq(p->cputime_expires.prof_exp,
> > > - cputime_zero) ||
> > > - cputime_gt(p->cputime_expires.prof_exp,
> > > - nt->expires.cpu))
> > > - p->cputime_expires.prof_exp =
> > > - nt->expires.cpu;
> > > + if (expires_le(p->cputime_expires.prof_exp,
> > > + exp->cpu))
> > > + break;
> >
> > Why the reverse logic and the extra break ?
>
> Just to use helper and to make similar logic in all cases in this funcion.

Well, you can do that the other way round as well :)

Thanks,

tglx
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/