Re: [PATCH] i386, nmi: signed vs unsigned mixup

From: Jesper Juhl
Date: Sat Nov 19 2005 - 20:15:34 EST


On 11/20/05, Andrew Morton <akpm@xxxxxxxx> wrote:
> Jesper Juhl <jesper.juhl@xxxxxxxxx> wrote:
> >
> > > -ETOOTRIVIAL. The code as-is works OK, and we have these sorts of things
> > > all over the tee.
> > >
> > Fair enough.
> >
> > Would a patch to clean this sort of stuff up in bulk all over be of
> > interrest or should I just leave it alone?
>
> Such a patchset would be pretty intrusive and it's not exactly trivial - at
> each site we need to decide whether we should be using signed or unsigned,
> then change one or the other, then do a full-scope check to see what the
> implications of that change are.
>
> I think the two risks of signedness sloppiness are a) inadvertent or
> premature overflow and b) comparisons, where the signed quantity went
> negative.
>
> Problem b) is more serious, and `gcc -Wsigned-compare' may be used to
> identify possible problems. There are quite a lot of places need checking,
> iirc.
>
Ok, so does that mean that, if properly verified, patches for things
that "gcc -Wsigned-compare" flags will be appreciated?
I'll just restrict myself to that in that case.

--
Jesper Juhl <jesper.juhl@xxxxxxxxx>
Don't top-post http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please http://www.expita.com/nomime.html
-
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/