Skip to content

Traffic capture of raw primitives #54

@bluecmd

Description

@bluecmd

From playing around with fejkon with some actual FC traffic it has become clear that there will be a need to capture behavior on the primitives.

For example when debugging why Brocade loopbacks wouldn't come up in #26 it seems the Brocade switch sends a bunch of primitives that fejkon 1) does not know about and 2) implementing would be infeasible.

Switching to xcvr <-> xcvr based mode is in progress which means that supporting this kind of traffic will be done, but in order to analyze this kind of low-level traffic there needs to be a way to capture essentially a waveform of the primitives.

I have been thinking about something like this:

                        csr
                         +
                         |
                    +----v---------+           +------------+
                    |              |           |            |
    +---------+     |              +---------->+   Memory   <-------+
+-->+  Port 0 +---->+              |           |            |       |
    +---------+     |      RLE     |           +------------+       |
    +---------+     |    Encoder   |           +------------+       |
+-->+  Port 1 +---->+              |           |            |       |
    +---------+     |              +---------->+   Memory   <-------+
                    |              |           |            |       |
                    +-----^--------+           +------------+       |
                          |                                         |
                          +                                         |
                      106.25 MHz                                    |
                                                                    |
                                                                    |
                                                                    +
                                                                  Data

Writing to a fixed-sized memory should allow one to trigger a ~synchronized capture of Port 0 and 1 being written to two memories encoded using RLE. A simple data format such as 64-bit formatted as 24-bit count | 4-bit metadata | 4-bit K-value | 32-bit value should be fine. 24-bit counter means that a fully idle stream will write out 7x idle frames every second as the counter wrap around is reached. This should be ample for our needs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestfcAffects the Fibre Channel part

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions