master-thesis/p4src/actions_controller.p4
2019-07-10 09:10:59 +02:00

21 lines
No EOL
524 B
Text

#ifndef NICO_CONTROLLER
#define NICO_CONTROLLER
/********************** GENERAL ACTIONS ***********************************/
action controller_reply(task_t task) {
meta.task = task;
meta.ingress_port = standard_metadata.ingress_port;
clone3(CloneType.I2E, 100, meta);
}
action controller_debug_table_id(table_t table_id) {
meta.table_id = table_id;
controller_reply(TASK_DEBUG);
}
action controller_debug() {
controller_reply(TASK_DEBUG);
}
#endif