do_cksum(uint8_t *dp, uint8_t *de)

{

    unsigned int bsum[2] = {0, 0}, i, sum;



    for (i = 1; dp < de; bsum[i^=1] += *dp++)

        ;

    sum = (bsum[0] << 8) + bsum[1];

    sum = (sum >> 16) + (sum & 0xffff);

    return ~(sum + (sum >> 16));

}

do_cksum(uint8_t *dp, uint8_t *de)

{

    unsigned int bsum[2] = {0, 0}, i, sum;



    for (i = 1; dp < de; bsum[i^=1] += *dp++)

        ;

    sum = (bsum[0] << 8) + bsum[1];

    sum = (sum >> 16) + (sum & 0xffff);

    return ~(sum + (sum >> 16));

}

FUNC_0(uint8_t *VAR_0, uint8_t *VAR_1)

{

    unsigned int VAR_2[2] = {0, 0}, VAR_3, VAR_4;



    for (VAR_3 = 1; VAR_0 < VAR_1; VAR_2[VAR_3^=1] += *VAR_0++)

        ;

    VAR_4 = (VAR_2[0] << 8) + VAR_2[1];

    VAR_4 = (VAR_4 >> 16) + (VAR_4 & 0xffff);

    return ~(VAR_4 + (VAR_4 >> 16));

}

FUNC_0(uint8_t *VAR_0, uint8_t *VAR_1)
{ unsigned int VAR_2[2] = {0, 0}, VAR_3, VAR_4; for (VAR_3 = 1; VAR_0 < VAR_1; VAR_2[VAR_3^=1] += *VAR_0++) ; VAR_4 = (VAR_2[0] << 8) + VAR_2[1]; VAR_4 = (VAR_4 >> 16) + (VAR_4 & 0xffff); return ~(VAR_4 + (VAR_4 >> 16)); }