Debug missing checksum, introduce new field
This commit is contained in:
parent
2e8f51929b
commit
c6b1463e17
4 changed files with 10 additions and 5 deletions
|
@ -415,7 +415,11 @@ DEBUG:main:reassambled=<Ether dst=33:33:ff:00:00:42 src=00:00:0a:00:00:01 type=
|
||||||
|
|
||||||
That looks like NDP is not working again. Why: checksum seems to be
|
That looks like NDP is not working again. Why: checksum seems to be
|
||||||
incorrect according to wireshark. Why? Checksum is the SAME as in the
|
incorrect according to wireshark. Why? Checksum is the SAME as in the
|
||||||
request -> probably not updated.
|
request -> probably not updated. After inserting marker: it's clear
|
||||||
|
that the checksum code DOES NOT work on the task field!
|
||||||
|
|
||||||
|
Problem: task field might be overriden for controller use in different
|
||||||
|
table -> need different task field!
|
||||||
|
|
||||||
*** TODO Get p4 VM / vagrant running
|
*** TODO Get p4 VM / vagrant running
|
||||||
**** DONE install libvirtd-daemon
|
**** DONE install libvirtd-daemon
|
||||||
|
|
|
@ -21,7 +21,7 @@ control MyVerifyChecksum(inout headers hdr, inout metadata meta) {
|
||||||
|
|
||||||
control MyComputeChecksum(inout headers hdr, inout metadata meta) {
|
control MyComputeChecksum(inout headers hdr, inout metadata meta) {
|
||||||
apply {
|
apply {
|
||||||
update_checksum_with_payload(meta.task == TASK_CHECKSUM_ICMP6,
|
update_checksum_with_payload(meta.switch_task == TASK_CHECKSUM_ICMP6,
|
||||||
{
|
{
|
||||||
hdr.ipv6.src_addr, /* 128 */
|
hdr.ipv6.src_addr, /* 128 */
|
||||||
hdr.ipv6.dst_addr, /* 128 */
|
hdr.ipv6.dst_addr, /* 128 */
|
||||||
|
@ -36,7 +36,7 @@ control MyComputeChecksum(inout headers hdr, inout metadata meta) {
|
||||||
);
|
);
|
||||||
|
|
||||||
/* checksumming for icmp6_na_ns_option */
|
/* checksumming for icmp6_na_ns_option */
|
||||||
update_checksum_with_payload(meta.task == TASK_CHECKSUM_ICMP6_NA,
|
update_checksum_with_payload(meta.switch_task == TASK_CHECKSUM_ICMP6_NA,
|
||||||
{
|
{
|
||||||
hdr.ipv6.src_addr, /* 128 */
|
hdr.ipv6.src_addr, /* 128 */
|
||||||
hdr.ipv6.dst_addr, /* 128 */
|
hdr.ipv6.dst_addr, /* 128 */
|
||||||
|
|
|
@ -166,6 +166,7 @@ struct headers {
|
||||||
struct metadata {
|
struct metadata {
|
||||||
port_t ingress_port;
|
port_t ingress_port;
|
||||||
task_t task;
|
task_t task;
|
||||||
|
task_t switch_task;
|
||||||
bit<16> tcp_length;
|
bit<16> tcp_length;
|
||||||
bit<32> cast_length;
|
bit<32> cast_length;
|
||||||
}
|
}
|
||||||
|
|
|
@ -197,7 +197,7 @@ control MyIngress(inout headers hdr,
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* checksum trigger / content */
|
/* checksum trigger / content */
|
||||||
meta.task = TASK_CHECKSUM_ICMP6_NA;
|
meta.switch_task = TASK_CHECKSUM_ICMP6_NA;
|
||||||
meta.cast_length = (bit<32>) hdr.ipv6.payload_length;
|
meta.cast_length = (bit<32>) hdr.ipv6.payload_length;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -212,7 +212,7 @@ control MyIngress(inout headers hdr,
|
||||||
|
|
||||||
hdr.icmp6.type = ICMP6_ECHO_REPLY;
|
hdr.icmp6.type = ICMP6_ECHO_REPLY;
|
||||||
|
|
||||||
meta.task = TASK_CHECKSUM_ICMP6;
|
meta.switch_task = TASK_CHECKSUM_ICMP6;
|
||||||
meta.cast_length = (bit<32>) hdr.ipv6.payload_length;
|
meta.cast_length = (bit<32>) hdr.ipv6.payload_length;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue