tree e7507e0367df7f95eaeefc3c6787dbaeda56529e
parent 507d37cf269ebbd1b32bcc435fe577e411f73151
author Arnaldo Carvalho de Melo <[EMAIL PROTECTED]> Fri, 09 Sep 2005 08:31:07 
-0300
committer Arnaldo Carvalho de Melo <[EMAIL PROTECTED]> Fri, 09 Sep 2005 
08:31:07 -0300

[CCID3] Calculate ccid3hcrx_x_recv using usecs_div

Signed-off-by: Arnaldo Carvalho de Melo <[EMAIL PROTECTED]>

 net/dccp/ccids/ccid3.c |    7 ++-----
 1 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/net/dccp/ccids/ccid3.c b/net/dccp/ccids/ccid3.c
--- a/net/dccp/ccids/ccid3.c
+++ b/net/dccp/ccids/ccid3.c
@@ -779,11 +779,8 @@ static void ccid3_hc_rx_send_feedback(st
        case TFRC_RSTATE_DATA: {
                const u32 delta = timeval_delta(&now,
                                        &hcrx->ccid3hcrx_tstamp_last_feedback);
-
-               hcrx->ccid3hcrx_x_recv = (hcrx->ccid3hcrx_bytes_recv *
-                                         USEC_PER_SEC);
-               if (likely(delta > 1))
-                       hcrx->ccid3hcrx_x_recv /= delta;
+               hcrx->ccid3hcrx_x_recv = usecs_div(hcrx->ccid3hcrx_bytes_recv,
+                                                  delta);
        }
                break;
        default:
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to