This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

C6678 VLAN Aware

Hi

I tried to implement a filter to accept only untagged packets at gbes MAC port2.

The plan was:

1. enable vlan aware
2. enable ale vlan aware
3. disable ale bypass
4. clear ale table
5. set port2 to tag untagged packets with 0x10
6. add ale entry to accept vlan 0x10
7. set to untag on egress.
8. no unknown ale entry

Code:

    CSL_CPSW_3GF_enableVlanAware();
    CSL_CPSW_3GF_enableAleVlanAware();
    CSL_CPSW_3GF_disableAleBypass();

    CSL_CPSW_3GF_setPortVlanReg(0 0x10, 1, 2);

    CSL_CPSW_3GF_setAleUnkownVlanReg(0,0,0,0);

    aleVlanEntry.vlanId = 0x10;
    aleVlanEntry.vlanMemList = 5;
    aleVlanEntry.forceUntaggedEgress = 5;
    aleVlanEntry.regMcastFloodMask = 5;
    aleVlanEntry.unRegMcastFloodMask = 5;

    CSL_CPSW_3GF_setAleVlanEntry(index++, &aleVlanEntry);


I find that this 
1. correctly adds vlan tags to untagged broadcast traffic.
2. passes broadcast packets out of port0 ok.
3. does not pass unicast packets out of port0.
4. I can't tell if unicast packets are not tagged and then dropped or
tagged and then dropped. no visibility.

(setting force untagged to 0 confirms that broadcast are being tagged.
Still don't see unicast)

Is this a reasonable expectation that I can filter untagged packets in
this manner?

Why are unicast packets being dropped? 
(even though they match the vlan id in the ale rule)

PDK is at pdk_C6678_1_1_2_5

Thanks

  • Maybe this is a clue?

    SPRUGV9D

    2.3.6.5.2 ALE VLAN Aware Lookup Process
    This section describes the behaviour of the ALE VLAN aware lookup process.

    ...

    if (unicast packet)
    then use VLAN_MEMBER_LIST less host port and go to Egress process

    Why remove the host port from the VLAN_MEMBERLIST ?

  • If you disabled ALE bypass, you will not be able to receive any unicast packets. You need to either: send out a unicast packet first, so this can be added to ALE automatically and you can receive unicast later. Or, you need add an ALE entry.

    Without this entry, your incoming packet is treated as case 3, of 2.3.6.5.2, "less host port". So your host can't receive it. If ALE has such an entry, then it is for cases 1 or 2, "destination address found", this should work.   

    Regards, Eric

  • Hello,

    You say that "You need to either: send out a unicast packet first, so this can be added to ALE automatically and you can receive unicast later. Or, you need add an ALE entry. "

    1. How ALE can add unicast automatically? enable learning?
    2. What kind of entry can I add to ALE to direct packets to host port (not broadcast packets)? As you know if packets are not broadcast, ALE dont direct unicast packets to host port. So according to your opinion how can be overcomed this issue?

    Regards,Serdar