summaryrefslogtreecommitdiff
path: root/src/base/inet.cc
diff options
context:
space:
mode:
authorAndreas Hansson <andreas.hansson@arm.com>2012-09-10 11:57:39 -0400
committerAndreas Hansson <andreas.hansson@arm.com>2012-09-10 11:57:39 -0400
commit1f9c3bcb462f84b97b75f264553180523eaf6419 (patch)
tree223f56e9d5719d8ca0656a2b3af26048ccda696e /src/base/inet.cc
parentd6283445744d5be2a9ac33f0adbc729d48e22c40 (diff)
downloadgem5-1f9c3bcb462f84b97b75f264553180523eaf6419.tar.xz
Inet: Remove the SackRange and its use
This patch aims to simplify the use of the Range class before introducing a more elaborate AddrRegion to replace the AddrRange. The SackRange is the only use of the range class besides address ranges, and the removal of this use makes for an easier modification of the range class. The functionlity that is removed with this patch is not used anywhere throughout the code base.
Diffstat (limited to 'src/base/inet.cc')
-rw-r--r--src/base/inet.cc23
1 files changed, 0 insertions, 23 deletions
diff --git a/src/base/inet.cc b/src/base/inet.cc
index 7d7eb3f5a..d8d156478 100644
--- a/src/base/inet.cc
+++ b/src/base/inet.cc
@@ -254,29 +254,6 @@ TcpHdr::options(vector<const TcpOpt *> &vec) const
return true;
}
-bool
-TcpOpt::sack(vector<SackRange> &vec) const
-{
- vec.clear();
-
- const uint8_t *data = bytes() + sizeof(struct tcp_hdr);
- int all = len() - offsetof(tcp_opt, opt_data.sack);
- while (all > 0) {
- const uint16_t *sack = (const uint16_t *)data;
- int len = sizeof(uint16_t) * 2;
- if (all < len) {
- vec.clear();
- return false;
- }
-
- vec.push_back(RangeIn(ntohs(sack[0]), ntohs(sack[1])));
- all -= len;
- data += len;
- }
-
- return false;
-}
-
int
hsplit(const EthPacketPtr &ptr)
{