Correct the return status of ENOSPC when flow table FULL
When the Agent adds a flow entry to Vrouter kernel module
(in particular reverse flow entry as forward flow entry is
always added by data path) and if the flow table is full,
Agent expects the return status as ENOSPC. But Vrouter is
returing EEXISTS wrongly. This is because, vr_find_free_entry()
is manipulating the flow index to 0 (which is a valid flow index)
even when the free entry is not found.
As a fix, the returned flow index is not manipulated if the free
flow entry is not found
Reviewed: https:/ /review. opencontrail. org/33404 github. com/Juniper/ contrail- vrouter/ commit/ 3ee94b5c00aad86 920113531ccf960 a14e912a48
Committed: http://
Submitter: Zuul (<email address hidden>)
Branch: R2.21.x
commit 3ee94b5c00aad86 920113531ccf960 a14e912a48
Author: Hari Prasad Killi <email address hidden>
Date: Tue Jul 4 14:20:40 2017 +0530
Correct the return status of ENOSPC when flow table FULL
When the Agent adds a flow entry to Vrouter kernel module free_entry( )
(in particular reverse flow entry as forward flow entry is
always added by data path) and if the flow table is full,
Agent expects the return status as ENOSPC. But Vrouter is
returing EEXISTS wrongly. This is because, vr_find_
is manipulating the flow index to 0 (which is a valid flow index)
even when the free entry is not found.
As a fix, the returned flow index is not manipulated if the free
flow entry is not found
Change-Id: Ia8e68006fdea1f 36fedf5b99ed9cc 7884e04e3b9
closes-bug: #1699425