On 2015-11-24 at 12:20 Kevin Klues <[email protected]> wrote:
> >> +     usec += kreq.tv_nsec ? (kreq.tv_nsec - 1)/1000 + 1 : 0;
> >
> > We have a helper for this, which I think does what you want:
> >
> > #define DIV_ROUND_UP(n,d) (((n) + (d) - 1) / (d))
> 
> This only works in cases where we don't have to worry about overflow
> for (n) (such as this because kreq.tv_nsec is maxed out at 999999999).
> If ((n) + (d) -1) were to overflow, this would cause problems.
> 
> Either way, i've updated it to make this call and pushed it.

Thanks, merged to master at fafa68356f11..aecd50eb71c2 (from, to]

You can see the entire diff with 'git diff' or at
https://github.com/brho/akaros/compare/fafa68356f11...aecd50eb71c2

---------
btw, these tests take a long time:

/ $ /bin/tests/utest/sleep
<-- BEGIN_USERSPACE_SLEEP_TESTS -->
        PASSED   [test_nanosleep](35.622515s)   
        PASSED   [test_usleep](15.017327s)   
        PASSED   [test_sleep](75.003688s)   
<-- END_USERSPACE_SLEEP_TESTS -->
/ $ 

is that going to mess with the timeout you set up with jenkins?  (not
sure if that was a thing or not).

barret

-- 
You received this message because you are subscribed to the Google Groups 
"Akaros" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to