dev: Fix style in pktfifo.hh.
Put return types of multi-line functions on their own line. Change-Id: I6c9cade720bd1c7aaa09c42b838c9bd83da7bc8f Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/48925 Reviewed-by: Daniel Carvalho <odanrc@yahoo.com.br> Maintainer: Gabe Black <gabe.black@gmail.com> Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
@@ -64,7 +64,8 @@ struct PacketFifoEntry
|
||||
{
|
||||
}
|
||||
|
||||
void clear()
|
||||
void
|
||||
clear()
|
||||
{
|
||||
packet = NULL;
|
||||
number = 0;
|
||||
@@ -120,7 +121,8 @@ class PacketFifo
|
||||
|
||||
EthPacketPtr front() { return fifo.begin()->packet; }
|
||||
|
||||
bool push(EthPacketPtr ptr)
|
||||
bool
|
||||
push(EthPacketPtr ptr)
|
||||
{
|
||||
assert(ptr->length);
|
||||
assert(_reserved <= ptr->length);
|
||||
@@ -137,7 +139,8 @@ class PacketFifo
|
||||
return true;
|
||||
}
|
||||
|
||||
void pop()
|
||||
void
|
||||
pop()
|
||||
{
|
||||
if (empty())
|
||||
return;
|
||||
@@ -149,7 +152,8 @@ class PacketFifo
|
||||
fifo.pop_front();
|
||||
}
|
||||
|
||||
void clear()
|
||||
void
|
||||
clear()
|
||||
{
|
||||
for (iterator i = begin(); i != end(); ++i)
|
||||
i->clear();
|
||||
@@ -158,7 +162,8 @@ class PacketFifo
|
||||
_reserved = 0;
|
||||
}
|
||||
|
||||
void remove(iterator i)
|
||||
void
|
||||
remove(iterator i)
|
||||
{
|
||||
if (i != fifo.begin()) {
|
||||
iterator prev = i;
|
||||
@@ -177,14 +182,16 @@ class PacketFifo
|
||||
|
||||
bool copyout(void *dest, unsigned offset, unsigned len);
|
||||
|
||||
int countPacketsBefore(const_iterator i) const
|
||||
int
|
||||
countPacketsBefore(const_iterator i) const
|
||||
{
|
||||
if (i == fifo.end())
|
||||
return 0;
|
||||
return i->number - fifo.begin()->number;
|
||||
}
|
||||
|
||||
int countPacketsAfter(const_iterator i) const
|
||||
int
|
||||
countPacketsAfter(const_iterator i) const
|
||||
{
|
||||
auto end = fifo.end();
|
||||
if (i == end)
|
||||
@@ -192,7 +199,8 @@ class PacketFifo
|
||||
return (--end)->number - i->number;
|
||||
}
|
||||
|
||||
void check() const
|
||||
void
|
||||
check() const
|
||||
{
|
||||
unsigned total = 0;
|
||||
for (auto i = begin(); i != end(); ++i)
|
||||
|
||||
Reference in New Issue
Block a user