• Jarek Poplawski's avatar
    pkt_sched: Change PSCHED_SHIFT from 10 to 6 · a4a710c4
    Jarek Poplawski authored
    Change PSCHED_SHIFT from 10 to 6 to increase schedulers time
    resolution. This will increase 16x a number of (internal) ticks per
    nanosecond, and is needed to improve accuracy of schedulers based on
    rate tables, like HTB, TBF or CBQ, with rates above 100Mbit. It is
    assumed this change is safe for 32bit accounting of time diffs up
    to 2 minutes, which should be enough for common use (extremely low
    rate values may overflow, so get inaccurate instead). To make full
    use of this change an updated iproute2 will be needed. (But using
    older iproute2 should be safe too.)
    
    This change breaks ticks - microseconds similarity, so some minor code
    fixes might be needed. It is also planned to change naming adequately
    eg. to PSCHED_TICKS2NS() etc. in the near future.
    Reported-by: default avatarAntonio Almeida <vexwek@gmail.com>
    Tested-by: default avatarAntonio Almeida <vexwek@gmail.com>
    Signed-off-by: default avatarJarek Poplawski <jarkao2@gmail.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    a4a710c4
pkt_sched.h 3.14 KB