Re: [PATCH 2/2] dma-buf: add helpers for attacher dma-parms

From: Tomasz Stanislawski
Date: Mon Aug 06 2012 - 08:42:27 EST


On 08/06/2012 01:58 PM, Michal Nazarewicz wrote:
>
> Tomasz Stanislawski <t.stanislaws@xxxxxxxxxxx> writes:
>> I recommend to change the semantics for unlimited number of segments
>> from 'value 0' to:
>>
>> #define DMA_SEGMENTS_COUNT_UNLIMITED ((unsigned long)INT_MAX)

Sorry. It should be:
#define DMA_SEGMENTS_COUNT_UNLIMITED ((unsigned int)INT_MAX)

>>
>> Using INT_MAX will allow using safe conversions between signed and
>> unsigned integers.
>
> LONG_MAX seems cleaner regardless.
>
>
>

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