Re: [PATCH 1/1] openvswitch: fix infoleak in conntrack

2020-06-16 Thread Pravin Shelar
On Mon, Jun 15, 2020 at 7:13 PM Xidong Wang wrote: > > From: xidongwang > > The stack object “zone_limit” has 3 members. In function > ovs_ct_limit_get_default_limit(), the member "count" is > not initialized and sent out via “nla_put_nohdr”. > > Signed-off-by: xidongwang Looks good. Acked-by:

Re: [PATCH] net: openvswitch: free vport unless register_netdevice() succeeds

2019-08-10 Thread Pravin Shelar
On Thu, Aug 8, 2019 at 8:55 PM Hillf Danton wrote: > > > syzbot found the following crash on: > > HEAD commit:1e78030e Merge tag 'mmc-v5.3-rc1' of git://git.kernel.org/.. > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=148d3d1a60 > kernel config: htt

Re: memory leak in internal_dev_create

2019-08-07 Thread Pravin Shelar
On Tue, Aug 6, 2019 at 5:00 AM Hillf Danton wrote: > > > On Tue, 06 Aug 2019 01:58:05 -0700 > > Hello, > > > > syzbot found the following crash on: > > ... > > BUG: memory leak > > unreferenced object 0x8881228ca500 (size 128): > >comm "syz-executor032", pid 7015, jiffies 4294944622 (age

Re: [ovs-dev] [PATCH 7/8] net: ovs: remove unused hardirq.h

2017-12-07 Thread Pravin Shelar
On Fri, Nov 17, 2017 at 3:02 PM, Yang Shi wrote: > Preempt counter APIs have been split out, currently, hardirq.h just > includes irq_enter/exit APIs which are not used by openvswitch at all. > > So, remove the unused hardirq.h. > > Signed-off-by: Yang Shi > Cc: Pravin S

Re: [PATCH] openvswitch: use ktime_get_ts64() instead of ktime_get_ts()

2017-11-27 Thread Pravin Shelar
On Mon, Nov 27, 2017 at 5:11 PM, Arnd Bergmann wrote: > timespec is deprecated because of the y2038 overflow, so let's convert > this one to ktime_get_ts64(). The code is already safe even on 32-bit > architectures, since it uses monotonic times. On 64-bit architectures, > nothing changes, while o

Re: [ovs-dev] [PATCH] openvswitch: add null pointer check on upcall

2017-11-09 Thread Pravin Shelar
On Thu, Nov 9, 2017 at 7:29 PM, Colin King wrote: > From: Colin Ian King > > upcall may be assigned a NULL pointer as genlmsg_put can potentially > return a NULL. Add a null check to avoid a null pointer dereference > on upcall. > > Detected by CoverityScan, CID#728404 ("Dereference null return

Re: [PATCH v2] geneve: Fix setting ttl value in collect metadata mode

2017-09-13 Thread Pravin Shelar
On Wed, Sep 13, 2017 at 4:15 AM, 严海双 wrote: > > >> On 2017年9月13日, at 上午7:43, Pravin Shelar wrote: >> >> On Tue, Sep 12, 2017 at 12:05 AM, Haishuang Yan >> wrote: >>> Similar to vxlan/ipip tunnel, if key->tos is zero in collect metadata >>> mod

Re: [PATCH v2] geneve: Fix setting ttl value in collect metadata mode

2017-09-12 Thread Pravin Shelar
On Tue, Sep 12, 2017 at 12:05 AM, Haishuang Yan wrote: > Similar to vxlan/ipip tunnel, if key->tos is zero in collect metadata > mode, tos should also fallback to ip{4,6}_dst_hoplimit. > > Signed-off-by: Haishuang Yan > > --- > Changes since v2: > * Make the commit message more clearer. > --- >

Re: [PATCH v4 1/2] ip_tunnel: fix ip tunnel lookup in collect_md mode

2017-09-12 Thread Pravin Shelar
On Tue, Sep 12, 2017 at 2:47 AM, Haishuang Yan wrote: > In collect_md mode, if the tun dev is down, it still can call > ip_tunnel_rcv to receive on packets, and the rx statistics increase > improperly. > > When the md tunnel is down, it's not neccessary to increase RX drops > for the tunnel device

Re: [PATCH v2] openvswitch: Fix an error handling path in 'ovs_nla_init_match_and_action()'

2017-09-11 Thread Pravin Shelar
On Mon, Sep 11, 2017 at 12:56 PM, Christophe JAILLET wrote: > All other error handling paths in this function go through the 'error' > label. This one should do the same. > > Fixes: 9cc9a5cb176c ("datapath: Avoid using stack larger than 1024.") > Signed-off-by: Christophe JAILLET > --- > I think

Re: [PATCH] geneve: Fix setting ttl value in collect metadata mode

2017-09-04 Thread Pravin Shelar
On Sun, Sep 3, 2017 at 5:49 AM, Haishuang Yan wrote: > If key->tos is zero in collect metadata mode, tos should fallback to > ip{4,6}_dst_hoplimit, same as normal mode. > > Signed-off-by: Haishuang Yan > --- > drivers/net/geneve.c | 6 ++ > 1 file changed, 2 insertions(+), 4 deletions(-) > >

Re: [PATCH v2 1/2] ip_tunnel: fix ip tunnel lookup in collect_md mode

2017-06-19 Thread Pravin Shelar
On Mon, Jun 19, 2017 at 6:13 AM, 严海双 wrote: > > >> On 19 Jun 2017, at 1:43 PM, Pravin Shelar wrote: >> >> On Fri, Jun 16, 2017 at 8:27 PM, Haishuang Yan >> wrote: >>> In collect_md mode, if the tun dev is down, it still can call >>> ip_tunnel_

Re: [PATCH v2 1/2] ip_tunnel: fix ip tunnel lookup in collect_md mode

2017-06-18 Thread Pravin Shelar
On Fri, Jun 16, 2017 at 8:27 PM, Haishuang Yan wrote: > In collect_md mode, if the tun dev is down, it still can call > ip_tunnel_rcv to receive on packets, and the rx statistics increase > improperly. > > Fixes: 2e15ea390e6f ("ip_gre: Add support to collect tunnel metadata.") > Cc: Pravin B Shela

Re: [PATCH v3 1/2] ip_tunnel: fix potential issue in ip_tunnel_rcv

2017-06-08 Thread Pravin Shelar
On Wed, Jun 7, 2017 at 9:32 PM, Haishuang Yan wrote: > When ip_tunnel_rcv fails, the tun_dst won't be freed, so call > dst_release to free it in error code path. > > CC: Pravin B Shelar > Fixes: 2e15ea390e6f ("ip_gre: Add support to collect tunnel metadata.") > Signed-off-by: Haishuang Yan > > -

Re: [PATCH v2 1/2] ip_tunnel: fix potential issue in ip_tunnel_rcv

2017-06-07 Thread Pravin Shelar
On Wed, Jun 7, 2017 at 8:15 PM, Eric Dumazet wrote: > On Wed, 2017-06-07 at 19:13 -0700, Pravin Shelar wrote: >> On Wed, Jun 7, 2017 at 5:57 PM, Haishuang Yan >> wrote: >> > When ip_tunnel_rcv fails, the tun_dst won't be freed, so move >> > skb_dst_set

Re: [PATCH v2 1/2] ip_tunnel: fix potential issue in ip_tunnel_rcv

2017-06-07 Thread Pravin Shelar
On Wed, Jun 7, 2017 at 5:57 PM, Haishuang Yan wrote: > When ip_tunnel_rcv fails, the tun_dst won't be freed, so move > skb_dst_set to begin and tun_dst would be freed by kfree_skb. > > CC: Pravin B Shelar > Fixes: 2e15ea390e6f ("ip_gre: Add support to collect tunnel metadata.") > Signed-off-by: H

Re: [ovs-dev] [PATCH 1/1] openvswitch: check return value of nla_nest_start

2017-04-23 Thread Pravin Shelar
On Sat, Apr 22, 2017 at 11:43 PM, Pan Bian wrote: > Function nla_nest_start() will return a NULL pointer on error, and its > return value should be validated before it is used. However, in function > queue_userspace_packet(), its return value is ignored. This may result > in NULL dereference when

Re: [PATCH] openvswitch: add sanity check in queue_userspace_packet.

2016-11-28 Thread Pravin Shelar
On Mon, Nov 28, 2016 at 8:36 PM, Haishuang Yan wrote: > kernel will crash in oops if genlmsg_put return NULL, > so add the sanity check. > > Signed-off-by: Haishuang Yan > --- > net/openvswitch/datapath.c | 4 > 1 file changed, 4 insertions(+) > > diff --git a/net/openvswitch/datapath.c b/n

Re: [PATCH] geneve: fix ip_hdr_len reserved for geneve6 tunnel.

2016-11-27 Thread Pravin Shelar
On Sun, Nov 27, 2016 at 9:26 PM, Haishuang Yan wrote: > It shold reserved sizeof(ipv6hdr) for geneve in ipv6 tunnel. > > Fixes: c3ef5aa5e5 ('geneve: Merge ipv4 and ipv6 geneve_build_skb()') > > Signed-off-by: Haishuang Yan Thanks for fix. Acked-by: Pravin B Shelar

Re: [PATCH v3] openvswitch: allow management from inside user namespaces

2016-02-11 Thread pravin shelar
e > much appreciated. > > v2: use the GENL_UNS_ADMIN_PERM flag instead of a check in each function > v3: use separate ifs for UNS_ADMIN_PERM and ADMIN_PERM, instead of one > massive one > > Reported-by: James Page > Signed-off-by: Tycho Andersen > CC: Eric Biederman

Re: [PATCH] openvswitch: allow management from inside user namespaces

2016-02-01 Thread pravin shelar
On Fri, Jan 29, 2016 at 8:37 AM, Tycho Andersen wrote: > Hi Eric, > > Thanks for the review. > > On Fri, Jan 29, 2016 at 08:29:55AM -0600, Eric W. Biederman wrote: >> Tycho Andersen writes: >> >> > Operations with the GENL_ADMIN_PERM flag fail permissions checks because >> > this flag means we ca

Re: [PATCH] ip_tunnel: make ip6tunnel_xmit definition conditional

2016-01-01 Thread Pravin Shelar
On Fri, Jan 1, 2016 at 5:48 AM, Arnd Bergmann wrote: > From 433df301cf49624871346fa63f3fc65033caeda3 Mon Sep 17 00:00:00 2001 > From: Arnd Bergmann > Date: Fri, 1 Jan 2016 13:18:48 +0100 > Subject: [PATCH] net: make ip6tunnel_xmit definition conditional > > Moving the caller of iptunnel_xmit_stat

Re: [PATCH] ovs: do not allocate memory from offline numa node

2015-10-02 Thread Pravin Shelar
On Fri, Oct 2, 2015 at 3:18 AM, Konstantin Khlebnikov wrote: > When openvswitch tries allocate memory from offline numa node 0: > stats = kmem_cache_alloc_node(flow_stats_cache, GFP_KERNEL | __GFP_ZERO, 0) > It catches VM_BUG_ON(nid < 0 || nid >= MAX_NUMNODES || !node_online(nid)) > [ replaced wit

Re: [PATCHv2 7/7] openvswitch: Change CT_ATTR_FLAGS to CT_ATTR_COMMIT

2015-10-01 Thread Pravin Shelar
On Thu, Oct 1, 2015 at 1:53 PM, Joe Stringer wrote: > Previously, the CT_ATTR_FLAGS attribute, when nested under the > OVS_ACTION_ATTR_CT, encoded a 32-bit bitmask of flags that modify the > semantics of the ct action. It's more extensible to just represent each > flag as a nested attribute, and t

Re: [PATCHv2 3/7] openvswitch: Fix skb leak in ovs_fragment()

2015-10-01 Thread Pravin Shelar
On Thu, Oct 1, 2015 at 1:53 PM, Joe Stringer wrote: > If ovs_fragment() was unable to fragment the skb due to an L2 header > that exceeds the supported length, skbs would be leaked. Fix the bug. > > Fixes: 7f8a436 "openvswitch: Add conntrack action" > Signed-off-by: Joe Stringer > --- > v2: Drop

Re: [PATCHv3] openvswitch: Rename LABEL->LABELS

2015-10-01 Thread Pravin Shelar
On Thu, Oct 1, 2015 at 3:00 PM, Joe Stringer wrote: > Conntrack LABELS (plural) are exposed by conntrack; rename the OVS name > for these to be consistent with conntrack. > > Fixes: c2ac667 "openvswitch: Allow matching on conntrack label" > Signed-off-by: Joe Stringer > --- > v3: Fix build with !

Re: [PATCH net 5/7] openvswitch: Reject ct_state unsupported bits

2015-09-30 Thread Pravin Shelar
On Wed, Sep 30, 2015 at 6:20 PM, Joe Stringer wrote: > On 30 September 2015 at 17:31, Pravin Shelar wrote: >> On Tue, Sep 29, 2015 at 3:39 PM, Joe Stringer wrote: >>> Previously, if userspace specified ct_state bits in the flow key which >>> are currently undefined

Re: [PATCH net 4/7] openvswitch: Ensure flow is valid before executing ct

2015-09-30 Thread Pravin Shelar
On Tue, Sep 29, 2015 at 3:39 PM, Joe Stringer wrote: > The ct action uses parts of the flow key, so we need to ensure that it > is valid before executing that action. > > Fixes: 7f8a436 "openvswitch: Add conntrack action" > Signed-off-by: Joe Stringer Acked-by: Pravin B Shelar -- To unsubscribe

Re: [PATCH net 6/7] openvswitch: Extend ct_state match field to 32 bits

2015-09-30 Thread Pravin Shelar
On Tue, Sep 29, 2015 at 3:39 PM, Joe Stringer wrote: > The ct_state field was initially added as an 8-bit field, however six of > the bits are already being used and use cases are already starting to > appear that may push the limits of this field. This patch extends the > field to 32 bits while r

Re: [PATCH net 7/7] openvswitch: Change CT_ATTR_FLAGS to CT_ATTR_COMMIT

2015-09-30 Thread Pravin Shelar
On Tue, Sep 29, 2015 at 3:39 PM, Joe Stringer wrote: > Previously, the CT_ATTR_FLAGS attribute, when nested under the > OVS_ACTION_ATTR_CT, encoded a 32-bit bitmask of flags that modify the > semantics of the ct action. It's more extensible to just represent each > flag as a nested attribute, and

Re: [PATCH net 2/7] openvswitch: Fix typos in CT headers

2015-09-30 Thread Pravin Shelar
On Tue, Sep 29, 2015 at 3:39 PM, Joe Stringer wrote: > These comments hadn't caught up to their implementations, fix them. > > Fixes: 7f8a436 "openvswitch: Add conntrack action" > Signed-off-by: Joe Stringer Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe

Re: [PATCH net 5/7] openvswitch: Reject ct_state unsupported bits

2015-09-30 Thread Pravin Shelar
On Tue, Sep 29, 2015 at 3:39 PM, Joe Stringer wrote: > Previously, if userspace specified ct_state bits in the flow key which > are currently undefined (and therefore unsupported), then they would be > ignored. This could cause unexpected behaviour in future if userspace is > extended to support a

Re: [PATCH net 1/7] openvswitch: Make LABELS name more consistent

2015-09-30 Thread Pravin Shelar
On Tue, Sep 29, 2015 at 3:39 PM, Joe Stringer wrote: > Conntrack LABELS (plural) are exposed by conntrack; rename the OVS name > for these to be consistent with conntrack. > > Fixes: c2ac667 "openvswitch: Allow matching on conntrack label" > Signed-off-by: Joe Stringer > --- > include/uapi/linux

Re: [regression] freezing usbip list by commit 6ae459bdaaeebc632

2015-09-30 Thread Pravin Shelar
On Wed, Sep 30, 2015 at 3:18 AM, Igor Kotrasinski wrote: > Commit 6ae459bdaaeebc632 (skbuff: Fix skb checksum flag on skb pull) > introduces a regression when using usbip userspace tools. > Running usbipd and attempting to list remote devices on localhost causes > usbip to freeze. Stopping usbip t

Re: 4.3-rc3 Regression: NFS access stall by commit 6ae459bdaaee

2015-09-29 Thread Pravin Shelar
On Tue, Sep 29, 2015 at 3:33 AM, Takashi Iwai wrote: > On Tue, 29 Sep 2015 02:35:04 +0200, > Pravin Shelar wrote: >> >> On Mon, Sep 28, 2015 at 6:12 AM, Takashi Iwai wrote: >> > [I resent this since the previous mail didn't go out properly, as it >> >

Re: 4.3-rc3 Regression: NFS access stall by commit 6ae459bdaaee

2015-09-28 Thread Pravin Shelar
On Mon, Sep 28, 2015 at 6:12 AM, Takashi Iwai wrote: > [I resent this since the previous mail didn't go out properly, as it > seems; apologies if you already read it, please disregard] > > Hi, > > I noticed that NFS access from my workstation slowed down drastically, > almost stalls, with the fre

Re: 4.3-rc3 Regression: NFS access stall by commit 6ae459bdaaee

2015-09-28 Thread Pravin Shelar
On Mon, Sep 28, 2015 at 6:12 AM, Takashi Iwai wrote: > [I resent this since the previous mail didn't go out properly, as it > seems; apologies if you already read it, please disregard] > > Hi, > > I noticed that NFS access from my workstation slowed down drastically, > almost stalls, with the fre

Re: [PATCH 08/38] openvswitch: fix handling result of ipv6_skip_exthdr

2015-09-21 Thread Pravin Shelar
On Mon, Sep 21, 2015 at 6:33 AM, Andrzej Hajda wrote: > The function can return negative value. > > The problem has been detected using proposed semantic patch > scripts/coccinelle/tests/unsigned_lesser_than_zero.cocci [1]. > > [1]: http://permalink.gmane.org/gmane.linux.kernel/2038576 > > Signed-

Re: [PATCH net] openvswitch: Fix IPv6 exthdr handling with ct helpers.

2015-09-14 Thread Pravin Shelar
On Mon, Sep 14, 2015 at 11:14 AM, Joe Stringer wrote: > Static code analysis reveals the following bug: > > net/openvswitch/conntrack.c:281 ovs_ct_helper() > warn: unsigned 'protoff' is never less than zero. > > This signedness bug breaks error handling for IPv6 extension headers w

Re: [PATCH net] openvswitch: Fix dependency on IPv6 defrag.

2015-09-11 Thread Pravin Shelar
On Fri, Sep 11, 2015 at 3:01 PM, Joe Stringer wrote: > When NF_CONNTRACK is built-in, NF_DEFRAG_IPV6 is a module, and > OPENVSWITCH is built-in, the following build error would occur: > > net/built-in.o: In function `ovs_ct_execute': > (.text+0x10f587): undefined reference to `nf_ct_frag6_gather'

Re: [PATCH net] openvswitch: Remove conntrack Kconfig option.

2015-09-04 Thread Pravin Shelar
On Fri, Sep 4, 2015 at 1:07 PM, Joe Stringer wrote: > There's no particular desire to have conntrack action support in Open > vSwitch as an independently configurable bit, rather just to ensure > there is not a hard dependency. This exposed option doesn't accurately > reflect the conntrack depende

Re: [PATCHv6 net-next 05/10] openvswitch: Add conntrack action

2015-08-26 Thread Pravin Shelar
On Wed, Aug 26, 2015 at 11:31 AM, Joe Stringer wrote: > Expose the kernel connection tracker via OVS. Userspace components can > make use of the CT action to populate the connection state (ct_state) > field for a flow. This state can be subsequently matched. > > Exposed connection states are OVS_C

Re: [PATCHv5 net-next 10/10] openvswitch: Allow attaching helpers to ct action

2015-08-25 Thread Pravin Shelar
On Mon, Aug 24, 2015 at 5:32 PM, Joe Stringer wrote: > Add support for using conntrack helpers to assist protocol detection. > The new OVS_CT_ATTR_HELPER attribute of the CT action specifies a helper > to be used for this connection. If no helper is specified, then helpers > will be automatically

Re: [PATCHv5 net-next 09/10] openvswitch: Allow matching on conntrack label

2015-08-25 Thread Pravin Shelar
On Mon, Aug 24, 2015 at 5:32 PM, Joe Stringer wrote: > Allow matching and setting the ct_label field. As with ct_mark, this is > populated by executing the CT action. The label field may be modified by > specifying a label and mask nested under the CT action. It is stored as > metadata attached to

Re: [PATCHv5 net-next 06/10] openvswitch: Allow matching on conntrack mark

2015-08-25 Thread Pravin Shelar
On Mon, Aug 24, 2015 at 5:32 PM, Joe Stringer wrote: > Allow matching and setting the ct_mark field. As with ct_state and > ct_zone, these fields are populated when the CT action is executed. To > write to this field, a value and mask can be specified as a nested > attribute under the CT action. T

Re: [PATCHv5 net-next 05/10] openvswitch: Add conntrack action

2015-08-25 Thread Pravin Shelar
On Mon, Aug 24, 2015 at 5:32 PM, Joe Stringer wrote: > Expose the kernel connection tracker via OVS. Userspace components can > make use of the CT action to populate the connection state (ct_state) > field for a flow. This state can be subsequently matched. > > Exposed connection states are OVS_CS

Re: [PATCHv5 net-next 03/10] ipv6: Export nf_ct_frag6_gather()

2015-08-25 Thread Pravin Shelar
On Mon, Aug 24, 2015 at 5:32 PM, Joe Stringer wrote: > Signed-off-by: Joe Stringer > Acked-by: Thomas Graf > Acked-by: Pravin B Shelar When I apply this patch I see empty commit msg. I think you need to add atleast a blank line after the subject. > --- > v4: Add ack. > v5: No change. > --- >

Re: [PATCHv4 net-next 10/10] openvswitch: Allow attaching helpers to ct action

2015-08-21 Thread Pravin Shelar
On Thu, Aug 20, 2015 at 5:47 PM, Joe Stringer wrote: > On 19 August 2015 at 15:57, Pravin Shelar wrote: >> On Tue, Aug 18, 2015 at 4:39 PM, Joe Stringer wrote: >>> Add support for using conntrack helpers to assist protocol detection. >>> The new OVS_CT_ATTR_HELPER

Re: [PATCHv4 net-next 09/10] openvswitch: Allow matching on conntrack label

2015-08-20 Thread Pravin Shelar
On Thu, Aug 20, 2015 at 12:13 PM, Joe Stringer wrote: > On 20 August 2015 at 08:45, Pravin Shelar wrote: >> On Wed, Aug 19, 2015 at 4:04 PM, Joe Stringer wrote: >>> Thanks for the review, >>> >>> On 19 August 2015 at 14:24, Pravin Shelar wrote: >&

Re: [PATCHv4 net-next 09/10] openvswitch: Allow matching on conntrack label

2015-08-20 Thread Pravin Shelar
On Wed, Aug 19, 2015 at 4:04 PM, Joe Stringer wrote: > Thanks for the review, > > On 19 August 2015 at 14:24, Pravin Shelar wrote: >> On Tue, Aug 18, 2015 at 4:39 PM, Joe Stringer wrote: >>> Allow matching and setting the conntrack label field. As with ct_mark,

Re: [PATCHv4 net-next 10/10] openvswitch: Allow attaching helpers to ct action

2015-08-19 Thread Pravin Shelar
On Tue, Aug 18, 2015 at 4:39 PM, Joe Stringer wrote: > Add support for using conntrack helpers to assist protocol detection. > The new OVS_CT_ATTR_HELPER attribute of the ct action specifies a helper > to be used for this connection. > > Example ODP flows allowing FTP connections from ports 1->2:

Re: [PATCHv4 net-next 09/10] openvswitch: Allow matching on conntrack label

2015-08-19 Thread Pravin Shelar
On Tue, Aug 18, 2015 at 4:39 PM, Joe Stringer wrote: > Allow matching and setting the conntrack label field. As with ct_mark, > this is populated by executing the CT action, and is a writable field. > Specifying a label and optional mask allows the label to be modified, > which takes effect on the

Re: [PATCHv4 net-next 08/10] netfilter: connlabels: Export setting connlabel length

2015-08-19 Thread Pravin Shelar
On Tue, Aug 18, 2015 at 4:39 PM, Joe Stringer wrote: > Add functions to change connlabel length into nf_conntrack_labels.c so > they may be reused by other modules like OVS and nftables without > needing to jump through xt_match_check() hoops. > > Suggested-by: Florian Westphal > Signed-off-by: J

Re: [PATCHv4 net-next 07/10] netfilter: Always export nf_connlabels_replace()

2015-08-19 Thread Pravin Shelar
On Tue, Aug 18, 2015 at 4:39 PM, Joe Stringer wrote: > The following patches will reuse this code from OVS. > > Signed-off-by: Joe Stringer Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org M

Re: [PATCHv4 net-next 06/10] openvswitch: Allow matching on conntrack mark

2015-08-19 Thread Pravin Shelar
On Tue, Aug 18, 2015 at 4:39 PM, Joe Stringer wrote: > Allow matching and setting the conntrack mark field. As with conntrack > state and zone, these are populated when the CT action is executed, > and are made available for matching via RECIRC. To write to this field, > a value and optional mark

Re: [PATCHv4 net-next 05/10] openvswitch: Add conntrack action

2015-08-19 Thread Pravin Shelar
On Tue, Aug 18, 2015 at 4:39 PM, Joe Stringer wrote: > Expose the kernel connection tracker via OVS. Userspace components can > make use of the "ct()" action, followed by "recirculate", to populate > the conntracking state in the OVS flow key, and subsequently match on > that state. > > Example OD

Re: [Patch V3 4/9] openvswitch: Replace cpu_to_node() with cpu_to_mem() to support memoryless node

2015-08-17 Thread Pravin Shelar
On Sun, Aug 16, 2015 at 8:19 PM, Jiang Liu wrote: > Function ovs_flow_stats_update() allocates memory with __GFP_THISNODE > flag set, which may cause permanent memory allocation failure on > memoryless node. So replace cpu_to_node() with cpu_to_mem() to better > support memoryless node. For node w

Re: [PATCHv3 net-next 06/10] openvswitch: Allow matching on conntrack mark

2015-08-13 Thread Pravin Shelar
On Wed, Aug 12, 2015 at 4:41 PM, Joe Stringer wrote: > On 12 August 2015 at 16:00, Pravin Shelar wrote: >> On Tue, Aug 11, 2015 at 3:59 PM, Joe Stringer wrote: >>> From: Justin Pettit >>> >>> Allow matching and setting the conntrack mark field. As with con

Re: [PATCHv3 net-next 06/10] openvswitch: Allow matching on conntrack mark

2015-08-12 Thread Pravin Shelar
On Tue, Aug 11, 2015 at 3:59 PM, Joe Stringer wrote: > From: Justin Pettit > > Allow matching and setting the conntrack mark field. As with conntrack > state and zone, these are populated by executing the ct() action. Unlike > these, the ct_mark is also a writable field. The set_field() action ma

Re: [PATCHv3 net-next 05/10] openvswitch: Add conntrack action

2015-08-12 Thread Pravin Shelar
On Tue, Aug 11, 2015 at 3:59 PM, Joe Stringer wrote: > Expose the kernel connection tracker via OVS. Userspace components can > make use of the "ct()" action, followed by "recirculate", to populate > the conntracking state in the OVS flow key, and subsequently match on > that state. > > Example OD

Re: [PATCHv3 net-next 04/10] dst: Add __skb_dst_copy() variation

2015-08-12 Thread Pravin Shelar
On Tue, Aug 11, 2015 at 3:59 PM, Joe Stringer wrote: > This variation on skb_dst_copy() doesn't require two skbs. > > Signed-off-by: Joe Stringer Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kern

Re: [PATCHv3 net-next 03/10] ipv6: Export nf_ct_frag6_gather()

2015-08-12 Thread Pravin Shelar
On Tue, Aug 11, 2015 at 3:59 PM, Joe Stringer wrote: > Signed-off-by: Joe Stringer > Acked-by: Thomas Graf Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://v

Re: [PATCHv3 net-next 02/10] openvswitch: Move MASKED* macros to datapath.h

2015-08-12 Thread Pravin Shelar
On Tue, Aug 11, 2015 at 3:59 PM, Joe Stringer wrote: > This will allow the ovs-conntrack code to reuse these macros. > > Signed-off-by: Joe Stringer > Acked-by: Thomas Graf Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a mes

Re: [PATCHv3 net-next 01/10] openvswitch: Serialize acts with original netlink len

2015-08-12 Thread Pravin Shelar
On Tue, Aug 11, 2015 at 3:59 PM, Joe Stringer wrote: > Previously, we used the kernel-internal netlink actions length to > calculate the size of messages to serialize back to userspace. > However,the sw_flow_actions may not be formatted exactly the same as the > actions on the wire, so store the o

Re: [PATCHv2 net-next 5/9] openvswitch: Add conntrack action

2015-08-06 Thread Pravin Shelar
On Thu, Aug 6, 2015 at 11:07 AM, Joe Stringer wrote: > On 5 August 2015 at 15:31, Pravin Shelar wrote: >> On Tue, Aug 4, 2015 at 9:49 PM, Joe Stringer wrote: >> I got sparse warning: >> >> net/openvswitch/actions.c:634:1: warning: symbol 'ovs_dst_get_mtu&#x

Re: [PATCHv2 net-next 5/9] openvswitch: Add conntrack action

2015-08-05 Thread Pravin Shelar
On Tue, Aug 4, 2015 at 9:49 PM, Joe Stringer wrote: > Expose the kernel connection tracker via OVS. Userspace components can > make use of the "ct()" action, followed by "recirculate", to populate > the conntracking state in the OVS flow key, and subsequently match on > that state. > > Example ODP

Re: [PATCHv2 net-next 2/9] openvswitch: Move MASKED* macros to datapath.h

2015-08-05 Thread Pravin Shelar
On Tue, Aug 4, 2015 at 9:49 PM, Joe Stringer wrote: > This will allow the ovs-conntrack code to reuse these macros. > > Signed-off-by: Joe Stringer > Acked-by: Thomas Graf Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a mess

Re: [PATCHv2 net-next 3/9] ipv6: Export nf_ct_frag6_gather()

2015-08-05 Thread Pravin Shelar
On Tue, Aug 4, 2015 at 9:49 PM, Joe Stringer wrote: > Signed-off-by: Joe Stringer > Acked-by: Thomas Graf > --- Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http

Re: [PATCHv2 net-next 1/9] openvswitch: Serialize acts with original netlink len

2015-08-05 Thread Pravin Shelar
On Tue, Aug 4, 2015 at 9:49 PM, Joe Stringer wrote: > Previously, we used the kernel-internal netlink actions length to > calculate the size of messages to serialize back to userspace. > However,the sw_flow_actions may not be formatted exactly the same as the > actions on the wire, so store the or

Re: [PATCH v2] openvswitch: Fix L4 checksum handling when dealing with IP fragments

2015-08-03 Thread Pravin Shelar
On Mon, Aug 3, 2015 at 9:56 AM, Glenn Griffin wrote: > openvswitch modifies the L4 checksum of a packet when modifying > the ip address. When an IP packet is fragmented only the first > fragment contains an L4 header and checksum. Prior to this change > openvswitch would modify all fragments, modi

Re: [PATCH] openvswitch: Fix L4 checksum handling when dealing with IP fragments

2015-08-03 Thread Pravin Shelar
On Sat, Aug 1, 2015 at 6:31 PM, Glenn Griffin wrote: > openvswitch modifies the L4 checksum of a packet when modifying > the ip address. When an IP packet is fragmented only the first > fragment contains an L4 header and checksum. Prior to this change > openvswitch would modify all fragments, modi

Re: [PATCH net-next 5/9] openvswitch: Add conntrack action

2015-07-31 Thread Pravin Shelar
On Thu, Jul 30, 2015 at 11:12 AM, Joe Stringer wrote: > Expose the kernel connection tracker via OVS. Userspace components can > make use of the "ct()" action, followed by "recirculate", to populate > the conntracking state in the OVS flow key, and subsequently match on > that state. > > Example O

Re: [PATCH net-next 1/9] openvswitch: Scrub packet in ovs_vport_receive()

2015-07-30 Thread Pravin Shelar
On Thu, Jul 30, 2015 at 11:12 AM, Joe Stringer wrote: > Signed-off-by: Joe Stringer > --- > net/openvswitch/vport.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/net/openvswitch/vport.c b/net/openvswitch/vport.c > index d14f594..baa018f 100644 > --- a/net/openvswitch/vport.c > +++

Re: [PATCH v2] openvswitch: allocate nr_node_ids flow_stats instead of num_possible_nodes

2015-07-21 Thread Pravin Shelar
On Tue, Jul 21, 2015 at 10:36 AM, Chris J Arges wrote: > Some architectures like POWER can have a NUMA node_possible_map that > contains sparse entries. This causes memory corruption with openvswitch > since it allocates flow_cache with a multiple of num_possible_nodes() and > assumes the node var

Re: [PATCH] openvswitch: Add missing initialization in validate_and_copy_set_tun()

2015-02-11 Thread Pravin Shelar
On Wed, Feb 11, 2015 at 2:23 AM, Geert Uytterhoeven wrote: > net/openvswitch/flow_netlink.c: In function ‘validate_and_copy_set_tun’: > net/openvswitch/flow_netlink.c:1749: warning: ‘err’ may be used uninitialized > in this function > > If ipv4_tun_from_nlattr() returns a different positive value

Re: [PATCH net-next v14 5/5] openvswitch: Add support for unique flow IDs.

2015-01-21 Thread Pravin Shelar
On Wed, Jan 21, 2015 at 4:42 PM, Joe Stringer wrote: > Previously, flows were manipulated by userspace specifying a full, > unmasked flow key. This adds significant burden onto flow > serialization/deserialization, particularly when dumping flows. > > This patch adds an alternative way to refer to

Re: [PATCH net-next v14 4/5] genetlink: Add genlmsg_parse() helper function.

2015-01-21 Thread Pravin Shelar
On Wed, Jan 21, 2015 at 4:42 PM, Joe Stringer wrote: > The first user will be the next patch. > > Signed-off-by: Joe Stringer Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo

Re: [PATCH net-next v14 2/5] openvswitch: Refactor ovs_flow_tbl_insert().

2015-01-21 Thread Pravin Shelar
On Wed, Jan 21, 2015 at 4:42 PM, Joe Stringer wrote: > Rework so that ovs_flow_tbl_insert() calls flow_{key,mask}_insert(). > This tidies up a future patch. > > Signed-off-by: Joe Stringer Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the

Re: [PATCH net-next v14 3/5] openvswitch: Use sw_flow_key_range for key ranges.

2015-01-21 Thread Pravin Shelar
On Wed, Jan 21, 2015 at 4:42 PM, Joe Stringer wrote: > These minor tidyups make a future patch a little tidier. > > Signed-off-by: Joe Stringer Acked-by: Pravin B Shelar -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.

Re: [PATCH net-next v14 1/5] openvswitch: Refactor ovs_nla_fill_match().

2015-01-21 Thread Pravin Shelar
On Wed, Jan 21, 2015 at 4:42 PM, Joe Stringer wrote: > Refactor the ovs_nla_fill_match() function into separate netlink > serialization functions ovs_nla_put_{unmasked_key,mask}(). Modify > ovs_nla_put_flow() to handle attribute nesting and expose the 'is_mask' > parameter - all callers need to ne

Re: [PATCH net-next v13 5/5] openvswitch: Add support for unique flow IDs.

2015-01-21 Thread Pravin Shelar
On Wed, Jan 21, 2015 at 11:29 AM, Joe Stringer wrote: > On 21 January 2015 at 10:31, Pravin Shelar wrote: >> On Tue, Jan 20, 2015 at 10:32 AM, Joe Stringer >> wrote: >>> Previously, flows were manipulated by userspace specifying a full, >>> unmasked flow key.

Re: [PATCH net-next v13 5/5] openvswitch: Add support for unique flow IDs.

2015-01-21 Thread Pravin Shelar
On Tue, Jan 20, 2015 at 10:32 AM, Joe Stringer wrote: > Previously, flows were manipulated by userspace specifying a full, > unmasked flow key. This adds significant burden onto flow > serialization/deserialization, particularly when dumping flows. > > This patch adds an alternative way to refer t

Re: [PATCH net-next v12 5/5] openvswitch: Add support for unique flow IDs.

2015-01-16 Thread Pravin Shelar
On Thu, Jan 15, 2015 at 1:48 PM, Joe Stringer wrote: > Previously, flows were manipulated by userspace specifying a full, > unmasked flow key. This adds significant burden onto flow > serialization/deserialization, particularly when dumping flows. > > This patch adds an alternative way to refer to

Re: [PATCH] openvswitch: fix odd_ptr_err.cocci warnings

2014-12-24 Thread Pravin Shelar
On Tue, Dec 23, 2014 at 10:41 PM, kbuild test robot wrote: > net/openvswitch/vport-gre.c:188:5-11: inconsistent IS_ERR and PTR_ERR, > PTR_ERR on line 189 > > PTR_ERR should access the value just tested by IS_ERR > > Semantic patch information: > There can be false positives in the patch case, w

Re: [ovs-dev] [PATCHv11 net-next 2/2] openvswitch: Add support for unique flow IDs.

2014-12-10 Thread Pravin Shelar
On Wed, Dec 10, 2014 at 10:15 AM, Joe Stringer wrote: > On 9 December 2014 at 22:11, Pravin Shelar wrote: >> On Tue, Dec 9, 2014 at 4:25 PM, Joe Stringer wrote: >>> On 9 December 2014 at 10:32, Pravin Shelar wrote: >>>> On Tue, Dec 2, 2014 at 6:56

Re: [PATCHv11 net-next 2/2] openvswitch: Add support for unique flow IDs.

2014-12-09 Thread Pravin Shelar
On Tue, Dec 9, 2014 at 4:25 PM, Joe Stringer wrote: > On 9 December 2014 at 10:32, Pravin Shelar wrote: >> On Tue, Dec 2, 2014 at 6:56 PM, Joe Stringer wrote: >>> @@ -662,11 +664,18 @@ static void get_dp_stats(const struct datapath *dp, >>>

Re: [PATCHv11 net-next 2/2] openvswitch: Add support for unique flow IDs.

2014-12-09 Thread Pravin Shelar
On Tue, Dec 2, 2014 at 6:56 PM, Joe Stringer wrote: > Previously, flows were manipulated by userspace specifying a full, > unmasked flow key. This adds significant burden onto flow > serialization/deserialization, particularly when dumping flows. > > This patch adds an alternative way to refer to

Re: [PATCHv11 net-next 1/2] openvswitch: Refactor ovs_nla_fill_match().

2014-12-03 Thread Pravin Shelar
On Tue, Dec 2, 2014 at 6:56 PM, Joe Stringer wrote: > Refactor the ovs_nla_fill_match() function into separate netlink > serialization functions ovs_nla_put_{unmasked_key,masked_key,mask}(). > Modify ovs_nla_put_flow() to handle attribute nesting and expose the > 'is_mask' parameter - all callers

Re: [PATCHv11 net-next 2/2] openvswitch: Add support for unique flow IDs.

2014-12-03 Thread Pravin Shelar
On Wed, Dec 3, 2014 at 10:47 AM, Joe Stringer wrote: > I forgot to mention that this is the first post based against net-next. > > On 2 December 2014 at 18:56, Joe Stringer wrote: >> >> diff --git a/net/openvswitch/flow.h b/net/openvswitch/flow.h >> index a8b30f3..7f31dbf 100644 >>

Re: [PATCHv3 net] openvswitch: Don't validate IPv6 label masks.

2014-11-19 Thread Pravin Shelar
On Wed, Nov 19, 2014 at 1:54 PM, Joe Stringer wrote: > When userspace doesn't provide a mask, OVS datapath generates a fully > unwildcarded mask for the flow by copying the flow and setting all bits > in all fields. For IPv6 label, this creates a mask that matches on the > upper 12 bits, causing t

Re: [ovs-dev] [PATCH net] openvswitch: Fix mask generation for IPv6 labels.

2014-11-19 Thread Pravin Shelar
On Wed, Nov 19, 2014 at 11:51 AM, Joe Stringer wrote: > On Wednesday, November 19, 2014 11:08:35 Pravin Shelar wrote: >> On Wed, Nov 19, 2014 at 9:48 AM, Joe Stringer > wrote: >> > On Wednesday, November 19, 2014 00:11:01 Pravin Shelar wrote: >> >> On Tue, Nov 1

Re: [ovs-dev] [PATCH net] openvswitch: Fix mask generation for IPv6 labels.

2014-11-19 Thread Pravin Shelar
On Wed, Nov 19, 2014 at 9:48 AM, Joe Stringer wrote: > On Wednesday, November 19, 2014 00:11:01 Pravin Shelar wrote: >> On Tue, Nov 18, 2014 at 11:25 PM, Joe Stringer > wrote: >> > On 18 November 2014 22:09, Pravin Shelar wrote: >> >> On Tue, Nov 1

Re: [ovs-dev] [PATCH net] openvswitch: Fix mask generation for IPv6 labels.

2014-11-19 Thread Pravin Shelar
On Tue, Nov 18, 2014 at 11:25 PM, Joe Stringer wrote: > On 18 November 2014 22:09, Pravin Shelar wrote: >> >> On Tue, Nov 18, 2014 at 10:54 AM, Joe Stringer >> wrote: >> > When userspace doesn't provide a mask, OVS datapath generates a fully >> > unw

Re: [PATCH net] openvswitch: Fix mask generation for IPv6 labels.

2014-11-18 Thread Pravin Shelar
On Tue, Nov 18, 2014 at 10:54 AM, Joe Stringer wrote: > When userspace doesn't provide a mask, OVS datapath generates a fully > unwildcarded mask for the flow. This is done by taking a copy of the > flow key, then iterating across its attributes, setting all values to > 0xff. This works for most a

Re: [PATCH 1/1 net-next] openvswitch: use PTR_ERR_OR_ZERO

2014-11-14 Thread Pravin Shelar
On Fri, Nov 14, 2014 at 10:32 AM, Fabian Frederick wrote: > Signed-off-by: Fabian Frederick Acked-by: Pravin B Shelar > --- > net/openvswitch/flow_netlink.c | 4 +--- > 1 file changed, 1 insertion(+), 3 deletions(-) > > diff --git a/net/openvswitch/flow_netlink.c b/net/openvswitch/flow_netlink

Re: [PATCH 1/1 net-next] openvswitch: use vport instead of p

2014-10-15 Thread Pravin Shelar
On Wed, Oct 15, 2014 at 12:03 PM, Fabian Frederick wrote: > All functions used struct vport *vport except > ovs_vport_find_upcall_portid. > > This fixes 1 kerneldoc warning > > Signed-off-by: Fabian Frederick Acked-by: Pravin B Shelar Thanks. > --- > net/openvswitch/vport.c | 4 ++-- > 1 fi

Re: [PATCH 1/1 net-next] openvswitch: kerneldoc warning fix

2014-10-15 Thread Pravin Shelar
On Wed, Oct 15, 2014 at 12:03 PM, Fabian Frederick wrote: > s/sock/gs > > Signed-off-by: Fabian Frederick Looks good. Acked-by: Pravin B Shelar Thanks. > --- > net/openvswitch/vport-geneve.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/net/openvswitch/vport-genev

Re: [PATCH] openvswitch: Use IS_ERR_OR_NULL

2014-07-28 Thread Pravin Shelar
On Sun, Jul 27, 2014 at 12:07 AM, Himangi Saraogi wrote: > This patch introduces the use of the macro IS_ERR_OR_NULL in place of > tests for NULL and IS_ERR. > > The following Coccinelle semantic patch was used for making the change: > > @@ > expression e; > @@ > > - e == NULL || IS_ERR(e) > + IS_

Re: [PATCH net-next v9 8/9] net: openvswitch - set name assign type

2014-07-17 Thread Pravin Shelar
On Thu, Jul 17, 2014 at 1:06 AM, Tom Gundersen wrote: > Signed-off-by: Tom Gundersen > Cc: Pravin Shelar > Cc: d...@openvswitch.org Looks good. Acked-by: Pravin B Shelar > --- > > v9: set NET_NAME_USER directly in internal_dev_create as requested by Pravin > Shelar

Re: [PATCH v8] net: openvswitch - set name assign type

2014-07-16 Thread Pravin Shelar
On Wed, Jul 16, 2014 at 4:16 PM, Tom Gundersen wrote: > On Thu, Jul 17, 2014 at 1:00 AM, Pravin Shelar wrote: >> On Wed, Jul 16, 2014 at 3:43 PM, Tom Gundersen wrote: >>> Signed-off-by: Tom Gundersen >>> Cc: Pravin Shelar >>> Cc: d...@openvswitch.org >&

  1   2   >