From eeaefa7878b6d7682c6dbd58789d685b6daecc86 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Wed, 27 Apr 2011 11:29:50 -0700 Subject: [PATCH] ofproto: Fix number of reported tables in OFPT_FEATURES_REPLY message. This has been wrong for a long time. --- ofproto/ofproto.c | 2 +- tests/ofproto.at | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ofproto/ofproto.c b/ofproto/ofproto.c index 3d995e19..a9f3704e 100644 --- a/ofproto/ofproto.c +++ b/ofproto/ofproto.c @@ -1362,7 +1362,7 @@ handle_features_request(struct ofconn *ofconn, const struct ofp_header *oh) osf = make_openflow_xid(sizeof *osf, OFPT_FEATURES_REPLY, oh->xid, &buf); osf->datapath_id = htonll(ofproto->datapath_id); osf->n_buffers = htonl(pktbuf_capacity()); - osf->n_tables = 2; + osf->n_tables = 1; osf->capabilities = htonl(OFPC_FLOW_STATS | OFPC_TABLE_STATS | OFPC_PORT_STATS | OFPC_ARP_MATCH_IP); osf->actions = htonl((1u << OFPAT_OUTPUT) | diff --git a/tests/ofproto.at b/tests/ofproto.at index 9587c978..6f785e97 100644 --- a/tests/ofproto.at +++ b/tests/ofproto.at @@ -11,7 +11,7 @@ OFPROTO_START AT_CHECK([ovs-ofctl -vANY:ANY:WARN show br0], [0], [stdout]) AT_CHECK([STRIP_XIDS stdout], [0], [dnl OFPT_FEATURES_REPLY: ver:0x1, dpid:fedcba9876543210 -n_tables:2, n_buffers:256 +n_tables:1, n_buffers:256 features: capabilities:0x87, actions:0xfff LOCAL(br0): addr:aa:55:aa:55:00:00, config: 0x1, state:0x1 OFPT_GET_CONFIG_REPLY: frags=normal miss_send_len=0 @@ -33,7 +33,7 @@ do AT_CHECK([ovs-ofctl -vANY:ANY:WARN show br0], [0], [stdout]) AT_CHECK_UNQUOTED([STRIP_XIDS stdout], [0], [dnl OFPT_FEATURES_REPLY: ver:0x1, dpid:fedcba9876543210 -n_tables:2, n_buffers:256 +n_tables:1, n_buffers:256 features: capabilities:0x87, actions:0xfff LOCAL(br0): addr:aa:55:aa:55:00:00, config: $config, state:$state OFPT_GET_CONFIG_REPLY: frags=normal miss_send_len=0 -- 2.30.2