On Sun, Sep 25, 2016 at 09:50:04AM +0300, Leon Romanovsky wrote: > -#ifndef min > -#define min(a, b) \ > - ({ typeof(a) _a = (a); \ > - typeof(b) _b = (b); \ > - _a < _b ? _a : _b; }) > -#endif > - > -#ifndef max > -#define max(a, b) \ > - ({ typeof(a) _a = (a); \ > - typeof(b) _b = (b); \ > - _a > _b ? _a : _b; }) > -#endif I'm not excited to replace the safer min above with the less safe min below, that could actually break something. > +/* > + * This include contains all common mathematical functions > + */ > +#ifndef min > +#define min(a, b) (((a) < (b)) ? (a) : (b)) > +#endif > + > +#ifndef max > +#define max(a, b) (((a) > (b)) ? (a) : (b)) > +#endif > +#endif /* _RDMA_MATH_H_ */ Jason -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html