From b9d6a7b68e93c9a7a48b2dada6e7380190480b79 Mon Sep 17 00:00:00 2001 From: Shivani Bhardwaj Date: Thu, 7 Apr 2016 22:58:54 +0530 Subject: src: evaluate: Show error for fanout without balance The idea of fanout option is to improve the performance by indexing CPU ID to map packets to the queues. This is used for load balancing. Fanout option is not required when there is a single queue specified. According to iptables, queue balance should be specified in order to use fanout. Following that, throw an error in nftables if the range of queues for load balancing is not specified with the fanout option. After this patch, $ sudo nft add rule ip filter forward counter queue num 0 fanout :1:46-46: Error: fanout requires a range to be specified add rule ip filter forward counter queue num 0 fanout ^^^^^ Signed-off-by: Shivani Bhardwaj Signed-off-by: Pablo Neira Ayuso --- src/parser_bison.y | 1 + 1 file changed, 1 insertion(+) (limited to 'src/parser_bison.y') diff --git a/src/parser_bison.y b/src/parser_bison.y index 4b7c1f5a..444ed4c2 100644 --- a/src/parser_bison.y +++ b/src/parser_bison.y @@ -1722,6 +1722,7 @@ queue_stmt_args : queue_stmt_arg queue_stmt_arg : QUEUENUM stmt_expr { $0->queue.queue = $2; + $0->queue.queue->location = @$; } | queue_stmt_flags { -- cgit v1.2.3