Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run time error "cannot add the same kind of tag twice" #27

Open
princhenee opened this issue Jan 5, 2019 · 0 comments
Open

Run time error "cannot add the same kind of tag twice" #27

princhenee opened this issue Jan 5, 2019 · 0 comments

Comments

@princhenee
Copy link

princhenee commented Jan 5, 2019

Hi Yibo,

have you ever met this error "cannot add the same kind of tag twice"?
I got this error whenever a CNP is passing two switch nodes.

This error is thrown here:
"src/point-to-point/model/qbb-net-device.cc:459-461 "

if (ipv4h.GetProtocol() != 0xFE) //not PFC
{
        packet->AddPacketTag(FlowIdTag(m_ifIndex));
......

Here, It seems that when a CNP(ipv4h.GetProtocol=0xFF) arrives at a switch node,
the packet tag will be added.

But the tag is not removed when leaving switch, specified in this scope:
"src/point-to-point/model/qbb-net-device.cc:349 "

if (m_queue->GetLastQueue() == qCnt - 1)//this is a pause or cnp, send it immediately!

I traced back and found when the CNP arrives at the next switch node, the error occurs.

Then I added a code snippet to remove the tag within the 'if' scope in
"src/point-to-point/model/qbb-net-device.cc:349"

if (m_queue->GetLastQueue() == qCnt - 1)//this is a pause or cnp, send it immediately!
  {
+      if (h.GetProtocol() != 0xFE) //not PFC , here h refers to ipv4header
+        {
+            p->RemovePacketTag(t);
+        }
	TransmitStart(p);
  }

The error does not occur now.

I wonder if this is a bug or due to I have missed something in configuration.
I met this in an Incast test scenario.

Thanks,
Ge

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant