allow SAI_ROUTE_ATTR_NEXT_HOP_ID point to SAI_NULL_OBJECT_ID by default#253
allow SAI_ROUTE_ATTR_NEXT_HOP_ID point to SAI_NULL_OBJECT_ID by default#253lguohan merged 2 commits intoopencomputeproject:masterfrom
Conversation
When SAI_ROUTE_ATTR_NEXT_HOP_ID = SAI_NULL_OBJECT_ID, packet is dropped. This allows user to change packet action from DROP to FORWARD using set API. Otherwise, the behavior transition from DROP to FORWARD is undefined.
|
@itaibaz , @AshokDaparthi , @atitjain , @tushar-ty , @krambn, please review. |
|
@kcudnik , this PR give following error. Processing saiwred_8h.xml Can you help? |
| * router IP address. For such routes, fill the CPU port | ||
| * (#SAI_SWITCH_ATTR_CPU_PORT). | ||
| * | ||
| * When it is SAI_NULL_OBJECT_ID, then packet will be dropped. |
There was a problem hiding this comment.
Just to confirm the understanding that NULL_OBJECT_ID can be set when packet action is set to TRAP before and the packet action will take precedence in that case. In other words, the packet will be dropped when packet action is one of the following: FORWARD, COPY, LOG, TRANSIT as mentioned in the comments.
There was a problem hiding this comment.
Yes, that is the understanding. packet action will take precedence.
There was a problem hiding this comment.
or its just cancel forward copy. So for LOG and COPY we still get a copy.
|
Jenkins, test this please |
… forward" (#138) This change breaks the latest test as the current SAI implementation doesn't support the mid-state that the route with packet action DROP is set with next hop ID and packet action FORWARD by two steps. The implementation also prevents removing the default route and create a new route instead. After the SAI implementation is fixed, this change will be re-introduced. ref: opencomputeproject/SAI#253
… forward" (sonic-net#138) This change breaks the latest test as the current SAI implementation doesn't support the mid-state that the route with packet action DROP is set with next hop ID and packet action FORWARD by two steps. The implementation also prevents removing the default route and create a new route instead. After the SAI implementation is fixed, this change will be re-introduced. ref: opencomputeproject/SAI#253
When SAI_ROUTE_ATTR_NEXT_HOP_ID = SAI_NULL_OBJECT_ID, packet is dropped.
This allows user to change packet action from DROP to FORWARD using set API.
Otherwise, the behavior transition from DROP to FORWARD is undefined.