master-thesis/p4src/actions_controller.p4

21 lines
524 B
Text
Raw Normal View History

2019-07-10 07:10:59 +00:00
#ifndef NICO_CONTROLLER
#define NICO_CONTROLLER
2019-07-10 07:07:17 +00:00
/********************** 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