net: Fix a bug when handling IPv6 packets
authorPin-Yen Lin <treapking@google.com>
Mon, 13 Aug 2018 06:23:24 +0000 (14:23 +0800)
committerEarl Ou <shunhsingou@google.com>
Fri, 7 Sep 2018 09:30:30 +0000 (09:30 +0000)
commit606b1b46f5ff382b0d9f35d515f137071785aeab
treedaf0e643cfdc09a283413a4ac4c68d33c86c3eb8
parent743a1b5cdd8e607f2e1bb5ad182047c512eae3f8
net: Fix a bug when handling IPv6 packets

When gem5 runs with the networking support, it will run into an assertion
fail and aborted. This is because it tries to calculate checksum for IPv6
packet and this makes the IpPtr pointer ``ip'' become NULL. For that there
is functions and classes for IPv6 in base/inet.cc, I added IPv6 support for
i8254xGBe.cc. Because IPv6 header does not have identification number,  I
ignored some of the debug messages using ip->id().

Change-Id: Ida5e36aefd2c5c26053f8152a0aac24191e7757c
Reviewed-on: https://gem5-review.googlesource.com/12339
Reviewed-by: Earl Ou <shunhsingou@google.com>
Reviewed-by: Jason Lowe-Power <jason@lowepower.com>
Maintainer: Gabe Black <gabeblack@google.com>
src/dev/net/i8254xGBe.cc