Re: [RFC][PATCH] NTP shift_right cleanup (v. A1)

From: john stultz
Date: Wed Sep 14 2005 - 12:56:00 EST


On Wed, 2005-09-14 at 10:48 -0700, john stultz wrote:
> +/* Required to safely shift negative values */
> +#define shift_right(x, s) ({ \
> + __typeof__(x) __x = x; \
> + __typeof__(s) __s = s; \
> + (__x < 0) ? (-((-__x) >> (__s))) : ((__x) >> (__s)); \
> +})
> +

Ah, crud. Scratch that. I forgot to check in the paren change suggested
by Roman. A new patch will follow shortly.

thanks
-john


-
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/