[dpdk-dev] [PATCH v2] meter: fix excess token bucket update in srtcm implementation

Dumitrescu, Cristian cristian.dumitrescu at intel.com
Wed Sep 21 10:57:16 CEST 2016



> -----Original Message-----
> From: Nikhil Jagtap [mailto:nikhil.jagtap at gmail.com]
> Sent: Wednesday, September 21, 2016 6:58 AM
> To: Dumitrescu, Cristian <cristian.dumitrescu at intel.com>
> Cc: dev at dpdk.org; Ramia, Kannan Babu <kannan.babu.ramia at intel.com>;
> Nikhil Jagtap <nikhil.jagtap at gmail.com>
> Subject: [PATCH v2] meter: fix excess token bucket update in srtcm
> implementation
> 
> As per srTCM RFC 2697, we should be updating the E bucket only after the
> C bucket overflows. This patch fixes the current DPDK implementation,
> where we are updating both the buckets simultaneously at the same rate
> (CIR) which results in token accumulation rate of (2*CIR).
> 
> Signed-off-by: Nikhil Jagtap <nikhil.jagtap at gmail.com>
> ---
> 
> v2:
> Removed the else part and instead added a default initialization of te.
> 
> ---
>  lib/librte_meter/rte_meter.h |   24 ++++++++++++++----------
>  1 files changed, 14 insertions(+), 10 deletions(-)
> 

Acked-by: Cristian Dumitrescu <cristian.dumitrescu at intel.com>

Thanks, Nikhil!



More information about the dev mailing list