Skip to Content.
Sympa Menu

rare-dev - Re: [rare-dev] further negotiations in between the dataplane and freerouter...

Subject: Rare project developers

List archive

Re: [rare-dev] further negotiations in between the dataplane and freerouter...


Chronological Thread 
  • From: Alexander Gall <>
  • To: mc36 <>
  • Cc: <>, Frédéric LOUI <>, "David Richardson" <>
  • Subject: Re: [rare-dev] further negotiations in between the dataplane and freerouter...
  • Date: Fri, 15 Jul 2022 17:35:10 +0200

On Thu, 14 Jul 2022 19:02:42 +0200, mc36 <> said:

> On 7/14/22 17:55, Alexander Gall wrote:
>>
>>> the other thing is when you swap
>>> the dataplanes: we have dpdk, pcap, xdp, all interchangeable both in
>>> parameters, and so on... but they have different namings for the
>>> interfaces, at least...
>>
>> I don't understand this argument. The p4lang section is specific to
>> the p4 dataplane, isn't it?
>>
> yesss, it is, which nowadays, include the tofino, but we do have the dpdk,

Just to make sure my understanding is correct: these dataplanes all
use the same message format as the p4-specific bf_forwarder and all
use the server p4lang stanza for configuration. The actual dataplane
to be used is chosen by starting a specific forwarder and tying it to
a p4lang instance (via rtr-hw).

Freerouter is not aware of which dataplane it's actually talking to.

It might be time to rename this into "server dataplane" or something
:)

> epbf/xdp, pcap, and an udp based one, and all names their ports
> differently...

Yes, of course :)

[ snip ]

> and all these dataplanes are interchangeable, so one can switch between
> them by just modifying the processes to spawn in -hw.txt.

This is where things get a bit murky for me. First of all, in the
case of Tofino, there actually is only one dataplane and these
conflicts cannot occur. But, ok, this can be viewed as a special case.

Each dataplane uses some kind of intrinsic identifier for an
interface. For Tofino it's the "dev port", dpdk uses the PCI address
etc. Before your recent change one had to enter those identifiers in
the export-port clause. Or so I thought up to now (guess what, I have
never used anything else than Tofino :). In the case of Tofino that's
true. But for the other dataplanes, I think what's happening is that
they have an array of interfaces and the number one enters with
export-port is simply the index into that array. Is this correct? At
least that's the number that's mapped to the name with the new
"portname" mechanism, AFAICS.

Your argument then appears to be that if we used the names (which are
essentially the intrinsic identifiers) instead of the number, that
name would become meaningless if we switch to another dataplane while
the number would be universal. Is that what you mean?

But then I really don't understand how that can be true in
general. Wouldn't that imply that the dataplane you switch to must see
exactly the same devices and they would have to be in the same order,
too? How can you be sure that's true? Maybe your test cases just
happen to be constructed that way or?

From a user perspective, this seems to have even more potential for
confusion. For Tofino, at least you can go check with bfshell which
port a number represents. For other dataplanes, how would you figure
out which interface

export-port sdn1 13

refers to?

I'm sure I only really understand a fraction of what's going on here,
so appologies if I get things wrong.

--
Alex



Archive powered by MHonArc 2.6.19.

Top of Page