1
0

[DCCP] ccid3: Fixup some type conversions related to rtts

Spotted by David Miller when compiling on sparc64, I reproduced it here on
parisc64, that are the only platforms to define __kernel_suseconds_t as an
'int', all the others, x86_64 and x86 included typedef it as a 'long', but from
the definition of suseconds_t it should just be an 'int' on platforms where it
is >= 32bits, it would not require all the castings from suseconds_t to (int)
when printking variables of this type, that are not needed on parisc64 and
sparc64.

Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
Este cometimento está contido em:
Arnaldo Carvalho de Melo
2006-12-10 15:39:29 -02:00
cometido por David S. Miller
ascendente 9e8efc8240
cometimento 1fba78b6cb
2 ficheiros modificados com 12 adições e 12 eliminações

Ver ficheiro

@@ -52,12 +52,12 @@
#define TFRC_T_MBI 64
/* What we think is a reasonable upper limit on RTT values */
#define CCID3_SANE_RTT_MAX (4 * USEC_PER_SEC)
#define CCID3_SANE_RTT_MAX ((suseconds_t)(4 * USEC_PER_SEC))
#define CCID3_RTT_SANITY_CHECK(rtt) do { \
if (rtt > CCID3_SANE_RTT_MAX) { \
DCCP_CRIT("RTT (%ld) too large, substituting %ld", \
rtt, CCID3_SANE_RTT_MAX); \
DCCP_CRIT("RTT (%d) too large, substituting %d", \
(int)rtt, (int)CCID3_SANE_RTT_MAX); \
rtt = CCID3_SANE_RTT_MAX; \
} } while (0)