Fix for issue 32. (#33)
* This commit includes example tutorials and solutions for P4D2 2017. - Added example P4 programs for ipv4_forwarding, mri, arp, calc - Added python code to invoke compiler, start bmv2, run mininet - Added solutions to above programs - Added README files that describe exercises * Fix for issue #32. The text had said the name of the action should be ipv4_forward, when it should have been set_dst_info.
This commit is contained in:
committed by
Nate Foster
parent
fe61fa61a7
commit
119f267938
@@ -173,10 +173,21 @@ control MyIngress(
|
||||
|
||||
/* TODO: Define actions and tables here */
|
||||
|
||||
|
||||
action set_dst_info(mac_addr_t mac_da,
|
||||
mac_addr_t mac_sa,
|
||||
port_id_t egress_port)
|
||||
{
|
||||
/*
|
||||
* TODO: add logic to store mac addresses and
|
||||
* egress ports in meta data
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
table ipv4_lpm {
|
||||
key = { meta.dst_ipv4 : lpm; }
|
||||
actions = { /* TODO: add actions */ drop; }
|
||||
actions = { set_dst_info; drop; }
|
||||
default_action = drop();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user