v4 if next to v6 if, not to nat64
This commit is contained in:
parent
f80ecc1d68
commit
7bba816f2c
2 changed files with 43 additions and 24 deletions
19
doc/plan.org
19
doc/plan.org
|
@ -6787,6 +6787,25 @@ action delta_udp_from_v6_to_v4()
|
|||
|
||||
#+END_CENTER
|
||||
|
||||
*** TODO 2019-07-25: BUG overwrite
|
||||
#+BEGIN_CENTER
|
||||
make -C src/
|
||||
make[1]: Entering directory '/home/nico/projects/P4-NetFPGA/contrib-projects/sume-sdnet-switch/projects/minip4/src'
|
||||
p4c-sdnet -o minip4.sdnet --sdnet_info .sdnet_switch_info.dat minip4_solution.p4
|
||||
minip4_solution.p4(19): [--Wwarn=uninitialized_out_param] warning: out parameter meta may be uninitialized when RealParser terminates
|
||||
out metadata meta,
|
||||
^^^^
|
||||
minip4_solution.p4(16)
|
||||
parser RealParser(
|
||||
^^^^^^^^^^
|
||||
terminate called after throwing an instance of 'Util::CompilerBug'
|
||||
what(): In file: /wrk/hdscratch/staff/mohan/p4c_sdnet/build/p4c/extensions/sdnet/translate/core/tupleEngine.cpp:324
|
||||
Compiler Bug: overwrite
|
||||
|
||||
Makefile:34: recipe for target 'all' failed
|
||||
|
||||
#+END_CENTER
|
||||
|
||||
** The NetPFGA saga
|
||||
Problems encountered:
|
||||
- The logfile for a compile run is 10k+ lines
|
||||
|
|
|
@ -130,35 +130,35 @@ control RealMain(
|
|||
|
||||
v4_networks.apply(); /* apply egress for IPv4 */
|
||||
exit; /* no further v6 processing */
|
||||
|
||||
} else if(hdr.ipv4.isValid()) {
|
||||
if(nat46.apply().hit) {
|
||||
if(hdr.icmp.isValid()) {
|
||||
nat46_icmp_generic();
|
||||
|
||||
if(hdr.icmp.type == ICMP_ECHO_REPLY) {
|
||||
hdr.icmp6.type = ICMP6_ECHO_REPLY;
|
||||
}
|
||||
if(hdr.icmp.type == ICMP_ECHO_REQUEST) {
|
||||
hdr.icmp6.type = ICMP6_ECHO_REQUEST;
|
||||
}
|
||||
}
|
||||
if(hdr.udp.isValid()) {
|
||||
delta_udp_from_v4_to_v6
|
||||
}
|
||||
if(hdr.tcp.isValid()) {
|
||||
delta_tcp_from_v4_to_v6
|
||||
}
|
||||
|
||||
v6_networks.apply();
|
||||
exit;
|
||||
}
|
||||
v4_networks.apply(); /* regular routing, egress */
|
||||
}
|
||||
} else if(hdr.ipv4.isValid()) {
|
||||
if(nat46.apply().hit) {
|
||||
if(hdr.icmp.isValid()) {
|
||||
nat46_icmp_generic();
|
||||
|
||||
if(hdr.icmp.type == ICMP_ECHO_REPLY) {
|
||||
hdr.icmp6.type = ICMP6_ECHO_REPLY;
|
||||
}
|
||||
if(hdr.icmp.type == ICMP_ECHO_REQUEST) {
|
||||
hdr.icmp6.type = ICMP6_ECHO_REQUEST;
|
||||
}
|
||||
}
|
||||
if(hdr.udp.isValid()) {
|
||||
delta_udp_from_v4_to_v6
|
||||
}
|
||||
if(hdr.tcp.isValid()) {
|
||||
delta_tcp_from_v4_to_v6
|
||||
}
|
||||
|
||||
v6_networks.apply();
|
||||
exit;
|
||||
}
|
||||
v4_networks.apply(); /* regular routing, egress */
|
||||
}
|
||||
|
||||
lookup_table.apply();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
control TopPipe(
|
||||
|
|
Loading…
Reference in a new issue