From d1993ffea5d91f28f39838e8bcb1c67bc6bec790 Mon Sep 17 00:00:00 2001 From: Simon Horman Date: Wed, 3 Aug 2011 11:19:46 +0900 Subject: [PATCH] datapath: Allow table to expand to have TBL_MAX_BUCKETS buckets This resolves what appears to be a logic error whereby the maximum number of buckets is limited to only half of TBL_MAX_BUCKETS. Signed-off-by: Simon Horman Signed-off-by: Jesse Gross --- datapath/table.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/datapath/table.c b/datapath/table.c index 76086ee46..36613bd90 100644 --- a/datapath/table.c +++ b/datapath/table.c @@ -333,7 +333,7 @@ struct tbl *tbl_expand(struct tbl *table) int n_buckets = table->n_buckets * 2; struct tbl *new_table; - if (n_buckets >= TBL_MAX_BUCKETS) { + if (n_buckets > TBL_MAX_BUCKETS) { err = -ENOSPC; goto error; } -- 2.43.0