[PATCH V3 net 0/3] Bug fixes for ENA ethernet driver

2020-08-19 Thread Shay Agroskin
This series adds the following: - Fix undesired call to ena_restore after returning from suspend - Fix condition inside a WARN_ON - Fix overriding previous value when updating missed_tx statistic v1->v2: - fix bug when calling reset routine after device resources are freed (Jakub) v2->v3: - fix w

[PATCH V3 net 2/3] net: ena: Change WARN_ON expression in ena_del_napi_in_range()

2020-08-19 Thread Shay Agroskin
The ena_del_napi_in_range() function unregisters the napi handler for rings in a given range. This function had the following WARN_ON macro: WARN_ON(ENA_IS_XDP_INDEX(adapter, i) && adapter->ena_napi[i].xdp_ring); This macro prints the call stack if the expression inside of it is t

[PATCH V3 net 3/3] net: ena: Make missed_tx stat incremental

2020-08-19 Thread Shay Agroskin
Most statistics in ena driver are incremented, meaning that a stat's value is a sum of all increases done to it since driver/queue initialization. This patch makes all statistics this way, effectively making missed_tx statistic incremental. Also added a comment regarding rx_drops and tx_drops to m

Re: NETDEV WATCHDOG: WARNING: at net/sched/sch_generic.c:442 dev_watchdog

2020-08-19 Thread Jesse Brandeburg
Steven Rostedt wrote: > On Wed, 19 Aug 2020 17:01:06 +0530 > Naresh Kamboju wrote: > > > kernel warning noticed on x86_64 while running LTP tracing > > ftrace-stress-test > > case. started noticing on the stable-rc linux-5.8.y branch. > > > > This device booted with KASAN config and DYNAMIC tr

[PATCH V3 net 1/3] net: ena: Prevent reset after device destruction

2020-08-19 Thread Shay Agroskin
The reset work is scheduled by the timer routine whenever it detects that a device reset is required (e.g. when a keep_alive signal is missing). When releasing device resources in ena_destroy_device() the driver cancels the scheduling of the timer routine without destroying the reset work explicitl

Re: [PATCH bpf-next] tools/resolve_btfids: Fix sections with wrong alignment

2020-08-19 Thread Jiri Olsa
On Wed, Aug 19, 2020 at 08:31:51AM -0700, Yonghong Song wrote: > > > On 8/19/20 2:23 AM, Jiri Olsa wrote: > > The data of compressed section should be aligned to 4 > > (for 32bit) or 8 (for 64 bit) bytes. > > > > The binutils ld sets sh_addralign to 1, which makes libelf > > fail with misaligned

Re: [PATCH net-next] SUNRPC: remove duplicate include

2020-08-19 Thread Chuck Lever
> On Aug 18, 2020, at 10:49 PM, Wang Hai wrote: > > Remove linux/sunrpc/auth_gss.h which is included more than once > > Reported-by: Hulk Robot > Signed-off-by: Wang Hai I've reviewed and compile-tested this, so no objection from me. Since this duplicate was introduced in nfsd-5.9, I can

Re: [RFC PATCH net-next 0/6] devlink: Add device metric support

2020-08-19 Thread Jakub Kicinski
On Wed, 19 Aug 2020 10:20:08 -0700 Florian Fainelli wrote: > > I'm trying to find a solution which will not require a policeman to > > constantly monitor the compliance. Please see my effort to ensure > > drivers document and use the same ethtool -S stats in the TLS offload > > implementations. I'v

[PATCH, net-next, v3] ibmvnic: store RX and TX subCRQ handle array in ibmvnic_adapter struct

2020-08-19 Thread Cristobal Forno
Currently the driver reads RX and TX subCRQ handle array directly from a DMA-mapped buffer address when it needs to make a H_SEND_SUBCRQ hcall. This patch stores that information in the ibmvnic_sub_crq_queue structure instead of reading from the buffer received at login. The overall goal of this pa

Re: [PATCH, net-next, v2] ibmvnic: store RX and TX subCRQ handle array in ibmvnic_adapter struct

2020-08-19 Thread Cris Forno
David Miller writes: > From: Cristobal Forno > Date: Tue, 18 Aug 2020 16:53:33 -0500 > >> @@ -1524,7 +1519,7 @@ static netdev_tx_t ibmvnic_xmit(struct sk_buff *skb, >> struct net_device *netdev) >> unsigned int offset; >> int num_entries = 1; >> unsigned char *dst; >> -u64 *h

Re: [PATCH v1 2/2] Bluetooth: sco: expose WBS packet length in socket option

2020-08-19 Thread Luiz Augusto von Dentz
Hi Pali, On Wed, Aug 19, 2020 at 7:37 AM Pali Rohár wrote: > > On Friday 14 August 2020 12:56:05 Luiz Augusto von Dentz wrote: > > Hi Joseph, > > > > On Thu, Aug 13, 2020 at 1:42 AM Joseph Hwang wrote: > > > > > > It is desirable to expose the wideband speech packet length via > > > a socket opt

Re: [PATCH v1 2/2] Bluetooth: sco: expose WBS packet length in socket option

2020-08-19 Thread Pali Rohár
On Wednesday 19 August 2020 11:21:00 Luiz Augusto von Dentz wrote: > Hi Pali, > > On Wed, Aug 19, 2020 at 7:37 AM Pali Rohár wrote: > > > > On Friday 14 August 2020 12:56:05 Luiz Augusto von Dentz wrote: > > > Hi Joseph, > > > > > > On Thu, Aug 13, 2020 at 1:42 AM Joseph Hwang > > > wrote: > >

Re: [PATCH v1 2/2] Bluetooth: sco: expose WBS packet length in socket option

2020-08-19 Thread Luiz Augusto von Dentz
On Wed, Aug 19, 2020 at 11:23 AM Pali Rohár wrote: > > On Wednesday 19 August 2020 11:21:00 Luiz Augusto von Dentz wrote: > > Hi Pali, > > > > On Wed, Aug 19, 2020 at 7:37 AM Pali Rohár wrote: > > > > > > On Friday 14 August 2020 12:56:05 Luiz Augusto von Dentz wrote: > > > > Hi Joseph, > > > > >

Re: WARNING in __cfg80211_connect_result

2020-08-19 Thread syzbot
syzbot has bisected this issue to: commit e7096c131e5161fa3b8e52a650d7719d2857adfd Author: Jason A. Donenfeld Date: Sun Dec 8 23:27:34 2019 + net: WireGuard secure network tunnel bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=175ad8b190 start commit: e3ec1e8c net:

Re: [PATCH bpf-next 2/6] bpf: sockmap: merge sockmap and sockhash update functions

2020-08-19 Thread Yonghong Song
On 8/19/20 2:24 AM, Lorenz Bauer wrote: Merge the two very similar functions sock_map_update_elem and sock_hash_update_elem into one. Signed-off-by: Lorenz Bauer Acked-by: Yonghong Song

Re: [PATCH net-next RFC v2 01/13] devlink: Add reload action option to devlink reload command

2020-08-19 Thread Jiri Pirko
Wed, Aug 19, 2020 at 06:25:51PM CEST, k...@kernel.org wrote: >On Wed, 19 Aug 2020 17:18:15 +0200 Jiri Pirko wrote: > I will add counters on which reload were done. reload_down()/up() can > return > which actions were actually done and devlink will show counters. Why a counter? J

Re: [PATCH net-next v2 0/2] net: dsa: loop: Expose VLAN table through devlink

2020-08-19 Thread David Miller
From: Florian Fainelli Date: Tue, 18 Aug 2020 21:32:16 -0700 > Changes in v2: > > - set the DSA configure_vlan_while_not_filtering boolean > - return the actual occupancy Series applied, thank you.

Re: xdp generic default option

2020-08-19 Thread Jakub Kicinski
On Wed, 19 Aug 2020 11:28:11 +0200 Lorenzo Bianconi wrote: > Hi Andrii, > > working on xdp multi-buff I figured out now xdp generic is the default choice > if not specified by userspace. In particular after commit 7f0a838254bd > ("bpf, xdp: Maintain info on attached XDP BPF programs in net_device"

Re: [PATCH] net: bypass ->sendpage for slab pages

2020-08-19 Thread David Miller
From: Christoph Hellwig Date: Wed, 19 Aug 2020 07:19:45 +0200 > Sending Slab or tail pages into ->sendpage will cause really strange > delayed oops. Prevent it right in the networking code instead of > requiring drivers to guess the exact conditions where sendpage works. > > Based on a patch fr

Re: [PATCH net-next 3/5] ibmvnic: improve ibmvnic_init and ibmvnic_reset_init

2020-08-19 Thread David Miller
From: Lijun Pan Date: Wed, 19 Aug 2020 00:35:10 -0500 > + if (rc) { > + dev_err(dev, "%s: Send crq init failed with error %d\n", > __func__, rc); > + return rc; Consistent with my feedback on patch #1, please get rid of this __func__ stuff. Thank you.

Re: [PATCH net-next 1/5] ibmvnic: print caller in several error messages

2020-08-19 Thread David Miller
From: Lijun Pan Date: Wed, 19 Aug 2020 00:35:08 -0500 > The error messages in the changed functions are exactly the same. > In order to differentiate them and make debugging easier, > we print the function names in the error messages. > > Signed-off-by: Lijun Pan I don't see any value in emitt

Re: [PATCH] netlink: fix state reallocation in policy export

2020-08-19 Thread Jakub Kicinski
On Wed, 19 Aug 2020 12:22:55 +0200 Johannes Berg wrote: > From: Johannes Berg > > Evidently, when I did this previously, we didn't have more than > 10 policies and didn't run into the reallocation path, because > it's missing a memset() for the unused policies. Fix that. > > Fixes: d07dcf9aadd6

Re: [PATCH bpf-next 3/6] bpf: sockmap: call sock_map_update_elem directly

2020-08-19 Thread Yonghong Song
On 8/19/20 2:24 AM, Lorenz Bauer wrote: Don't go via map->ops to call sock_map_update_elem, since we know what function to call in bpf_map_update_value. Since check_map_func_compatibility doesn't allow calling BPF_FUNC_map_update_elem from BPF context, we can remove ops->map_update_elem and re

Re: NETDEV WATCHDOG: WARNING: at net/sched/sch_generic.c:442 dev_watchdog

2020-08-19 Thread Steven Rostedt
On Wed, 19 Aug 2020 10:29:09 -0700 Jesse Brandeburg wrote: > What I don't understand in the stack trace is this: > > > [ 107.654661] Call Trace: > > > [ 107.657735] > > > [ 107.663155] ? ftrace_graph_caller+0xc0/0xc0 > > > [ 107.667929] call_timer_fn+0x3b/0x1b0 > > > [ 107.672238] ? ne

Re: [PATCH net-next 6/6] net: mvneta: enable jumbo frames for XDP

2020-08-19 Thread Jakub Kicinski
On Wed, 19 Aug 2020 15:13:51 +0200 Lorenzo Bianconi wrote: > Enable the capability to receive jumbo frames even if the interface is > running in XDP mode > > Signed-off-by: Lorenzo Bianconi Hm, already? Is all the infra in place? Or does it not imply multi-buffer.

[PATCH bpf] bpf: refer to struct xdp_md in user space comments

2020-08-19 Thread Jakub Kicinski
uAPI uses xdp_md, not xdp_buff. Fix comments. Signed-off-by: Jakub Kicinski --- include/uapi/linux/bpf.h | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/uapi/linux/bpf.h b/include/uapi/linux/bpf.h index 0480f893facd..cc3553a102d0 100644 --- a/include/uapi/linu

Re: [PATCH net-next] net/mlx5: remove erroneous fallthrough

2020-08-19 Thread Saeed Mahameed
On Mon, 2020-08-03 at 10:48 -0500, Gustavo A. R. Silva wrote: > On Mon, Aug 03, 2020 at 05:34:48PM +0300, Dan Carpenter wrote: > > This isn't a fall through because it was after a return > > statement. The > > fall through annotation leads to a Smatch warning: > > > > drivers/net/ethernet/mel

Re: [PATCH v2 bpf-next 2/5] selftests/bpf: test TYPE_EXISTS and TYPE_SIZE CO-RE relocations

2020-08-19 Thread Andrii Nakryiko
On Wed, Aug 19, 2020 at 9:31 AM Yonghong Song wrote: > > > > On 8/18/20 10:28 PM, Andrii Nakryiko wrote: > > Add selftests for TYPE_EXISTS and TYPE_SIZE relocations, testing correctness > > of relocations and handling of type compatiblity/incompatibility. > > > > If __builtin_preserve_type_info()

Re: [PATCH v2 bpf-next 3/5] selftests/bpf: add CO-RE relo test for TYPE_ID_LOCAL/TYPE_ID_TARGET

2020-08-19 Thread Andrii Nakryiko
On Wed, Aug 19, 2020 at 9:43 AM Yonghong Song wrote: > > > > On 8/18/20 10:28 PM, Andrii Nakryiko wrote: > > Add tests for BTF type ID relocations. To allow testing this, enhance > > core_relo.c test runner to allow dynamic initialization of test inputs. > > If __builtin_btf_type_id() is not suppo

[PATCH v3 bpf-next 1/5] libbpf: implement type-based CO-RE relocations support

2020-08-19 Thread Andrii Nakryiko
Implement support for TYPE_EXISTS/TYPE_SIZE/TYPE_ID_LOCAL/TYPE_ID_REMOTE relocations. These are examples of type-based relocations, as opposed to field-based relocations supported already. The difference is that they are calculating relocation values based on the type itself, not a field within a s

[PATCH v3 bpf-next 2/5] selftests/bpf: test TYPE_EXISTS and TYPE_SIZE CO-RE relocations

2020-08-19 Thread Andrii Nakryiko
Add selftests for TYPE_EXISTS and TYPE_SIZE relocations, testing correctness of relocations and handling of type compatiblity/incompatibility. If __builtin_preserve_type_info() is not supported by compiler, skip tests. Acked-by: Yonghong Song Signed-off-by: Andrii Nakryiko --- .../selftests/bp

[PATCH v3 bpf-next 4/5] libbpf: implement enum value-based CO-RE relocations

2020-08-19 Thread Andrii Nakryiko
Implement two relocations of a new enumerator value-based CO-RE relocation kind: ENUMVAL_EXISTS and ENUMVAL_VALUE. First, ENUMVAL_EXISTS, allows to detect the presence of a named enumerator value in the target (kernel) BTF. This is useful to do BPF helper/map/program type support detection from BP

[PATCH v3 bpf-next 5/5] selftests/bpf: add tests for ENUMVAL_EXISTS/ENUMVAL_VALUE relocations

2020-08-19 Thread Andrii Nakryiko
Add tests validating existence and value relocations for enum value-based relocations. If __builtin_preserve_enum_value() built-in is not supported, skip tests. Acked-by: Yonghong Song Signed-off-by: Andrii Nakryiko --- .../selftests/bpf/prog_tests/core_reloc.c | 56 + .../bpf/p

[PATCH v3 bpf-next 3/5] selftests/bpf: add CO-RE relo test for TYPE_ID_LOCAL/TYPE_ID_TARGET

2020-08-19 Thread Andrii Nakryiko
Add tests for BTF type ID relocations. To allow testing this, enhance core_relo.c test runner to allow dynamic initialization of test inputs. If Clang doesn't have necessary support for new functionality, test is skipped. Acked-by: Yonghong Song Signed-off-by: Andrii Nakryiko --- .../selftests/

Re: [PATCH, net-next, v3] ibmvnic: store RX and TX subCRQ handle array in ibmvnic_adapter struct

2020-08-19 Thread Jesse Brandeburg
Cristobal Forno wrote: > Currently the driver reads RX and TX subCRQ handle array directly from > a DMA-mapped buffer address when it needs to make a H_SEND_SUBCRQ > hcall. This patch stores that information in the ibmvnic_sub_crq_queue > structure instead of reading from the buffer received at lo

[PATCH v3 bpf-next 0/5] Add libbpf support for type- and enum value-based CO-RE relocations

2020-08-19 Thread Andrii Nakryiko
This patch set adds libbpf support for two new classes of CO-RE relocations: type-based (TYPE_EXISTS/TYPE_SIZE/TYPE_ID_LOCAL/TYPE_ID_TARGET) and enum value-vased (ENUMVAL_EXISTS/ENUMVAL_VALUE): - TYPE_EXISTS allows to detect presence in kernel BTF of a locally-recorded BTF type. Useful for fe

Re: [PATCH] netlink: fix state reallocation in policy export

2020-08-19 Thread Johannes Berg
On Wed, 2020-08-19 at 12:10 -0700, Jakub Kicinski wrote: > > + memset(&state->policies[state->n_alloc], 0, > > + sizeof(state->policies[0]) * (n_alloc - state->n_alloc)); > > [flex_]array_size() ? To avoid the inevitable follow up from a bot.. Yeah, hmm. I suppose you know this but

Re: [PATCH 00/49] DRM driver for Hikey 970

2020-08-19 Thread John Stultz
On Wed, Aug 19, 2020 at 8:31 AM Laurent Pinchart wrote: > On Wed, Aug 19, 2020 at 05:21:20PM +0200, Sam Ravnborg wrote: > > On Wed, Aug 19, 2020 at 01:45:28PM +0200, Mauro Carvalho Chehab wrote: > > > This patch series port the out-of-tree driver for Hikey 970 (which > > > should also support Hike

[PATCH v2] netlink: fix state reallocation in policy export

2020-08-19 Thread Johannes Berg
From: Johannes Berg Evidently, when I did this previously, we didn't have more than 10 policies and didn't run into the reallocation path, because it's missing a memset() for the unused policies. Fix that. Fixes: d07dcf9aadd6 ("netlink: add infrastructure to expose policies to userspace") Signe

Re: [PATCH v2] net: Stop warning about SO_BSDCOMPAT usage

2020-08-19 Thread David Miller
From: Miaohe Lin Date: Wed, 19 Aug 2020 04:32:08 -0400 > We've been warning about SO_BSDCOMPAT usage for many years. We may remove > this code completely now. > > Suggested-by: David S. Miller > Signed-off-by: Miaohe Lin Applied to net-next, thank you.

Re: [PATCH net-next v2] Documentation/networking: update l2tp docs

2020-08-19 Thread David Miller
From: jchap...@katalix.com Date: Wed, 19 Aug 2020 10:20:32 +0100 > From: James Chapman > > Kernel documentation of L2TP has not been kept up to date and lacks > coverage of some L2TP APIs. While addressing this, refactor to improve > readability, separating the parts which focus on user APIs and

Re: [PATCH net-next 0/2] r8169: use napi_complete_done return value

2020-08-19 Thread David Miller
From: Heiner Kallweit Date: Wed, 19 Aug 2020 13:00:57 +0200 > Consider the return value of napi_complete_done(), this allows users to > use the gro_flush_timeout sysfs attribute as an alternative to classic > interrupt coalescing. Series applied, thanks Heiner.

Re: [PATCH v2] dt-bindings: net: renesas,ether: Improve schema validation

2020-08-19 Thread David Miller
From: Geert Uytterhoeven Date: Wed, 19 Aug 2020 14:45:39 +0200 > - Remove pinctrl consumer properties, as they are handled by core > dt-schema, > - Document missing properties, > - Document missing PHY child node, > - Add "additionalProperties: false". > > Signed-off-by: Geert Uytter

RE: [PATCH bpf-next 1/6] net: sk_msg: simplify sk_psock initialization

2020-08-19 Thread John Fastabend
Lorenz Bauer wrote: > Initializing psock->sk_proto and other saved callbacks is only > done in sk_psock_update_proto, after sk_psock_init has returned. > The logic for this is difficult to follow, and needlessly complex. > > Instead, initialize psock->sk_proto whenever we allocate a new > psock. A

RE: [PATCH bpf-next 2/6] bpf: sockmap: merge sockmap and sockhash update functions

2020-08-19 Thread John Fastabend
Lorenz Bauer wrote: > Merge the two very similar functions sock_map_update_elem and > sock_hash_update_elem into one. > > Signed-off-by: Lorenz Bauer > --- > net/core/sock_map.c | 53 - > 1 file changed, 9 insertions(+), 44 deletions(-) > Fixup the w

Re: [PATCH bpf-next 4/7] libbpf: sanitize BPF program code for bpf_probe_read_{kernel,user}[_str]

2020-08-19 Thread Andrii Nakryiko
On Tue, Aug 18, 2020 at 6:42 PM Yonghong Song wrote: > > > > On 8/18/20 2:33 PM, Andrii Nakryiko wrote: > > Add BPF program code sanitization pass, replacing calls to BPF > > bpf_probe_read_{kernel,user}[_str]() helpers with bpf_probe_read[_str](), if > > libbpf detects that kernel doesn't support

Re: [PATCH bpf-next 4/6] bpf: override the meaning of ARG_PTR_TO_MAP_VALUE for sockmap and sockhash

2020-08-19 Thread Yonghong Song
On 8/19/20 2:24 AM, Lorenz Bauer wrote: The verifier assumes that map values are simple blobs of memory, and therefore treats ARG_PTR_TO_MAP_VALUE, etc. as such. However, there are map types where this isn't true. For example, sockmap and sockhash store sockets. In general this isn't a big pro

Re: [PATCH bpf-next 4/7] libbpf: sanitize BPF program code for bpf_probe_read_{kernel,user}[_str]

2020-08-19 Thread Alexei Starovoitov
On Wed, Aug 19, 2020 at 1:13 PM Andrii Nakryiko wrote: > > On Tue, Aug 18, 2020 at 6:42 PM Yonghong Song wrote: > > > > > > > > On 8/18/20 2:33 PM, Andrii Nakryiko wrote: > > > Add BPF program code sanitization pass, replacing calls to BPF > > > bpf_probe_read_{kernel,user}[_str]() helpers with b

Re: [PATCH net-next 6/6] net: mvneta: enable jumbo frames for XDP

2020-08-19 Thread Lorenzo Bianconi
> On Wed, 19 Aug 2020 15:13:51 +0200 Lorenzo Bianconi wrote: > > Enable the capability to receive jumbo frames even if the interface is > > running in XDP mode > > > > Signed-off-by: Lorenzo Bianconi > > Hm, already? Is all the infra in place? Or does it not imply > multi-buffer. > Hi Jakub,

Re: [PATCH bpf-next 4/7] libbpf: sanitize BPF program code for bpf_probe_read_{kernel,user}[_str]

2020-08-19 Thread Andrii Nakryiko
On Wed, Aug 19, 2020 at 1:15 PM Alexei Starovoitov wrote: > > On Wed, Aug 19, 2020 at 1:13 PM Andrii Nakryiko > wrote: > > > > On Tue, Aug 18, 2020 at 6:42 PM Yonghong Song wrote: > > > > > > > > > > > > On 8/18/20 2:33 PM, Andrii Nakryiko wrote: > > > > Add BPF program code sanitization pass, r

[PATCH net 3/3] net: qed: RDMA personality shouldn't fail VF load

2020-08-19 Thread Dmitry Bogdanov
Fix the assert during VF driver installation when the personality is iWARP Fixes: 1fe614d10f45 ("qed: Relax VF firmware requirements") Signed-off-by: Igor Russkikh Signed-off-by: Michal Kalderon Signed-off-by: Dmitry Bogdanov --- drivers/net/ethernet/qlogic/qed/qed_sriov.c | 1 + 1 file change

[PATCH net 2/3] net: qede: Disable aRFS for NPAR and 100G

2020-08-19 Thread Dmitry Bogdanov
In some configurations ARFS cannot be used, so disable it if device is not capable. Fixes: e4917d46a65 ("qede: Add aRFS support") Signed-off-by: Manish Chopra Signed-off-by: Igor Russkikh Signed-off-by: Michal Kalderon Signed-off-by: Dmitry Bogdanov --- drivers/net/ethernet/qlogic/qede/qede_f

[PATCH net 1/3] net: qed: Disable aRFS for NPAR and 100G

2020-08-19 Thread Dmitry Bogdanov
In CMT and NPAR the PF is unknown when the GFS block processes the packet. Therefore cannot use searcher as it has a per PF database, and thus ARFS must be disabled. Fixes: d51e4af5c209 ("qed: aRFS infrastructure support") Signed-off-by: Manish Chopra Signed-off-by: Igor Russkikh Signed-off-by:

[PATCH net 0/3] net: qed disable aRFS in NPAR and 100G

2020-08-19 Thread Dmitry Bogdanov
This patchset fixes some recent issues found by customers. Dmitry Bogdanov (3): net: qed: Disable aRFS for NPAR and 100G net: qede: Disable aRFS for NPAR and 100G qed: RDMA personality shouldn't fail VF load drivers/net/ethernet/qlogic/qed/qed_dev.c | 11 ++- drivers/net/ether

RE: [PATCH bpf-next 3/6] bpf: sockmap: call sock_map_update_elem directly

2020-08-19 Thread John Fastabend
Lorenz Bauer wrote: > Don't go via map->ops to call sock_map_update_elem, since we know > what function to call in bpf_map_update_value. Since > check_map_func_compatibility doesn't allow calling > BPF_FUNC_map_update_elem from BPF context, we can remove > ops->map_update_elem and rename the functi

Re: [PATCH bpf-next 5/6] bpf: sockmap: allow update from BPF

2020-08-19 Thread Yonghong Song
On 8/19/20 2:24 AM, Lorenz Bauer wrote: Allow calling bpf_map_update_elem on sockmap and sockhash from a BPF context. The synchronization required for this is a bit fiddly: we need to prevent the socket from changing it's state while we add it to the sockmap, since we rely on getting a callbac

Re: [PATCH iproute2-next v2] iproute2: ss: add support to expose various inet sockopts

2020-08-19 Thread Roman Mashak
Wei Wang writes: > This commit adds support to expose the following inet socket options: > -- recverr > -- is_icsk > -- freebind > -- hdrincl > -- mc_loop > -- transparent > -- mc_all > -- nodefrag > -- bind_address_no_port > -- recverr_rfc4884 > -- defer_connect > with the option --inet-sockopt.

Re: [PATCH bpf-next 6/6] selftests: bpf: test sockmap update from BPF

2020-08-19 Thread Yonghong Song
On 8/19/20 2:24 AM, Lorenz Bauer wrote: Add a test which copies a socket from a sockmap into another sockmap or sockhash. This excercises bpf_map_update_elem support from BPF context. Compare the socket cookies from source and destination to ensure that the copy succeeded. Signed-off-by: Lore

Re: [PATCH bpf] bpf: refer to struct xdp_md in user space comments

2020-08-19 Thread Yonghong Song
On 8/19/20 12:27 PM, Jakub Kicinski wrote: uAPI uses xdp_md, not xdp_buff. Fix comments. Signed-off-by: Jakub Kicinski Acked-by: Yonghong Song

RE: [PATCH bpf-next 4/6] bpf: override the meaning of ARG_PTR_TO_MAP_VALUE for sockmap and sockhash

2020-08-19 Thread John Fastabend
Lorenz Bauer wrote: > The verifier assumes that map values are simple blobs of memory, and > therefore treats ARG_PTR_TO_MAP_VALUE, etc. as such. However, there are > map types where this isn't true. For example, sockmap and sockhash store > sockets. In general this isn't a big problem: we can just

Re: xdp generic default option

2020-08-19 Thread Andrii Nakryiko
On Wed, Aug 19, 2020 at 2:29 AM Lorenzo Bianconi wrote: > > Hi Andrii, > > working on xdp multi-buff I figured out now xdp generic is the default choice > if not specified by userspace. In particular after commit 7f0a838254bd > ("bpf, xdp: Maintain info on attached XDP BPF programs in net_device")

Re: [PATCH 49/49] dt: display: Add binds for the DPE and DSI controller for Kirin 960/970

2020-08-19 Thread Sam Ravnborg
Hi Mauro. Some feedback in the following. Good to see DT schma files and not .txt files - but needs a bit more work. Sam On Wed, Aug 19, 2020 at 01:46:17PM +0200, Mauro Carvalho Chehab wrote: > Add a description of the bindings used by Kirin 960/970 Display > Serial Interface (DSI) contr

[PATCH] rtl818x_pci: switch from 'pci_' to 'dma_' API

2020-08-19 Thread Christophe JAILLET
The wrappers in include/linux/pci-dma-compat.h should go away. The patch has been generated with the coccinelle script below and has been hand modified to replace GFP_ with a correct flag. It has been compile tested. When memory is allocated in 'rtl8180_init_rx_ring()' and 'rtl8180_init_tx_ring()

Re: [PATCH bpf-next 1/2] net-tun: add type safety to tun_xdp_to_ptr() and tun_ptr_to_xdp()

2020-08-19 Thread Alexei Starovoitov
On Tue, Aug 18, 2020 at 6:07 PM Maciej Żenczykowski wrote: > > From: Maciej Żenczykowski > > This reduces likelihood of incorrect use. > > Test: builds > Signed-off-by: Maciej Żenczykowski Applied. Thanks

Re: [PATCH 00/49] DRM driver for Hikey 970

2020-08-19 Thread John Stultz
On Wed, Aug 19, 2020 at 4:46 AM Mauro Carvalho Chehab wrote: > Yet, I'm submitting it via staging due to the following reasons: > > - It depends on the LDO3 power supply, which is provided by > a regulator driver that it is currently on staging; > - Due to legal reasons, I need to preserve the a

Re: [PATCH net-next 6/6] net: mvneta: enable jumbo frames for XDP

2020-08-19 Thread Jakub Kicinski
On Wed, 19 Aug 2020 22:22:23 +0200 Lorenzo Bianconi wrote: > > On Wed, 19 Aug 2020 15:13:51 +0200 Lorenzo Bianconi wrote: > > > Enable the capability to receive jumbo frames even if the interface is > > > running in XDP mode > > > > > > Signed-off-by: Lorenzo Bianconi > > > > Hm, already? Is

Re: [PATCH bpf-next] net-veth: add type safety to veth_xdp_to_ptr() and veth_ptr_to_xdp()

2020-08-19 Thread Alexei Starovoitov
On Tue, Aug 18, 2020 at 7:00 PM Maciej Żenczykowski wrote: > > From: Maciej Żenczykowski > > This reduces likelihood of incorrect use. > > Test: builds I kept this in the commit log though it's a pointless comment. Please reconsider for the future. If you want to mention how you've tested it, pl

Re: [PATCH iproute2 v5 0/2] iplink: hsr: add support for creating PRP device

2020-08-19 Thread Murali Karicheri
Hi, Stephen, On 8/17/20 5:17 PM, Murali Karicheri wrote: This series enhances the iproute2 iplink module to add support for creating PRP device similar to HSR. The kernel part of this is already merged to v5.9 master v5 - addressed comment from Stephen Hemminger - Sending this with a iprout

RE: [PATCH bpf-next 5/6] bpf: sockmap: allow update from BPF

2020-08-19 Thread John Fastabend
Lorenz Bauer wrote: > Allow calling bpf_map_update_elem on sockmap and sockhash from a BPF > context. The synchronization required for this is a bit fiddly: we > need to prevent the socket from changing it's state while we add it > to the sockmap, since we rely on getting a callback via > sk_prot->

Re: [PATCH 00/49] DRM driver for Hikey 970

2020-08-19 Thread Sam Ravnborg
Hi John. > > So, IMO, the best is to keep it on staging for a while, until those > > remaining bugs gets solved. > > I'm not sure I see all of these as compelling for pushing it in via > staging. And I suspect in the process of submitting the patches for > review folks may find the cause of some

Re: [PATCH bpf-next] tools/resolve_btfids: Fix sections with wrong alignment

2020-08-19 Thread Yonghong Song
On 8/19/20 11:16 AM, Nick Desaulniers wrote: On Wed, Aug 19, 2020 at 10:36 AM Jiri Olsa wrote: On Wed, Aug 19, 2020 at 08:31:51AM -0700, Yonghong Song wrote: On 8/19/20 2:23 AM, Jiri Olsa wrote: The data of compressed section should be aligned to 4 (for 32bit) or 8 (for 64 bit) bytes.

tc filter by source port and destination port strange offset

2020-08-19 Thread Denis Gubin
Dear colleagues, There are filters. Let's have a look on it. Pretty mode showing: tc -p filter show dev ens5 parent : filter protocol ip pref 49146 u32 chain 0 filter protocol ip pref 49146 u32 chain 0 fh 806: ht divisor 1 filter protocol ip pref 49146 u32 chain 0 fh 806::800 order 2048 key

Re: [PATCH bpf-next] tools/resolve_btfids: Fix sections with wrong alignment

2020-08-19 Thread Yonghong Song
On 8/19/20 2:23 AM, Jiri Olsa wrote: The data of compressed section should be aligned to 4 (for 32bit) or 8 (for 64 bit) bytes. The binutils ld sets sh_addralign to 1, which makes libelf fail with misaligned section error during the update as reported by Jesper: FAILED elf_update(WRITE):

Re: [PATCH 00/49] DRM driver for Hikey 970

2020-08-19 Thread John Stultz
On Wed, Aug 19, 2020 at 4:46 AM Mauro Carvalho Chehab wrote: > So, IMO, the best is to keep it on staging for a while, until those > remaining bugs gets solved. > > I added this series, together with the regulator driver and > a few other patches (including a hack to fix a Kernel 5.8 > regression

Re: [PATCH] block: convert tasklets to use new tasklet_setup() API

2020-08-19 Thread James Bottomley
On Wed, 2020-08-19 at 21:54 +0530, Allen wrote: > > [...] > > > > Since both threads seem to have petered out, let me suggest in > > > > kernel.h: > > > > > > > > #define cast_out(ptr, container, member) \ > > > > container_of(ptr, typeof(*container), member) > > > > > > > > It does what you

Re: [PATCH net-next 6/6] net: mvneta: enable jumbo frames for XDP

2020-08-19 Thread John Fastabend
Jakub Kicinski wrote: > On Wed, 19 Aug 2020 22:22:23 +0200 Lorenzo Bianconi wrote: > > > On Wed, 19 Aug 2020 15:13:51 +0200 Lorenzo Bianconi wrote: > > > > Enable the capability to receive jumbo frames even if the interface is > > > > running in XDP mode > > > > > > > > Signed-off-by: Lorenzo Bi

Re: [PATCH v3 bpf-next 0/5] Add libbpf support for type- and enum value-based CO-RE relocations

2020-08-19 Thread Alexei Starovoitov
On Wed, Aug 19, 2020 at 12:45:14PM -0700, Andrii Nakryiko wrote: > > Selftests are added for all the new features. Selftests utilizing new Clang > built-ins are designed such that they will compile with older Clangs and will > be skipped during test runs. So this shouldn't cause any build and test

Re: Kernel build error on BTFIDS vmlinux

2020-08-19 Thread Mark Wielaard
Hi, On Wed, 2020-08-19 at 19:18 +0200, Jiri Olsa wrote: > On Wed, Aug 19, 2020 at 04:34:30PM +0100, Nick Clifton wrote: > > > So it would be nice if binutils ld could also be fixed to write out > > > compressed sections with the correct alignment. > > > > OK, I will look into doing this. > > > >

Re: [PATCH net] drivers/net/wan/lapbether: Added needed_tailroom

2020-08-19 Thread Xie He
Hi Martin Schiller, Can you help review this patch? Thanks! It is a very simple patch that adds the "needed_tailroom" setting for this driver. Thank you! Xie He

Re: [PATCH net-next 2/3] net: dsa: mv88e6xxx: return error instead of lane in .serdes_get_lane

2020-08-19 Thread kernel test robot
Hi "Marek, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on net-next/master] url: https://github.com/0day-ci/linux/commits/Marek-Beh-n/net-dsa-mv88e6xxx-Add-Amethyst-88E6393X/20200819-234008 base: https://git.kernel.org/pub/scm/linux/kernel/git/dave

Re: [PATCH V3 net 0/3] Bug fixes for ENA ethernet driver

2020-08-19 Thread David Miller
From: Shay Agroskin Date: Wed, 19 Aug 2020 20:28:35 +0300 > This series adds the following: > - Fix undesired call to ena_restore after returning from suspend > - Fix condition inside a WARN_ON > - Fix overriding previous value when updating missed_tx statistic > > v1->v2: > - fix bug when calli

Re: [PATCH 49/49] dt: display: Add binds for the DPE and DSI controller for Kirin 960/970

2020-08-19 Thread Rob Herring
On Wed, 19 Aug 2020 13:46:17 +0200, Mauro Carvalho Chehab wrote: > Add a description of the bindings used by Kirin 960/970 Display > Serial Interface (DSI) controller and by its Display Engine (DPE). > > Signed-off-by: Mauro Carvalho Chehab > --- > .../display/hisilicon,hi3660-dpe.yaml |

Re: [PATCH v3 bpf-next 0/5] Add libbpf support for type- and enum value-based CO-RE relocations

2020-08-19 Thread Andrii Nakryiko
On Wed, Aug 19, 2020 at 2:58 PM Alexei Starovoitov wrote: > > On Wed, Aug 19, 2020 at 12:45:14PM -0700, Andrii Nakryiko wrote: > > > > Selftests are added for all the new features. Selftests utilizing new Clang > > built-ins are designed such that they will compile with older Clangs and > > will

Re: [PATCH, net-next, v3] ibmvnic: store RX and TX subCRQ handle array in ibmvnic_adapter struct

2020-08-19 Thread David Miller
From: Cristobal Forno Date: Wed, 19 Aug 2020 13:16:23 -0500 > Currently the driver reads RX and TX subCRQ handle array directly from > a DMA-mapped buffer address when it needs to make a H_SEND_SUBCRQ > hcall. This patch stores that information in the ibmvnic_sub_crq_queue > structure instead of

Re: [PATCH v2] netlink: fix state reallocation in policy export

2020-08-19 Thread David Miller
From: Johannes Berg Date: Wed, 19 Aug 2020 21:52:38 +0200 > From: Johannes Berg > > Evidently, when I did this previously, we didn't have more than > 10 policies and didn't run into the reallocation path, because > it's missing a memset() for the unused policies. Fix that. > > Fixes: d07dcf9aa

RE: [PATCH bpf-next 5/6] bpf: sockmap: allow update from BPF

2020-08-19 Thread John Fastabend
John Fastabend wrote: > Lorenz Bauer wrote: > > Allow calling bpf_map_update_elem on sockmap and sockhash from a BPF > > context. The synchronization required for this is a bit fiddly: we > > need to prevent the socket from changing it's state while we add it > > to the sockmap, since we rely on ge

Re: [PATCH net 2/3] net: qede: Disable aRFS for NPAR and 100G

2020-08-19 Thread David Miller
From: Dmitry Bogdanov Date: Wed, 19 Aug 2020 23:29:28 +0300 > Fixes: e4917d46a65 ("qede: Add aRFS support") This Fixes tag only has 11 digits of SHA1, when you should provide 12 like the other two patches in this series do. Thank you.

Re: [PATCH net-next v1 2/3] net: openvswitch: refactor flow free function

2020-08-19 Thread David Miller
From: xiangxia.m@gmail.com Date: Tue, 18 Aug 2020 18:09:22 +0800 > Decrease table->count and ufid_count unconditionally, You don't explain why this is a valid transformation. Is it a bug fix? Can it never happen? What are the details and how did you determine this?

[PATCH net-next v2 1/4] ibmvnic: compare adapter->init_done_rc with more readable ibmvnic_rc_codes

2020-08-19 Thread Lijun Pan
Instead of comparing (adapter->init_done_rc == 1), let it be (adapter->init_done_rc == PARTIALSUCCESS). Signed-off-by: Lijun Pan --- drivers/net/ethernet/ibm/ibmvnic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/i

[PATCH net-next v2 4/4] ibmvnic: merge ibmvnic_reset_init and ibmvnic_init

2020-08-19 Thread Lijun Pan
These two functions share the majority of the code, hence merge them together. In the meanwhile, add a reset pass-in parameter to differentiate them. Thus, the code is easier to read and to tell the difference between reset_init and regular init. Signed-off-by: Lijun Pan --- drivers/net/ethernet

[PATCH net-next v2 3/4] ibmvnic: remove never executed if statement

2020-08-19 Thread Lijun Pan
At the beginning of the function, from_passive_init is set false by "adapter->from_passive_init = false;", hence the if statement will never run. Signed-off-by: Lijun Pan --- drivers/net/ethernet/ibm/ibmvnic.c | 12 1 file changed, 12 deletions(-) diff --git a/drivers/net/ethernet/

[PATCH net-next v2 0/4] refactoring of ibmvnic code

2020-08-19 Thread Lijun Pan
This patch series refactor reset_init and init functions, and make some other cosmetic changes to make the code easier to read and debug. v2 removes __func__ and v1's 1/5. Lijun Pan (4): ibmvnic: compare adapter->init_done_rc with more readable ibmvnic_rc_codes ibmvnic: improve ibmvnic_ini

[PATCH net-next v2 2/4] ibmvnic: improve ibmvnic_init and ibmvnic_reset_init

2020-08-19 Thread Lijun Pan
When H_SEND_CRQ command returns with H_CLOSED, it means the server's CRQ is not ready yet. Instead of resetting immediately, we wait for the server to launch passive init. ibmvnic_init() and ibmvnic_reset_init() should also return the error code from ibmvnic_send_crq_init() call. Signed-off-by: Li

Re: [PATCH v4 0/9] ptp: Add generic helper functions

2020-08-19 Thread David Miller
From: Kurt Kanzenbach Date: Tue, 18 Aug 2020 12:32:42 +0200 > in order to reduce code duplication (and cut'n'paste errors) in the ptp code > of > DSA, Ethernet and Phy drivers, create helper functions and move them to > ptp_classify. This way all drivers can share the same implementation. ...

Re: [PATCH net v6] net: xdp: account for layer 3 packets in generic skb handler

2020-08-19 Thread David Miller
From: "Jason A. Donenfeld" Date: Sat, 15 Aug 2020 09:41:02 +0200 > A user reported that packets from wireguard were possibly ignored by XDP > [1]. Another user reported that modifying packets from layer 3 > interfaces results in impossible to diagnose drops. Jason this really is a minefield. If

Re: [PATCH v2 net] ptp: ptp_clockmatrix: use i2c_master_send for i2c write

2020-08-19 Thread David Miller
From: Date: Tue, 18 Aug 2020 10:41:22 -0400 > From: Min Li > > The old code for i2c write would break on some controllers, which fails > at handling Repeated Start Condition. So we will just use i2c_master_send > to handle write in one transanction. > > Changes since v1: > - Remove indentation

Re: [PATCH NET] net: atlantic: Use readx_poll_timeout() for large timeout

2020-08-19 Thread David Miller
From: Sebastian Andrzej Siewior Date: Tue, 18 Aug 2020 18:14:39 +0200 > Commit >8dcf2ad39fdb2 ("net: atlantic: add hwmon getter for MAC temperature") > > implemented a read callback with an udelay(1U). This fails to > compile on ARM because the delay is >1ms. I doubt that it is needed to

Re: [PATCH net-next] ethtool: allow flow-type ether without IP protocol field

2020-08-19 Thread David Miller
From: Vishal Kulkarni Date: Wed, 19 Aug 2020 00:25:03 +0530 > Set IP protocol mask only when IP protocol field is set. > This will allow flow-type ether with vlan rule which don't have > protocol field to apply. > > ethtool -N ens5f4 flow-type ether proto 0x8100 vlan 0x600\ > m 0x1FFF action 3 l

Re: [net-next v3 1/4] devlink: check flash_update parameter support in net core

2020-08-19 Thread David Miller
From: Jacob Keller Date: Tue, 18 Aug 2020 17:28:15 -0700 > @@ -991,6 +993,12 @@ enum devlink_trap_group_generic_id { > } > > struct devlink_ops { > + /** > + * @supported_flash_update_params: > + * mask of parameters supported by the driver's .flash_update > + * implem

Re: [PATCH net v2] net: gemini: Fix missing free_netdev() in error path of gemini_ethernet_port_probe()

2020-08-19 Thread David Miller
From: Wang Hai Date: Wed, 19 Aug 2020 10:33:09 +0800 > Replace alloc_etherdev_mq with devm_alloc_etherdev_mqs. In this way, > when probe fails, netdev can be freed automatically. > > Fixes: 4d5ae32f5e1e ("net: ethernet: Add a driver for Gemini gigabit > ethernet") > Reported-by: Hulk Robot > S

<    1   2   3   4   >