projects
/
gem5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3134283
)
Add serialization for etherdev
author
Steve Raasch
<sraasch@umich.edu>
Thu, 30 Oct 2003 01:24:47 +0000
(20:24 -0500)
committer
Steve Raasch
<sraasch@umich.edu>
Thu, 30 Oct 2003 01:24:47 +0000
(20:24 -0500)
These changes don't seem to break anything, and may even be correct.
dev/etherpkt.hh:
Add serialization
--HG--
extra : convert_revision :
02962b9bef01c1c3f35a095788117bd95e7ed4bc
dev/etherpkt.hh
patch
|
blob
|
history
diff --git
a/dev/etherpkt.hh
b/dev/etherpkt.hh
index 678b83b33611a9740ed111a94e4a35abe72c3925..030f51317432a4d9f5278959c1ddcc35c24f672c 100644
(file)
--- a/
dev/etherpkt.hh
+++ b/
dev/etherpkt.hh
@@
-39,6
+39,8
@@
#include "base/refcnt.hh"
+class IniFile;
+
/*
* Reference counted class containing ethernet packet data
*/
@@
-58,6
+60,9
@@
class EtherPacket : public RefCounted
bool IsUnicast() { return data[0] == 0x00; }
bool IsMulticast() { return data[0] == 0x01; }
bool IsBroadcast() { return data[0] == 0xff; }
+
+ virtual void serialize(std::ostream &os);
+ virtual void unserialize(const IniFile *db, const std::string §ion);
};
typedef RefCountingPtr<EtherPacket> PacketPtr;