From 174f4a120ec7644531728621cfab5ce7fdb481c3 Mon Sep 17 00:00:00 2001 From: Pablo Neira Ayuso Date: Mon, 3 Aug 2015 15:56:27 +0200 Subject: src: add burst parameter to limit ... limit rate 1024 mbytes/second burst 10240 bytes ... limit rate 1/second burst 3 packets This parameter is optional. You need a Linux kernel >= 4.3-rc1. Signed-off-by: Pablo Neira Ayuso --- include/datatype.h | 3 +++ include/statement.h | 1 + 2 files changed, 4 insertions(+) (limited to 'include') diff --git a/include/datatype.h b/include/datatype.h index ebafa655..07fedce8 100644 --- a/include/datatype.h +++ b/include/datatype.h @@ -239,4 +239,7 @@ extern struct error_record *rate_parse(const struct location *loc, const char *str, uint64_t *rate, uint64_t *unit); +extern struct error_record *data_unit_parse(const struct location *loc, + const char *str, uint64_t *rate); + #endif /* NFTABLES_DATATYPE_H */ diff --git a/include/statement.h b/include/statement.h index d2d0852e..bead0a6f 100644 --- a/include/statement.h +++ b/include/statement.h @@ -52,6 +52,7 @@ struct limit_stmt { uint64_t rate; uint64_t unit; enum nft_limit_type type; + uint32_t burst; }; extern struct stmt *limit_stmt_alloc(const struct location *loc); -- cgit v1.2.3