Send OFPET_BAD_INSTRUCTION/OFPBIC_BAD_TABLE_ID if table is invalid
in goto table instruction.
Signed-off-by: Selvamuthukumar <smkumar@merunetworks.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
uint8_t goto_table = ofpact_get_GOTO_TABLE(a)->table_id;
if ((table_id != 255 && goto_table <= table_id)
|| (n_tables != 255 && goto_table >= n_tables)) {
- return OFPERR_OFPBRC_BAD_TABLE_ID;
+ return OFPERR_OFPBIC_BAD_TABLE_ID;
}
return 0;
}
0001 0008 01 000001
dnl Goto-Table 1 instruction go back to the previous table.
-# bad OF1.1 instructions: OFPBRC_BAD_TABLE_ID
+# bad OF1.1 instructions: OFPBIC_BAD_TABLE_ID
2,0001 0008 01 000000
dnl Goto-Table 1
# but at least it's the same code in ofpacts_check() that issues the error.
AT_CHECK([ovs-ofctl add-flow -O OpenFlow11 br0 table=1,action=goto_table:1],
[1], [],
- [ovs-ofctl: actions are invalid with specified match (OFPBRC_BAD_TABLE_ID)
+ [ovs-ofctl: actions are invalid with specified match (OFPBIC_BAD_TABLE_ID)
])
OVS_VSWITCHD_STOP
AT_CLEANUP