[ovs-git] [openvswitch/ovs] f56347: ofproto-dpif-xlate: Fix packet_in reason for Table...

GitHub noreply at github.com
Fri Jul 6 20:10:18 UTC 2018

  Branch: refs/heads/master
  Home:   https://github.com/openvswitch/ovs
  Commit: f5634764607dfa23ee1eb64831cc6ea3fa8545ac
  Author: Keshav Gupta <keshav.gupta at ericsson.com>
  Date:   2018-07-06 (Fri, 06 Jul 2018)

  Changed paths:
    M ofproto/ofproto-dpif-xlate.c
    M tests/ofproto-dpif.at

  Log Message:
  ofproto-dpif-xlate: Fix packet_in reason for Table-miss rule

Currently in OvS if we hit "Table-miss" rules (associated with Controller
action) then we send PACKET_IN message to controller with reason as

“Table-miss” rule is one whose priority is 0 and its catch all rule.

But if we hit same "Table-miss" rule after executing group entry we will
send the reason as OFPR_ACTION (for OF1.3 and below) and OFPR_GROUP
(for OF1.4 and above).

This is because once we execute group entry we set ctx->in_group and later
when we hit the "Table-miss" rule, Since ctx->in_group  is set we send
reason as OFPR_ACTION (for OF1.3) and OFPR_GROUP (for OF1.4 and above).

For eg: for the following pipeline, we will send the reason as OFPR_ACTION
even if we hit The “Table-miss” rule.

cookie=0x8000000, duration=761.189s, table=0, n_packets=1401, n_bytes=67954,

cookie=0x6800001, duration=768.848s, table=17, n_packets=1418, n_bytes=68776,

cookie=0x6800000, duration=24944.312s, table=60, n_packets=58244,
  n_bytes=2519520, priority=0 actions=resubmit(,17)

cookie=0x8040000, duration=785.733s, table=17, n_packets=1450, n_bytes=69724,

cookie=0x822002d, duration=24960.795s, table=43, n_packets=53097,
  n_bytes=2230074, priority=100,arp,arp_op=1 actions=group:6000

  bucket=actions=resubmit(,48), bucket=actions=resubmit(,81)

cookie=0x8500000, duration=24977.323s, table=48, n_packets=58309, n_bytes=2522634,
  priority=0 actions=resubmit(,49),resubmit(,50)

cookie=0x8050000, duration=24984.679s, table=50, n_packets=6, n_bytes=264,
  priority=0 actions=CONTROLLER:65535

Currently we are sending table_id as 50 and packet_in reason as OFPR_ACTION.
Instead of sending packet_in reason as OFPR_NO_MATCH.

Signed-off-by: Keshav Gupta <keshav.gupta at ericsson.com>
Co-authored-by: Rohith Basavaraja <rohith.basavaraja at gmail.com>
Signed-off-by: Rohith Basavaraja <rohith.basavaraja at gmail.com>
Signed-off-by: Ben Pfaff <blp at ovn.org>

      **NOTE:** This service been marked for deprecation: https://developer.github.com/changes/2018-04-25-github-services-deprecation/

      Functionality will be removed from GitHub.com on January 31st, 2019.

More information about the git mailing list