Acked-by: William Tu
On Thu, Sep 15, 2016 at 11:11 AM, Ben Pfaff wrote:
> See https://tools.ietf.org/html/draft-foschiano-erspan-01. Even though
> that draft has expired, it's genuine documentation.
>
> Signed-off-by: Ben Pfaff
> ---
> FAQ.md | 5 ++---
> 1 file c
LGTM, tested it and no problem. thanks for the fix.
Acked-by: William Tu
On Thu, Aug 18, 2016 at 3:56 PM, Joe Stringer wrote:
> This is available in GNU awk, but not other awks (eg mawk). Drop this in
> favour of "ofctl_strip" to produce reliable output.
>
> Signe
igured before
becoming up state. Note that the original 'link-args' is renamed to
'type-args'.
Signed-off-by: William Tu
---
tests/system-common-macros.at | 13 +++--
tests/system-traffic.at | 3 +--
2 files changed, 8 insertions(+), 8 deletions(-)
diff --git a
Ubuntu 14.04 with kernel 3.13 fails to set a GRE tunnel's mac address after
device state is up. The patch adds mac address setting in ADD_NATIVE_TUNNEL
as an optional configuration parameter so that we can set the mac address,
then bring up the device.
Signed-off-by: William Tu
---
Thanks for making this code much more clean. I've tested it and no problem.
Acked-by: William Tu
On Tue, Aug 9, 2016 at 12:50 PM, Andy Zhou wrote:
> Use ds_get_line() instead of hand rolling it. Rearrange the logic
> to removes some duplication.
>
> Signed-off-by: Andy Zhou
/lex.h
The patch fixes it and tested with rpmbuild 4.13.0 under Fedora 23.
Signed-off-by: William Tu
---
rhel/openvswitch-fedora.spec.in | 1 +
1 file changed, 1 insertion(+)
diff --git a/rhel/openvswitch-fedora.spec.in b/rhel/openvswitch-fedora.spec.in
index 088afcb..34c0f37 100644
--- a/rhel/o
> Is this just because the fedora packaging hasn't been updated to
> provide OVN, or someone has forgotten to update the specfile after
> adding/moving files?
>
> It seems to me like the right solution is to specify these files in
> the specfile somehow, rather than overriding a warning about
> unp
The patch disables it and tested with rpmbuild 4.13.0 under Fedora 23.
Signed-off-by: William Tu
---
rhel/openvswitch-fedora.spec.in | 4
1 file changed, 4 insertions(+)
diff --git a/rhel/openvswitch-fedora.spec.in b/rhel/openvswitch-fedora.spec.in
index 088afcb..f1edd58 100644
--- a/rhel
Thanks, I've submitted v2 which removes the 'const'.
On Wed, Jul 27, 2016 at 1:39 PM, Ben Pfaff wrote:
> On Tue, Jul 26, 2016 at 06:28:30PM -0700, William Tu wrote:
>> Valgrind testcase 1804 ovsdb-server.at:1023 insert rows, update rows by value
>&
(replication.c:445)
process_notification (replication.c:402)
check_for_notifications (replication.c:418)
replication_run (replication.c:110)
Signed-off-by: William Tu
---
v1->v2
* remove 'const' at struct json
---
ovsdb/replication.c | 7 +--
1 file changed, 5 insertions(+)
{
> +if (!is_all_zeros(nas->zeros, sizeof nas->zeros)) {
> +return OFPERR_NXBRC_MUST_BE_ZERO;
> +}
> +
> struct ofpact_sample *sample;
>
> sample = ofpact_put_SAMPLE(out);
>
>
> Thanks,
>
> Ben.
>
> On Sun, Jul 10, 2016 at 09:24:45PM -07
; ovsdb_condition_destroy(&condition);
> +json_destroy(CONST_CAST(struct json *, where));
> +
> return error;
> }
>
> @@ -625,6 +627,7 @@ execute_update(struct ovsdb_txn *txn, const char *uuid,
> ovsdb_row_destroy(row);
> ovsdb_column_set_destroy
Testcase 1857: ovsdb-monitor.at:538 monitor-cond-change reports the
following definitely memory leak:
ovsdb_schema_create (ovsdb.c:34)
ovsdb_schema_from_json (ovsdb.c:196)
fetch_schema (ovsdb-client.c:385)
do_monitor_cond (ovsdb-client.c:1112)
Signed-of-by: William Tu
---
ovsdb
)
json_from_string (json.c:1025)
parse_json (test-ovsdb.c:227)
update_conditions (test-ovsdb.c:2324)
do_idl (test-ovsdb.c:2389)
ovs_cmdl_run_command (command-line.c:121)
main (test-ovsdb.c:73)
Signed-off-by: William Tu
---
tests/test-ovsdb.c | 1 +
1 file changed, 1
(replication.c:445)
process_notification (replication.c:402)
check_for_notifications (replication.c:418)
replication_run (replication.c:110)
Signed-off-by: William Tu
---
ovsdb/replication.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/ovsdb/replication.c b/ovsdb/replication.c
index
thanks for fixing the memory leak!
Acked-by: William Tu
On Tue, Jul 26, 2016 at 1:08 PM, Andy Zhou wrote:
> Release the memory of reply message of the initial "monitor" request.
>
> Reported-at: http://openvswitch.org/pipermail/dev/2016-July/076075.html
> Si
Hi Andy,
Thanks for fixing the memory leak! I've tested it and it solved the
issue. btw, I think we don't have to assign "NULL" to static variable,
C99 standard assume all static variable initializes to 0.
Acked-by: William Tu
On Tue, Jul 26, 2016 at 1:08 PM, Andy Zhou
Sorry, this should be
Acked-by: William Tu
On Tue, Jul 26, 2016 at 8:32 AM, William Tu wrote:
> Hi Mark,
>
> Thanks for fixing them! looks good to me.
>
> Signed-off-by: William Tu
>
>
>
> On Tue, Jul 26, 2016 at 6:19 AM, Mark Kavanagh
> wrote:
>> Commi
Hi Mark,
Thanks for fixing them! looks good to me.
Signed-off-by: William Tu
On Tue, Jul 26, 2016 at 6:19 AM, Mark Kavanagh
wrote:
> Commit 64839cf43 applies batch objects to netdev-providers, but
> some comments were not updated accordingly. Fix these:
>- replace 'pkt
Hi,
Valgrind reports definitely memory leak in the testcase
1826: ovsdb-server.at:1081 insert monitored table, update excluded table
Can someone take at look? Thank you~
==52969== 144 (48 direct, 96 indirect) bytes in 1 blocks are
definitely lost in loss record 306 of 373
==52969==at 0x4C
Instead of looping into each packet and check whether to truncate, the
patch moves it out of the loop and uses batch API. If truncation is
not set, checking 'trunc' in 'struct dp_packet_batch' at per-batch basis
can skip the per-packet checking overhead.
Signed-off-by:
Looks good to me, thanks for fixing it!
Acked-by: William Tu
On Mon, Jul 25, 2016 at 1:00 AM, Liran Schour wrote:
> Destroy shash on destroy of session's condition structure.
> Reported here: http://openvswitch.org/pipermail/dev/2016-July/075968.html
>
> Signed-off
Hi,
Testcases which exercises this code report definitely memory lost. An
example is testcast 1000: ofproto-dpif.at:957 ofproto-dpif - Default
Table Miss
Since I'm not so familiar with ovsdb code, could someone take a look? thanks!
==59366== 160 bytes in 2 blocks are definitely lost in loss reco
ays be able to optimize them (I checked the assebly
> output in a couple of functions).
>
> Few comments inline, otherwise this looks good to me
>
> 2016-06-29 13:53 GMT-07:00 William Tu :
>>
>> Commit 1895cc8dbb64 ("dpif-netdev: create batch object") introduces
tch APIs can be used in providers. With batch metadata visible in
providers, optimizations can be introduced at per-batch level instead
of per-packet.
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/145694197
Signed-off-by: William Tu
--
v3->v4:
- remove extra variables
- re
Hi Joe,
I agree that this check is kind of redundant. Please remove this line.
Thank you~
William
On Wed, Jul 13, 2016 at 4:57 PM, Joe Stringer wrote:
> On 1 July 2016 at 09:45, William Tu wrote:
>> We generally try to keep the testsuite independent of the underlying
>> datap
Hi Wenyu and Daniel,
Thanks for your feedback.
On Mon, Jul 11, 2016 at 1:50 AM, Wenyu Zhang wrote:
> Hi William,
>
> In your patch, no codes about supporting “snaplen" in IPFIX included. IPFIX
> still get the length of packet as before, whatever the packet is truncated.
> If user put a non-zero
Hi Daniel,
Thanks for reviewing the patch.
Indeed, the way sFlow sets up the datapath does not require the
OpenFlow sample action, and changing OVSDB/compose_sample_action() is
sufficient to program the datapath sample action for current sFlow use
case. So if IPFIX does not use 'snaplen', or there
Hi Ben,
Thanks, I've fixed it and submitted new version.
Regards,
William
On Fri, Jul 1, 2016 at 9:28 PM, Ben Pfaff wrote:
> On Fri, Jul 01, 2016 at 12:43:02PM -0700, William Tu wrote:
>> This patch adds a 'snaplen' field in sample action (nx_action_sample2).
>&g
d.
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/142593443
Signed-off-by: William Tu
---
v2->v3
http://openvswitch.org/pipermail/dev/2016-July/074288.html
- Update NEWS and ovs-ofctl
- Make snaplen default UINT16_MAX
- Fix encode_SAMPLE() and format_SAMPLE()
- Prevent user from se
6,9 @@ struct nln {
> };
>
> struct nln_notifier {
> +struct ovs_list node;
> struct nln *nln; /* Parent nln. */
>
> -struct ovs_list node;
> int multicast_group; /* Multicast group we listen on. */
> nln_notify_func *cb;
>
Hi Ben,
Thanks, I tested your patch below and clang no longer reports no error.
Regards,
William
> A port is guaranteed to have at least one interface, so 'iface' can't be
> null here. Even if it could, this patch wouldn't help because a few
> lines down there's an unconditional dereference.
>
oh, I forgot to add the new file to EXTRA_DIST. Thanks for fixing it!
On Sun, Jul 3, 2016 at 10:28 AM, Ben Pfaff wrote:
> On Wed, Jun 29, 2016 at 10:35:00AM -0700, William Tu wrote:
>> Add FreeBSD 10.2 vagrant file "Vagrantfile-FreeBSD". Users can run
>> 'VAGRANT_V
d.
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/141704344
Signed-off-by: William Tu
---
v1->v2
http://openvswitch.org/pipermail/dev/2016-June/072404.html
- Add snaplen to nx_action_sample2
- Since truncate then userspace action is supported in userspace datapath,
,commit aaca
We generally try to keep the testsuite independent of the underlying
datapath. This patch removes the datapath-specific tests and macros.
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/141642065
Signed-off-by: William Tu
---
tests/system-kmod-macros.at | 7 ---
tests
Hi Darrell,
Thanks, I think we should print the error in VLOG_WARN and free it .
Regards,
William
On Wed, Jun 29, 2016 at 10:08 AM, Darrell Ball wrote:
>
>
> On Tue, Jun 28, 2016 at 10:02 PM, William Tu wrote:
>>
>> Variable 'error' has been free in line 1795.
liamtu/ovs-travis/builds/141186839
Signed-off-by: William Tu
---
v2->v3
- fix min and max number in schema
http://openvswitch.org/pipermail/dev/2016-June/072630.html
v1->v2
- use UINT16_MAX instead of (uint16_t) - 1
http://openvswitch.org/pipermail/dev/2016-June/072297.html
---
ofpr
tch APIs can be used in providers. With batch metadata visible in
providers, optimizations can be introduced at per-batch level instead
of per-packet.
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/141178364
Signed-off-by: William Tu
--
v2->v3:
- fix freebsd build issue
v1-
Add FreeBSD 10.2 vagrant file "Vagrantfile-FreeBSD". Users can run
'VAGRANT_VAGRANTFILE=Vagrantfile-FreeBSD vagrant up' to test basic
OVS configure, build, and check.
Signed-off-by: William Tu
---
Vagrantfile-FreeBSD | 49 +
Clang reports variable 'error' never been used. Fix by
returning error when table_update->type != JSON_OBJECT.
Signed-off-by: William Tu
---
ovsdb/replication.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/ovsdb/replication.c b/ovsdb/replication.c
index 3d1bc33..a5f94da
Variable 'error' has been free in line 1795.
Signed-off-by: William Tu
---
ovn/utilities/ovn-nbctl.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/ovn/utilities/ovn-nbctl.c b/ovn/utilities/ovn-nbctl.c
index 345647a..3228a03 100644
--- a/ovn/utilities/ovn-nbctl.c
+++ b/ovn/uti
In packet_set_tcp_port(), clang reports passing null pointer of &th->tcp_src
when calling packet_set_port(&th->tcp_src, src, &th->tcp_csum);
Signed-off-by: William Tu
---
lib/packets.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/packets.c
Signed-off-by: William Tu
---
ovn/controller-vtep/ovn-controller-vtep.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/ovn/controller-vtep/ovn-controller-vtep.c
b/ovn/controller-vtep/ovn-controller-vtep.c
index bad3316..36005ed 100644
--- a/ovn/controller-vtep/ovn-controller-vtep.c
+++ b
In nl_msg_push_flag(), the 3rd NULL parameter causing 'memcpy()'
with NULL source pointer in nl_msg_push_unspec().
Signed-off-by: William Tu
---
lib/netlink.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/netlink.c b/lib/netlink.c
index 5d8a147..fbdb78e 10
mory Error
Memory leak 1
Use-after-free 5
William Tu (7):
bridge: Fix possible null pointer dereference reported by clang.
clang: Fix dead assignment.
netlink: Fix passing null pointer reported by clang.
ovn-controller-vtep: Fix dead increment reported by clang.
ovn-nbctl:
Signed-off-by: William Tu
---
lib/dpif-netdev.c | 1 -
tests/test-ovsdb.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c
index ff4227c..37c2631 100644
--- a/lib/dpif-netdev.c
+++ b/lib/dpif-netdev.c
@@ -2842,7 +2842,6
Signed-off-by: William Tu
---
vswitchd/bridge.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/vswitchd/bridge.c b/vswitchd/bridge.c
index 8ebfc66..7244e11 100644
--- a/vswitchd/bridge.c
+++ b/vswitchd/bridge.c
@@ -1999,7 +1999,7 @@ find_local_hw_addr(const struct bridge *br
Thanks, some of my testcases use netcat.
Tested-by: William Tu
On Tue, Jun 28, 2016 at 2:23 AM, Joe Stringer wrote:
> netcat is used in several tests, but when creating a new vagrant VM we
> haven't been installing it. Do so.
>
> Signed-off-by: Joe Stringer
> ---
>
This is pretty cool. I tested it and have some comments.
On Mon, Jun 27, 2016 at 9:11 AM, Bhanuprakash Bodireddy
wrote:
> Clang Static Analyzer is a source code analysis tool to find bugs. This
> patch adds make target to trigger static analysis using below commands.
>
> ./boot.sh
> ./configure -
Hi Darrell,
Thanks for you feedback!
On Sun, Jun 26, 2016 at 8:02 PM, Darrell Ball wrote:
>
>
> On Sat, Jun 25, 2016 at 7:44 AM, William Tu wrote:
>>
>> Commit 1895cc8dbb64 ("dpif-netdev: create batch object") introduces
>> batch process functions and '
Thanks, the patch solves the valgrind error.
Acked-by: William Tu
On Sun, Jun 26, 2016 at 2:54 PM, Ben Pfaff wrote:
> Otherwise IPFIX statistics leak memory from ovs-vswitchd.
>
> Reported-by: William Tu
> Reported-at: http://openvswitch.org/pipermail/dev/2016-June/073769.html
>
Hi,
Valgrind reports the error below on
# make check-valgrind TESTSUITEFLAGS='1055'
Testcase 1055: ofproto-dpif - Bridge IPFIX statistics check
I'm not sure if it's a false positive or not, it looks like the memory
is allocated by bridge level IPFIX test but error is triggerred from
flow stat req
Looks good to me.
Acked-by: William Tu
On Fri, Jun 24, 2016 at 9:23 PM, Ben Pfaff wrote:
> It's a pretty common pattern so create a function for it.
>
> Signed-off-by: Ben Pfaff
> ---
> lib/dpif-netdev.c| 6 ++
> lib/jsonrpc.c| 2
Thadeu Lima de Souza Cascardo
wrote:
> On Mon, Jun 20, 2016 at 07:32:52AM -0700, William Tu wrote:
>> Testcase 2050, ovn -- 3 HVs, 1 LS, 3 lports/HV, reports possible leak:
>> nln_notifier_create (netlink-notifier.c:131)
>> name_table_init (route-table.c:
tch APIs can be used in providers. With batch metadata visible in
providers, optimizations can be introduced at per-batch level instead
of per-packet.
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/140135888
Signed-off-by: William Tu
--
v1->v2: make commit message more descr
oop into each packet and check.
Regards,
William
On Fri, Jun 24, 2016 at 10:35 PM, Ben Pfaff wrote:
> On Fri, Jun 24, 2016 at 04:11:47PM -0700, William Tu wrote:
>> This patch applies the packet batch object to the netdev providers,
>> including dummy, Linux, BSD, and DPDK.
This patch applies the packet batch object to the netdev providers,
including dummy, Linux, BSD, and DPDK.
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/140135888
Signed-off-by: William Tu
---
lib/netdev-bsd.c | 9 --
lib/netdev-dpdk.c | 81
Upstream commit:
commit b95e5928fcc76d156352570858abdea7b2628efd
Author: William Tu
Date: Mon Jun 20 07:26:17 2016 -0700
The commit f2a4d086ed4c ("openvswitch: Add packet truncation support.")
introduces packet truncation before sending to userspace upcal
Hi Wenyu,
I was debugging a little bit and the issue is a NULL pointer deference
of be_cfg at virtual_obs_id = smap_get(&be_cfg->other_config,
"virtual_obs_id");
Maybe adding if (valid_be_cfg) check before the deference? I will
leave you to fix it. Also I hope you can add a test case to this ca
en=100),output:1,output:2'
- The Datapath actions shows:
# Datapath actions: trunc(100),1,1,2
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/140037134
Signed-off-by: William Tu
---
NEWS | 4 +
include/openvswitch/ofp-actions.h | 10 ++
lib/dp-pa
o be any OFPUTIL_NAMED_PORTS.
- Add more testcases.
v1
- Reuse max_len in OpenFlow output controller action.
William Tu (2):
datapath:backport: openvswitch: Add packet truncation support.
ofp-actions: Add truncate action.
NEWS
Upstream commit:
commit f2a4d086ed4c588d32fe9b7aa67fead7280e7bf1
Author: William Tu
Date: Fri Jun 10 11:49:33 2016 -0700
openvswitch: Add packet truncation support.
The patch adds a new OVS action, OVS_ACTION_ATTR_TRUNC, in order to
truncate packets. A 'max_le
Thanks, I will update and resubmit.
On Thu, Jun 23, 2016 at 3:28 PM, pravin shelar wrote:
> On Wed, Jun 22, 2016 at 10:02 PM, William Tu wrote:
>> The patch adds a new action to support packet truncation. The new action
>> is formatted as 'output(port=n,max_len=m)',
en=100),output:1,output:2'
- The Datapath actions shows:
# Datapath actions: trunc(100),1,1,2
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/139668398
Signed-off-by: William Tu
---
include/openvswitch/ofp-actions.h | 10 ++
lib/dp-packet.c | 2 +
lib/dp-pa
max_len in OpenFlow output action.
William Tu (2):
datapath:backport: openvswitch: Add packet truncation support.
ofp-actions: Add truncate action.
datapath/actions.c| 40 +++-
datapath/datapath.c | 29 +--
datapath/datapath.h
Upstream commit:
commit f2a4d086ed4c588d32fe9b7aa67fead7280e7bf1
Author: William Tu
Date: Fri Jun 10 11:49:33 2016 -0700
openvswitch: Add packet truncation support.
The patch adds a new OVS action, OVS_ACTION_ATTR_TRUNC, in order to
truncate packets. A 'max_le
d truncate support for tunnel push and pop.
- Fix clang error.
- Use pskb_trim instead of skb_trim.
- Fallback to userspace truncate action when the
openvswitch kernel module does not support.
- Disallow truncate port to be any OFPUTIL_NAMED_PORTS.
- Add more testcases.
v1
- Reuse max_len in O
Upstream commit:
commit f2a4d086ed4c588d32fe9b7aa67fead7280e7bf1
Author: William Tu
Date: Fri Jun 10 11:49:33 2016 -0700
openvswitch: Add packet truncation support.
The patch adds a new OVS action, OVS_ACTION_ATTR_TRUNC, in order to
truncate packets. A 'max_le
en=100),output:1,output:2'
- The Datapath actions shows:
# Datapath actions: trunc(100),1,1,2
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/139597225
Signed-off-by: William Tu
---
include/openvswitch/ofp-actions.h | 10 ++
lib/dp-packet.c | 2 +
lib/dp-pa
Hi Pravin,
Thanks for the feedback.
>> @@ -4084,10 +4089,13 @@ dp_execute_cb(void *aux_, struct dp_packet_batch
>> *packets_,
>> int i;
>>
>> if (!may_steal) {
>> - dp_packet_batch_clone(&tnl_pkt, packets_);
>> - packets_ = &t
38910851
Signed-off-by: William Tu
---
lib/route-table.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/lib/route-table.c b/lib/route-table.c
index 58e7f62..cf01c34 100644
--- a/lib/route-table.c
+++ b/lib/route-table.c
@@ -316,6 +316,7 @@ route_table_fallback_lookup(const struct in
en=100),output:1,output:2'
- The Datapath actions shows:
# Datapath actions: trunc(100),1,1,2
Signed-off-by: William Tu
---
include/openvswitch/ofp-actions.h | 10 +++
lib/dp-packet.c | 2 +
lib/dp-packet.h | 67 +++
lib/dpif-netdev.c
e action when the
openvswitch kernel module does not support.
- Disallow truncate port to be any OFPUTIL_NAMED_PORTS.
- Add more testcases.
v1
- Reuse max_len in OpenFlow output action.
William Tu (2):
datapath:backport: openvswitch: Add packet truncation support.
ofp-actions: Add trunca
Upstream commit:
commit f2a4d086ed4c588d32fe9b7aa67fead7280e7bf1
Author: William Tu
Date: Fri Jun 10 11:49:33 2016 -0700
openvswitch: Add packet truncation support.
The patch adds a new OVS action, OVS_ACTION_ATTR_TRUNC, in order to
truncate packets. A 'max_le
Hi Pravin,
Thanks for the feedback, I've submitted another version to address these.
Regards,
William
On Fri, Jun 17, 2016 at 10:56 AM, pravin shelar wrote:
> On Tue, Jun 14, 2016 at 4:42 PM, William Tu wrote:
>> The patch adds a new action to support packet truncation. The ne
en=100),output:1,output:2'
- The Datapath actions shows:
# Datapath actions: trunc(100),1,1,2
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/138596207
Signed-off-by: William Tu
Cc: Pravin Shelar
---
include/openvswitch/ofp-actions.h | 10 +++
lib/dp-packet.c
Upstream commit:
commit f2a4d086ed4c588d32fe9b7aa67fead7280e7bf1
Author: William Tu
Date: Fri Jun 10 11:49:33 2016 -0700
openvswitch: Add packet truncation support.
The patch adds a new OVS action, OVS_ACTION_ATTR_TRUNC, in order to
truncate packets. A 'max_le
ORTS.
- Add more testcases.
v1
- Reuse max_len in OpenFlow output action.
William Tu (2):
datapath:backport: openvswitch: Add packet truncation support.
ofp-actions: Add truncate action.
datapath/actions.c| 40 +-
datapath/datapath.c
en=100),output:1,output:2'
- The Datapath actions shows:
# Datapath actions: trunc(100),1,1,2
Tested-at: https://travis-ci.org/williamtu/ovs-travis/builds/137660394
Signed-off-by: William Tu
Cc: Pravin Shelar
---
include/openvswitch/ofp-actions.h | 10 +++
lib/dp-packet.c
oes not support.
- Disallow truncate port to be any OFPUTIL_NAMED_PORTS.
- Add more testcases.
v1
- Reuse max_len in OpenFlow output action.
William Tu (2):
datapath:backport: openvswitch: Add packet truncation support.
ofp-actions: Add truncate action.
datapath/actions.c
Upstream commit:
commit f2a4d086ed4c588d32fe9b7aa67fead7280e7bf1
Author: William Tu
Date: Fri Jun 10 11:49:33 2016 -0700
openvswitch: Add packet truncation support.
The patch adds a new OVS action, OVS_ACTION_ATTR_TRUNC, in order to
truncate packets. A 'max_le
Looks good to me.
Acked-by: William Tu
On Mon, Jun 13, 2016 at 8:09 PM, Benli Ye wrote:
> 'last_template_set_time' in truct dpif_ipfix_exporter is declared
> as time_t and time_t is long int type. If we initialize
> 'last_template_set_time' as TIME_MIN, whose val
Acked-by: William Tu
I think it fixes the issue, although the root cause is that we are
1) Comparing signed int (last_template_set_time) and unsigned int
(export_time_sec). From the C99, the operand with signed integer type
is converted to the type of the operand with unsigned integer type, so
;look weird"?
>
> On Thu, Jun 09, 2016 at 10:20:31PM -0700, William Tu wrote:
>> Hi Ben,
>>
>> Because for sFlow, it doesn't have any benefit to do
>> "sample(truncate(n), userspace(...))" in userspace datapath. I tried
>> to implement it by tru
>> I understand that's what userspace does. What about in the datapath?
>> Do the datapaths properly handle it if userspace adds a flow that does
>> "truncate, pop_vlan, ..., output"? The kernel datapath, in particular,
>> should be able to handle malicious or buggy userspace.
>>
>
> There is che
other use case so I let sFlow translates differently for kernel
and userspace dp.
Regards,
William
On Thu, Jun 9, 2016 at 8:16 PM, Ben Pfaff wrote:
> On Thu, Jun 09, 2016 at 06:06:47PM -0700, William Tu wrote:
>> > I'm not sure why CHECK_TRUNC_USERSPACE exists, because I thin
Hi Ryan,
Thanks for the review. I looked at the jsonrpc-server.c and I think
it's OK without leaks.
Regards,
William
On Wed, Jun 8, 2016 at 7:32 PM, Ryan Moats wrote:
> "dev" wrote on 06/05/2016 09:37:35 AM:
>
>> From: William Tu
>> To: dev@openvswitch
Hi Ben,
Thanks for the review.
> This changes the "wire format" of the NXAST_SAMPLE action, but we can't
> do that because it will break compatibility with older OpenFlow clients.
> Usually if we need a new feature in an action we add a new version that
> has that feature, e.g. NXAST_SAMPLE2. The
Hi Ben,
Thanks for the feedback.
>> Signed-off-by: William Tu
>
> I'm a bit nervous about cutlen. Can a packet change, for example by
> popping a VLAN header, after cutlen is set? If so, can this cause the
> packet length to drop below 0, or below 14?
>
I don'
This patch adds a 'snaplen' config for mirroring table. A mirrored packet
with size larger than snaplen bytes will be truncated in datapath before
sending to the mirror output port. A snaplen of 0 equals 65535, which means
no truncation applied.
Signed-off-by: William Tu
---
ofpro
en=100),output:1,output:2'
- The Datapath actions shows:
# Datapath actions: trunc(100),1,1,2
Signed-off-by: William Tu
---
datapath/actions.c| 36 -
datapath/datapath.c | 25 +++-
datapath/datapath.h
path.
Thus, only N bytes instead of full-packet size will be copied from kernel
to userspace, saving the copying overhead.
Signed-off-by: William Tu
---
include/openvswitch/ofp-actions.h | 1 +
lib/ofp-actions.c | 10 -
ofproto/ofproto-dpif-sflow.c | 19 ++--
im.
- Fallback to userspace truncate action when the
openvswitch kernel module does not support.
- Disallow truncate port to be any OFPUTIL_NAMED_PORTS.
- Add more testcases.
v2: https://patchwork.ozlabs.org/patch/605082/
William Tu (3):
ofp-actions: Add truncate action.
ofproto-dpif-sflow: Add
ession_open (jsonrpc.c:784)
ovsdb_idl_create (ovsdb-idl.c:246)
main (ovn-controller.c:384)
and,
xmalloc (util.c:112)
jsonrpc_session_open (jsonrpc.c:784)
ovsdb_idl_set_remote (ovsdb-idl.c:289)
main (ovn-controller.c:409)
Signed-off-by: William Tu
---
lib/ovsdb-idl.c | 3 +++
1
len=)" is supported. Output to any
OFPUTIL_NAMED_PORTS or patch port are not supported.
- Compatibility: If the openvswitch kernel module does not support
OVS_ACTION_ATTR_TRUNC, it falls back to userspace slow path, do the
packet truncation and send to the output port
tion patch:
https://patchwork.ozlabs.org/patch/626486/
Signed-off-by: William Tu
---
ofproto/ofproto-dpif-mirror.c | 9 +-
ofproto/ofproto-dpif-mirror.h | 4 +-
ofproto/ofproto-dpif-xlate.c | 27 -
ofproto/ofproto-dpif.c| 2 +-
ofproto/ofproto.h | 2 +
tests/ofpro
len=)" is supported. Output to any
OFPUTIL_NAMED_PORTS are not supported.
- Compatibility: If the openvswitch kernel module does not support
OVS_ACTION_ATTR_TRUNC, it falls back to userspace slow path, do the
packet truncation and send to the output port.
Signed-o
Reported-by: William Tu
> Signed-off-by: Daniele Di Proietto
> ---
> lib/dpif-netdev.c | 5 +
> 1 file changed, 5 insertions(+)
>
> diff --git a/lib/dpif-netdev.c b/lib/dpif-netdev.c
> index 33fd228..76a8c6b 100644
> --- a/lib/dpif-netdev.c
> +++ b/lib/dpif-net
nowing that this pipeline adds 4B more, so it translates to datapath
as truncate(104) instead of truncate(100). If the next coming packet with
1500B hit the datapath flow, it will also truncate to 104B.
Regards,
William
On Wed, May 4, 2016 at 11:00 AM, William Tu wrote:
> The patch proposes
Hi Daniele,
Thanks! this saves a lot of time to reproduce the error.
The new testcase can exercise the code path correctly to reproduce the
error, and after applying the 4 patches the error at " 2032: ovn.at:1230
ovn -- 3 HVs, 3 LS, 3 lports/LS, 1 LR" is resolved.
The ukey issue also disappears.
1 - 100 of 249 matches
Mail list logo