[ovs-dev] [ovs-discuss] [ACLv2 14/19] flow: Add more detailed printing for ARP flows.

Jesse Gross jesse at nicira.com
Fri Sep 4 23:56:46 UTC 2009



Ben Pfaff wrote:
> Jesse Gross <jesse at nicira.com> writes:
>
>   
>> @@ -399,7 +399,19 @@ flow_wildcard_to_string(flow_t *flow, uint32_t wildcards, int verbosity)
>>                  ds_put_cstr(&f, "ip,");
>>              }
>>          } else if (flow->dl_type == htons(ETH_TYPE_ARP)) {
>> -            ds_put_cstr(&f, "arp,");
>> +            if (!(wildcards & OFPFW_NW_PROTO)) {
>> +                skip_proto = true;
>> +                if (flow->nw_proto == ARP_OP_REQUEST) {
>> +                    ds_put_cstr(&f, "arp request,");
>> +                } else if (flow->nw_proto == ARP_OP_REPLY) {
>> +                    ds_put_cstr(&f, "arp reply,");
>>     
>
> The design here is supposed to match the keywords parsed by
> parse_protocol() in ovs-ofctl.c.  Those keywords can't include
> spaces (see str_to_flow()).  For the moment that code doesn't
> care, since OpenFlow doesn't support ARP, but someday it might
> and then it'd be nice to have keywords that can be easily added.
> So I would add a hyphen: "arp-request", "arp-reply".
>
>   

OK, hyphens added.




More information about the dev mailing list