RE: [PATCH] can: flexcan: add LPSR mode support for i.MX7D

2019-08-15 Thread Joakim Zhang
Kindly Ping... Best Regards, Joakim Zhang > -Original Message- > From: Joakim Zhang > Sent: 2019年7月31日 13:57 > To: m...@pengutronix.de; linux-...@vger.kernel.org > Cc: w...@grandegger.com; netdev@vger.kernel.org; dl-linux-imx > ; Joakim Zhang > Subject: [PATCH] can: flexcan: add LPSR mo

RE: [PATCH V2] can: flexcan: fix deadlock when using self wakeup

2019-08-15 Thread Joakim Zhang
Kindly Ping... Best Regards, Joakim Zhang > -Original Message- > From: Joakim Zhang > Sent: 2019年7月30日 10:52 > To: m...@pengutronix.de; linux-...@vger.kernel.org; s...@geanix.com > Cc: w...@grandegger.com; netdev@vger.kernel.org; dl-linux-imx > ; Joakim Zhang > Subject: [PATCH V2] can:

Re: [PATCH] can: flexcan: update hardware feature information for i.MX8QM

2019-08-15 Thread Marc Kleine-Budde
On 8/15/19 9:58 AM, Joakim Zhang wrote: > Update hardware feature information for i.MX8QM. > > Signed-off-by: Joakim Zhang Squashed into "can: flexcan: add imx8qm support" Tnx, Marc -- Pengutronix e.K. | Marc Kleine-Budde | Industrial Linux Solutions| Phone:

Re: [PATCH] can: flexcan: disable completely the ECC mechanism

2019-08-15 Thread Marc Kleine-Budde
On 8/15/19 10:00 AM, Joakim Zhang wrote: > The ECC(memory error detection and correction) mechanism can be > activated or not, controlled by the ECCDIS bit in CAN_MECR. When > disabled, updates on indications and reporting registers are stopped. > So if want to disable ECC completely, had better as

Re: [PATCH bpf-next 0/5] Add support for SKIP_BPF flag for AF_XDP sockets

2019-08-15 Thread Samudrala, Sridhar
On 8/15/2019 12:28 PM, Jakub Kicinski wrote: On Wed, 14 Aug 2019 20:46:18 -0700, Sridhar Samudrala wrote: This patch series introduces XDP_SKIP_BPF flag that can be specified during the bind() call of an AF_XDP socket to skip calling the BPF program in the receive path and pass the buffer dir

Re: [PATCH bpf-next 0/5] Add support for SKIP_BPF flag for AF_XDP sockets

2019-08-15 Thread Samudrala, Sridhar
On 8/15/2019 10:11 AM, Toke Høiland-Jørgensen wrote: "Samudrala, Sridhar" writes: On 8/15/2019 4:12 AM, Toke Høiland-Jørgensen wrote: Sridhar Samudrala writes: This patch series introduces XDP_SKIP_BPF flag that can be specified during the bind() call of an AF_XDP socket to skip calling

Re: [PATCH v2 bpf-next 1/4] bpf: unprivileged BPF access via /dev/bpf

2019-08-15 Thread Song Liu
> On Aug 15, 2019, at 5:54 PM, Andy Lutomirski wrote: > > > >> On Aug 15, 2019, at 4:46 PM, Alexei Starovoitov >> wrote: > > >>> >>> I'm not sure why you draw the line for VMs -- they're just as buggy >>> as anything else. Regardless, I reject this line of thinking: yes, >>> all software

Re: [net-next v2 1/1] tipc: clean up skb list lock handling on send path

2019-08-15 Thread Xin Long
On Thu, Aug 15, 2019 at 11:36 PM Jon Maloy wrote: > > The policy for handling the skb list locks on the send and receive paths > is simple. > > - On the send path we never need to grab the lock on the 'xmitq' list > when the destination is an exernal node. > > - On the receive path we always nee

Re: [PATCH -next v2] btf: fix return value check in btf_vmlinux_init()

2019-08-15 Thread Alexei Starovoitov
On Thu, Aug 15, 2019 at 7:36 PM Wei Yongjun wrote: > > In case of error, the function kobject_create_and_add() returns NULL > pointer not ERR_PTR(). The IS_ERR() test in the return value check > should be replaced with NULL test. > > Fixes: 341dfcf8d78e ("btf: expose BTF info through sysfs") > Sig

Re: [PATCH bpf-next 2/4] selftests/bpf: test_progs: test__skip

2019-08-15 Thread Andrii Nakryiko
On Thu, Aug 15, 2019 at 10:16 PM Alexei Starovoitov wrote: > > On Wed, Aug 14, 2019 at 1:01 PM Andrii Nakryiko > wrote: > > > > > > Let me know if you see a value in highlighting test vs subtest skip. > > > > > > Other related question is: should we do verbose output in case > > > of a skip? Righ

Re: [PATCH bpf-next 2/4] selftests/bpf: test_progs: test__skip

2019-08-15 Thread Alexei Starovoitov
On Wed, Aug 14, 2019 at 1:01 PM Andrii Nakryiko wrote: > > > > Let me know if you see a value in highlighting test vs subtest skip. > > > > Other related question is: should we do verbose output in case > > of a skip? Right now we don't do it. > > It might be useful, I guess, especially if it's no

Re: [PATCH bpf] tools: bpftool: close prog FD before exit on showing a single program

2019-08-15 Thread Alexei Starovoitov
On Thu, Aug 15, 2019 at 7:22 AM Quentin Monnet wrote: > > When showing metadata about a single program by invoking > "bpftool prog show PROG", the file descriptor referring to the program > is not closed before returning from the function. Let's close it. > > Fixes: 71bb428fe2c1 ("tools: bpf: add

Re: [PATCH bpf 0/6] tools: bpftool: fix printf()-like functions

2019-08-15 Thread Alexei Starovoitov
On Thu, Aug 15, 2019 at 7:32 AM Quentin Monnet wrote: > > Hi, > Because the "__printf()" attributes were used only where the functions are > implemented, and not in header files, the checks have not been enforced on > all the calls to printf()-like functions, and a number of errors slipped in > bp

Reminder: 6 active syzbot reports in "net/tls" subsystem

2019-08-15 Thread Eric Biggers
[This email was generated by a script. Let me know if you have any suggestions to make it better, or if you want it re-generated with the latest status.] Of the distinct crashes that syzbot has seen in the last week, I've manually marked 6 of them as possibly being bugs in the "net/tls" subsystem

Reminder: 8 active syzbot reports in "net/bpf" subsystem

2019-08-15 Thread Eric Biggers
[This email was generated by a script. Let me know if you have any suggestions to make it better, or if you want it re-generated with the latest status.] Of the distinct crashes that syzbot has seen in the last week, I've manually marked 8 of them as possibly being bugs in the "net/bpf" subsystem

Re: [PATCH net] tunnel: fix dev null pointer dereference when send pkg larger than mtu in collect_md mode

2019-08-15 Thread Hangbin Liu
On Fri, Aug 16, 2019 at 11:24:18AM +0800, Hangbin Liu wrote: > If yes, how about just set the skb dst to rt->dst, as the > iptunnel_xmit would do later. > > skb_dst_drop(skb); > skb_dst_set(skb, &rt->dst); > Tested and this donesn't work good

Re: [PATCH v2] socket.7: Add description of SO_SELECT_ERR_QUEUE

2019-08-15 Thread Ricardo Biehl Pasquali
TL;DR: This email proposes a description of the socket option SO_SELECT_ERR_QUEUE taking into account the change in wake up behavior when errors are enqueued introduced by the commit 6e5d58fdc9bedd0255a8 ("skbuff: Fix not waking applications when errors are enqueued") in Linux 4.16. On Mon, Jul 29

Re: [PATCH net] tunnel: fix dev null pointer dereference when send pkg larger than mtu in collect_md mode

2019-08-15 Thread Hangbin Liu
Hi Eric, Thanks for the review. On Thu, Aug 15, 2019 at 11:16:58AM +0200, Eric Dumazet wrote: > > diff --git a/net/ipv4/ip_tunnel.c b/net/ipv4/ip_tunnel.c > > index 38c02bb62e2c..c6713c7287df 100644 > > --- a/net/ipv4/ip_tunnel.c > > +++ b/net/ipv4/ip_tunnel.c > > @@ -597,6 +597,9 @@ void ip_md_tu

RECEIVE AND KEEP THIS MONEY FOR ME IN YOUR BANK ACCOUNT,REPLY TO fta447...@gmail.com FOR DETAILS

2019-08-15 Thread RECEIVE AND SECURE THIS MONEY FOR ME

[PATCH -next v2] btf: fix return value check in btf_vmlinux_init()

2019-08-15 Thread Wei Yongjun
In case of error, the function kobject_create_and_add() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Fixes: 341dfcf8d78e ("btf: expose BTF info through sysfs") Signed-off-by: Wei Yongjun Acked-by: Andrii Nakryiko --- kernel/b

Re: [RFC PATCH bpf-next 00/14] xdp_flow: Flow offload to XDP

2019-08-15 Thread Toshiaki Makita
On 2019/08/16 0:46, William Tu wrote: On Tue, Aug 13, 2019 at 5:07 AM Toshiaki Makita wrote: This is a rough PoC for an idea to offload TC flower to XDP. * Motivation The purpose is to speed up software TC flower by using XDP. I chose TC flower because my current interest is in OVS. OVS us

Re: [RFC PATCH bpf-next 00/14] xdp_flow: Flow offload to XDP

2019-08-15 Thread Toshiaki Makita
On 2019/08/16 4:22, Jakub Kicinski wrote: On Thu, 15 Aug 2019 08:21:00 -0700, Stanislav Fomichev wrote: On 08/15, Toshiaki Makita wrote: On 2019/08/15 2:07, Stanislav Fomichev wrote: On 08/13, Toshiaki Makita wrote: * Implementation xdp_flow makes use of UMH to load an eBPF program for XDP,

[PATCH net,v5 1/2] net: sched: use major priority number as hardware priority

2019-08-15 Thread Pablo Neira Ayuso
tc transparently maps the software priority number to hardware. Update it to pass the major priority which is what most drivers expect. Update drivers too so they do not need to lshift the priority field of the flow_cls_common_offload object. The stmmac driver is an exception, since this code assum

[PATCH net,v5 2/2] netfilter: nf_tables: map basechain priority to hardware priority

2019-08-15 Thread Pablo Neira Ayuso
This patch adds initial support for offloading basechains using the priority range from 1 to 65535. This is restricting the netfilter priority range to 16-bit integer since this is what most drivers assume so far from tc. It should be possible to extend this range of supported priorities later on o

[PATCH net,v5 0/2] flow_offload hardware priority fixes

2019-08-15 Thread Pablo Neira Ayuso
Hi, This patchset contains two updates for the flow_offload users: 1) Pass the major tc priority to drivers so they do not have to lshift it. This is a preparation patch for the fix coming in patch #2. 2) Set the hardware priority from the netfilter basechain priority, some drivers brea

Re: [PATCH net-next,v4 07/12] net: sched: use flow block API

2019-08-15 Thread Pablo Neira Ayuso
On Wed, Aug 14, 2019 at 05:32:34PM +0100, Edward Cree wrote: > On 09/07/2019 21:55, Pablo Neira Ayuso wrote: > > This patch adds tcf_block_setup() which uses the flow block API. > > > > This infrastructure takes the flow block callbacks coming from the > > driver and register/unregister to/from the

Re: [RFC PATCH bpf-next 00/14] xdp_flow: Flow offload to XDP

2019-08-15 Thread Toshiaki Makita
On 2019/08/16 0:21, Stanislav Fomichev wrote: On 08/15, Toshiaki Makita wrote: On 2019/08/15 2:07, Stanislav Fomichev wrote: On 08/13, Toshiaki Makita wrote: * Implementation xdp_flow makes use of UMH to load an eBPF program for XDP, similar to bpfilter. The difference is that xdp_flow does n

Re: [PATCH net-next,v4 08/12] drivers: net: use flow block API

2019-08-15 Thread Pablo Neira Ayuso
On Wed, Aug 14, 2019 at 05:17:20PM +0100, Edward Cree wrote: > On 13/08/2019 20:51, Pablo Neira Ayuso wrote: > > On Mon, Aug 12, 2019 at 06:50:09PM +0100, Edward Cree wrote: > >> Pablo, can you explain (because this commit message doesn't) why these per- > >>  driver lists are needed, and what the

Re: [PATCH v2 bpf-next 1/4] bpf: unprivileged BPF access via /dev/bpf

2019-08-15 Thread Andy Lutomirski
> On Aug 15, 2019, at 4:46 PM, Alexei Starovoitov > wrote: >> >> I'm not sure why you draw the line for VMs -- they're just as buggy >> as anything else. Regardless, I reject this line of thinking: yes, >> all software is buggy, but that isn't a reason to give up. > > hmm. are you saying y

[RFC PATCH net-next 07/11] spi: spi-fsl-dspi: Add a debugging GPIO for monitoring latency

2019-08-15 Thread Vladimir Oltean
This is being used to monitor the time it takes to transmit individual bytes over SPI to the slave device. It is used in conjunction with the PTP system timestamp feature - only the byte that was requested to be timestamped triggers a toggle of the GPIO pin. Signed-off-by: Vladimir Oltean --- dr

[RFC PATCH net-next 11/11] ARM: dts: ls1021a-tsn: Reduce the SJA1105 SPI frequency for debug

2019-08-15 Thread Vladimir Oltean
I have a logic analyzer that cannot sample signals at a higher frequency than this, and it's nice to actually see the captured data and not just an amorphous mess. Signed-off-by: Vladimir Oltean --- arch/arm/boot/dts/ls1021a-tsn.dts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --g

[RFC PATCH net-next 04/11] spi: spi-fsl-dspi: Cosmetic cleanup

2019-08-15 Thread Vladimir Oltean
This patch addresses some cosmetic issues: - Alignment - Typos - (Non-)use of BIT() and GENMASK() macros - Unused definitions - Unused includes - Abuse of ternary operator in detriment of readability - Reduce indentation level Signed-off-by: Vladimir Oltean --- drivers/spi/spi-fsl-dspi.c | 312 +

[RFC PATCH net-next 03/11] spi: Add a PTP system timestamp to the transfer structure

2019-08-15 Thread Vladimir Oltean
SPI is one of the interfaces used to access devices which have a POSIX clock driver (real time clocks, 1588 timers etc). Since there are lots of sources of timing jitter when retrieving the time from such a device (controller delays, locking contention etc), introduce a PTP system timestamp struct

[RFC PATCH net-next 08/11] spi: spi-fsl-dspi: Disable interrupts and preemption during poll mode transfer

2019-08-15 Thread Vladimir Oltean
While the poll mode helps reduce the overall latency in transmitting a SPI message in the EOQ and TCFQ modes, the transmission can still have jitter due to the CPU needing to service interrupts. The transmission latency does not matter except in situations where the SPI transfer represents the rea

[RFC PATCH net-next 06/11] spi: spi-fsl-dspi: Implement the PTP system timestamping

2019-08-15 Thread Vladimir Oltean
This adds a snapshotting software feature for TCFQ and EOQ modes of operation. Due to my lack of proper understanding of the DMA mode, the latter mode is left as an exercise for future developers. Signed-off-by: Vladimir Oltean --- drivers/spi/spi-fsl-dspi.c | 18 ++ 1 file chang

[RFC PATCH net-next 05/11] spi: spi-fsl-dspi: Use poll mode in case the platform IRQ is missing

2019-08-15 Thread Vladimir Oltean
On platforms like LS1021A which use TCFQ mode, an interrupt needs to be processed after each byte is TXed/RXed. I tried to make the DSPI implementation on this SoC operate in other, more efficient modes (EOQ, DMA) but it looks like it simply isn't possible. Therefore allow the driver to operate in

[RFC PATCH net-next 10/11] ARM: dts: ls1021a-tsn: Use the DSPI controller in poll mode

2019-08-15 Thread Vladimir Oltean
Connected to the LS1021A DSPI is the SJA1105 DSA switch. This constitutes 4 of the 6 Ethernet ports on this board. When using the board as a PTP switch and bridging all 6 ports under one single L2 entity, it is good to also have the PTP clocks of the switch and of the standalone Ethernet ports in s

[RFC PATCH net-next 01/11] net: dsa: sja1105: Add a debugging GPIO for monitoring SPI latency

2019-08-15 Thread Vladimir Oltean
I am using this to monitor the gettimex64 callback jitter, i.e. the time it takes for the SPI controller to retrieve the PTP time from the switch, and therefore the uncertainty in the time that has just been read. Signed-off-by: Vladimir Oltean --- drivers/net/dsa/sja1105/sja1105.h | 4 +++

[RFC PATCH net-next 02/11] net: dsa: sja1105: Implement the .gettimex64 system call for PTP

2019-08-15 Thread Vladimir Oltean
Through the PTP_SYS_OFFSET_EXTENDED ioctl, it is possible for userspace applications (i.e. phc2sys) to compensate for the delays incurred while reading the PHC's time. Implement this ioctl by passing the PTP system timestamp to the switch's SPI controller driver. The 'read PTP time' message is a

[RFC PATCH net-next 09/11] ARM: dts: ls1021a-tsn: Add debugging GPIOs for the SJA1105 and DSPI drivers

2019-08-15 Thread Vladimir Oltean
These GPIOs are exported to the expansion pin header at the rear of the board: EXP1_GPIO7: row 1, pin 9 from left EXP1_GPIO6: row 1, pin 8 from left Experimentally I could only see EXP1_GPIO6 (the pin currently assigned to the DSPI driver) actually toggle on an analyzer - I don't know why, but on

[RFC PATCH net-next 00/11] Deterministic SPI latency on NXP

2019-08-15 Thread Vladimir Oltean
Continuing the discussion created by Hubert Feurstein around the mv88e6xxx driver for MDIO-controlled switches (https://lkml.org/lkml/2019/8/2/1364), this patchset takes a similar approach for the NXP LS1021A-TSN board, which has a SPI-controlled DSA switch (SJA1105). The patchset is motivated by

Re: [PATCH v3 bpf-next] libbpf: make libbpf.map source of truth for libbpf version

2019-08-15 Thread Alexei Starovoitov
On Wed, Aug 14, 2019 at 3:16 PM Andrey Ignatov wrote: > > Andrii Nakryiko [Wed, 2019-08-14 13:57 -0700]: > > Currently libbpf version is specified in 2 places: libbpf.map and > > Makefile. They easily get out of sync and it's very easy to update one, > > but forget to update another one. In addit

Re: [v5,0/4] tools: bpftool: add net attach/detach command to attach XDP prog

2019-08-15 Thread Alexei Starovoitov
On Tue, Aug 13, 2019 at 2:43 PM Jakub Kicinski wrote: > > On Tue, 13 Aug 2019 11:46:17 +0900, Daniel T. Lee wrote: > > Currently, bpftool net only supports dumping progs attached on the > > interface. To attach XDP prog on interface, user must use other tool > > (eg. iproute2). By this patch, with

Re: [PATCH v2 bpf-next 1/4] bpf: unprivileged BPF access via /dev/bpf

2019-08-15 Thread Alexei Starovoitov
On Thu, Aug 15, 2019 at 12:46:41PM -0700, Kees Cook wrote: > On Tue, Aug 13, 2019 at 02:58:25PM -0700, Alexei Starovoitov wrote: > > agree that containers (namespaces) reduce amount of trust necessary > > for apps to run, but the end goal is not security though. > > Unsurprisingly, I totally disag

Re: [PATCH net-next 4/4 v2] net: ethernet: mediatek: Add MT7628/88 SoC support

2019-08-15 Thread David Miller
From: Stefan Roese Date: Wed, 14 Aug 2019 13:18:25 +0200 > +static int txd_to_idx(struct mtk_tx_ring *ring, struct mtk_tx_dma *dma) > +{ > + return ((u32)dma - (u32)ring->dma) / sizeof(*dma); > +} This will definitely warn on 64-bit, and you should avoid that even if this driver can not poss

Re: [PATCH net-next v6 0/6] net: mscc: PTP Hardware Clock (PHC) support

2019-08-15 Thread David Miller
From: Antoine Tenart Date: Mon, 12 Aug 2019 16:45:31 +0200 > This series introduces the PTP Hardware Clock (PHC) support to the Mscc > Ocelot switch driver. In order to make use of this, a new register bank > is added and described in the device tree, as well as a new interrupt. > The use this ba

Re: [PATCH v2 bpf-next 1/4] bpf: unprivileged BPF access via /dev/bpf

2019-08-15 Thread Alexei Starovoitov
On Thu, Aug 15, 2019 at 11:36:43AM -0700, Andy Lutomirski wrote: > On Thu, Aug 15, 2019 at 10:29 AM Alexei Starovoitov > wrote: > > > > On Thu, Aug 15, 2019 at 11:24:54AM +, Jordan Glover wrote: > > > systemd --user processes aren't "less privileged". The are COMPLETELY > > > unprivileged. >

Re: [PATCH net-next v6 6/6] net: mscc: PTP Hardware Clock (PHC) support

2019-08-15 Thread Richard Cochran
On Wed, Aug 14, 2019 at 12:49:39PM -0400, David Miller wrote: > From: Antoine Tenart > Date: Mon, 12 Aug 2019 16:45:37 +0200 > > > This patch adds support for PTP Hardware Clock (PHC) to the Ocelot > > switch for both PTP 1-step and 2-step modes. > > > > Signed-off-by: Antoine Tenart > > Richa

Re: [PATCH net-next 2/3] tcp: ulp: add functions to dump ulp-specific information

2019-08-15 Thread Jakub Kicinski
On Thu, 15 Aug 2019 20:46:01 +0200, Eric Dumazet wrote: > On 8/15/19 6:00 PM, Davide Caratti wrote: > > > > > + if (net_admin) { > > + const struct tcp_ulp_ops *ulp_ops; > > + > > + rcu_read_lock(); > > + ulp_ops = icsk->icsk_ulp_ops; > > + if (ulp_ops)

Re: [PATCH net-next 1/3] net/tls: use RCU protection on icsk->icsk_ulp_data

2019-08-15 Thread Jakub Kicinski
On Thu, 15 Aug 2019 18:00:42 +0200, Davide Caratti wrote: > From: Jakub Kicinski > > We need to make sure context does not get freed while diag > code is interrogating it. Free struct tls_context with > kfree_rcu(). > > We add the __rcu annotation directly in icsk, and cast it > away in the data

Re: [PATCH bpf 1/1] xdp: unpin xdp umem pages in error path

2019-08-15 Thread Jonathan Lemon
On 15 Aug 2019, at 13:56, Ivan Khoronzhuk wrote: > Fix mem leak caused by missed unpin routine for umem pages. > Fixes: 8aef7340ae9695 ("commit xsk: introduce xdp_umem_page") > > Signed-off-by: Ivan Khoronzhuk Acked-by: Jonathan Lemon

Re: [PATCH 0/7] Netfilter fixes for net

2019-08-15 Thread David Miller
From: Pablo Neira Ayuso Date: Wed, 14 Aug 2019 11:24:33 +0200 > This patchset contains Netfilter fixes for net: > > 1) Extend selftest to cover flowtable with ipsec, from Florian Westphal. > > 2) Fix interaction of ipsec with flowtable, also from Florian. > > 3) User-after-free with bound set

Re: [PATCH net] net/packet: fix race in tpacket_snd()

2019-08-15 Thread David Miller
From: Eric Dumazet Date: Wed, 14 Aug 2019 02:11:57 -0700 > packet_sendmsg() checks tx_ring.pg_vec to decide > if it must call tpacket_snd(). > > Problem is that the check is lockless, meaning another thread > can issue a concurrent setsockopt(PACKET_TX_RING ) to flip > tx_ring.pg_vec back to NUL

Re: [PATCH bpf] tools: bpftool: close prog FD before exit on showing a single program

2019-08-15 Thread Andrii Nakryiko
On Thu, Aug 15, 2019 at 11:09 AM Jakub Kicinski wrote: > > On Thu, 15 Aug 2019 11:05:16 -0700, Andrii Nakryiko wrote: > > > > Would it be better to make show_prog(fd) close provided fd instead or > > > > is it used in some other context where FD should live longer (I > > > > haven't checked, sorry

Re: [PATCH net-next v4 0/2] qed*: Support for NVM config attributes.

2019-08-15 Thread David Miller
From: Sudarsana Reddy Kalluru Date: Wed, 14 Aug 2019 01:11:51 -0700 > The patch series adds support for managing the NVM config attributes. > Patch (1) adds functionality to update config attributes via MFW. > Patch (2) adds driver interface for updating the config attributes. > > Changes from p

[PATCH] net: cavium: fix driver name

2019-08-15 Thread Stephen Hemminger
The driver name gets exposed in sysfs under /sys/bus/pci/drivers so it should look like other devices. Change it to be common format (instead of "Cavium PTP"). This is a trivial fix that was observed by accident because Debian kernels were building this driver into kernel (bug). Signed-off-by: St

[PATCH mlx5-next 5/5] net/mlx5: Add lag_tx_port_affinity capability bit

2019-08-15 Thread Saeed Mahameed
From: Maxim Mikityanskiy Add the lag_tx_port_affinity HCA capability bit that indicates that setting port affinity of TISes is supported. Signed-off-by: Maxim Mikityanskiy Reviewed-by: Tariq Toukan Signed-off-by: Saeed Mahameed --- include/linux/mlx5/mlx5_ifc.h | 4 +++- 1 file changed, 3 in

[PATCH mlx5-next 1/5] net/mlx5: Add missing include file to lib/crypto.c

2019-08-15 Thread Saeed Mahameed
Add missing include file to avoid compiler warnings: drivers/net/ethernet/mellanox/mlx5/core//lib/crypto.c:6:5: warning: no previous prototype for ‘mlx5_create_encryption_key’ 6 | int mlx5_create_encryption_key(struct mlx5_core_dev *mdev, | ^~ drivers/net/ether

Re: [PATCH v2 bpf-next 1/4] bpf: unprivileged BPF access via /dev/bpf

2019-08-15 Thread Kees Cook
On Tue, Aug 13, 2019 at 02:58:25PM -0700, Alexei Starovoitov wrote: > agree that containers (namespaces) reduce amount of trust necessary > for apps to run, but the end goal is not security though. Unsurprisingly, I totally disagree: this is the very definition of improved "security": reduced atta

[PATCH mlx5-next 3/5] net/mlx5: Add support for VNIC_ENV internal rq counter

2019-08-15 Thread Saeed Mahameed
From: Moshe Shemesh Add mlx5 interface support for reading internal rq out of buffer counter as part of QUERY_VNIC_ENV command. The command is used by the driver to query vnic diagnostic statistics from FW. Signed-off-by: Moshe Shemesh Signed-off-by: Saeed Mahameed --- include/linux/mlx5/mlx5

[PATCH mlx5-next 2/5] net/mlx5: Improve functions documentation

2019-08-15 Thread Saeed Mahameed
Fix documentation of mlx5_eq_enable/disable to cleanup compiler warnings. drivers/net/ethernet/mellanox/mlx5/core//eq.c:334: warning: Function parameter or member 'dev' not described in 'mlx5_eq_enable' warning: Function parameter or member 'eq' not described in 'mlx5_eq_enable' warning: Function

[PATCH mlx5-next 4/5] net/mlx5: Expose IP-in-IP capability bit

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Expose Fw indication that it supports Stateless Offloads for IP over IP tunneled packets. The following offloads are supported for the inner packets: RSS, RX & TX Checksum Offloads, LSO and Flow Steering. Signed-off-by: Aya Levin Reviewed-by: Tariq Toukan Signed-off-by: Saeed M

[PATCH mlx5-next 0/5] Mellanox, Updates for mlx5-next branch 2019-08-15

2019-08-15 Thread Saeed Mahameed
Hi All, This series includes misc updates for mlx5-next shared branch. mlx5 HW spec and bits updates: 1) Aya exposes IP-in-IP capability in mlx5_core. 2) Maxim exposes lag tx port affinity capabilities. 3) Moshe adds VNIC_ENV internal rq counter bits. Misc updates: 4) Saeed, two compiler warning

Re: pull-request: can-next 2019-08-14,pull-request: can-next 2019-08-14

2019-08-15 Thread David Miller
From: Marc Kleine-Budde Date: Wed, 14 Aug 2019 08:16:24 +0200 > this is a pull request for net-next/master consisting of 41 patches. ... Pulled, thanks Marc.

Re: [net PATCH] net: tls, fix sk_write_space NULL write when tx disabled

2019-08-15 Thread David Miller
From: John Fastabend Date: Wed, 14 Aug 2019 05:31:54 + > The ctx->sk_write_space pointer is only set when TLS tx mode is enabled. > When running without TX mode its a null pointer but we still set the > sk sk_write_space pointer on close(). > > Fix the close path to only overwrite sk->sk_wri

Re: [PATCH bpf-next 0/5] Add support for SKIP_BPF flag for AF_XDP sockets

2019-08-15 Thread Jakub Kicinski
On Wed, 14 Aug 2019 20:46:18 -0700, Sridhar Samudrala wrote: > This patch series introduces XDP_SKIP_BPF flag that can be specified > during the bind() call of an AF_XDP socket to skip calling the BPF > program in the receive path and pass the buffer directly to the socket. > > When a single AF_X

Re: [PATCH net-next] page_pool: fix logic in __page_pool_get_cached

2019-08-15 Thread David Miller
From: Jonathan Lemon Date: Tue, 13 Aug 2019 10:45:09 -0700 > __page_pool_get_cached() will return NULL when the ring is > empty, even if there are pages present in the lookaside cache. > > It is also possible to refill the cache, and then return a > NULL page. > > Restructure the logic so elimi

Re: [RFC PATCH bpf-next 00/14] xdp_flow: Flow offload to XDP

2019-08-15 Thread Jakub Kicinski
On Thu, 15 Aug 2019 08:21:00 -0700, Stanislav Fomichev wrote: > On 08/15, Toshiaki Makita wrote: > > On 2019/08/15 2:07, Stanislav Fomichev wrote: > > > On 08/13, Toshiaki Makita wrote: > > > > * Implementation > > > > > > > > xdp_flow makes use of UMH to load an eBPF program for XDP, similar

[net-next 11/16] net/mlx5e: Report and recover from rx timeout

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Add support for report and recovery from rx timeout. On driver open we post NOP work request on the rx channels to trigger napi in order to fillup the rx rings. In case napi wasn't scheduled due to a lost interrupt, perform EQ recovery. Signed-off-by: Aya Levin Reviewed-by: Tari

[net-next 13/16] net/mlx5e: Report and recover from CQE with error on RQ

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Add support for report and recovery from error on completion on RQ by setting the queue back to ready state. Handle only errors with a syndrome indicating the RQ might enter error state and could be recovered. Signed-off-by: Aya Levin Reviewed-by: Tariq Toukan Acked-by: Jiri Pi

[net-next 08/16] net/mlx5e: Add support to rx reporter diagnose

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Add rx reporter, which supports diagnose call-back. Diagnostics output include: information common to all RQs: RQ type, RQ size, RQ stride size, CQ size and CQ stride size. In addition advertise information per RQ and its related icosq and attached CQ. $ devlink health diagnose p

[net-next 14/16] Documentation: net: mlx5: Devlink health documentation updates

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Add documentation for devlink health rx reporter supported by mlx5. Update tx reporter documentation. Signed-off-by: Aya Levin Signed-off-by: Saeed Mahameed --- .../device_drivers/mellanox/mlx5.rst | 33 +-- 1 file changed, 31 insertions(+), 2 deletion

[net-next 12/16] net/mlx5e: RX, Handle CQE with error at the earliest stage

2019-08-15 Thread Saeed Mahameed
Just to be aligned with the MPWQE handlers, handle RX WQE with error for legacy RQs in the top RX handlers, just before calling skb_from_cqe(). CQE error handling will now be called at the same stage regardless of the RQ type or netdev mode NIC, Representor, IPoIB, etc .. This will be useful for

[net-next 16/16] net/mlx5: Fix the order of fc_stats cleanup

2019-08-15 Thread Saeed Mahameed
From: Gavi Teitz Previously, mlx5_cleanup_fc_stats() would cleanup the flow counter pool beofre releasing all the counters to it, which would result in flow counter bulks not getting freed. Resolve this by changing the order in which elements of fc_stats are cleaned up, so that the flow counter p

[net-next 15/16] net/mlx5e: Fix deallocation of non-fully init encap entries

2019-08-15 Thread Saeed Mahameed
From: Vlad Buslov Recent rtnl lock dependency refactoring changed encap entry attach code to insert encap entry to hash table before it was fully initialized in order to allow concurrent tc users to wait on completion for encap entry to finish initialization. That change required all the users of

[net-next 06/16] net/mlx5e: Add cq info to tx reporter diagnose

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Add cq information to general diagnose output: CQ size and stride size. Per SQ add information about the related CQ: cqn and CQ's HW status. $ devlink health diagnose pci/:00:0b.0 reporter tx Common Config: SQ: stride size: 64 size: 1024 CQ: stride size: 64 s

[net-next 10/16] net/mlx5e: Report and recover from CQE error on ICOSQ

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Add support for report and recovery from error on completion on ICOSQ. Deactivate RQ and flush, then deactivate ICOSQ. Set the queue back to ready state (firmware) and reset the ICOSQ and the RQ (software resources). Finally, activate the ICOSQ and the RQ. Signed-off-by: Aya Levi

[net-next 09/16] net/mlx5e: Split open/close ICOSQ into stages

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Align ICOSQ open/close behaviour with RQ and SQ. Split open flow into open and activate where open handles creation and activate enables the queue. Do a symmetric thing in close flow: split into close and deactivate. Signed-off-by: Aya Levin Reviewed-by: Tariq Toukan Acked-by:

[net-next 04/16] net/mlx5e: Extend tx diagnose function

2019-08-15 Thread Saeed Mahameed
From: Aya Levin The following patches in the set enhance the diagnostics info of tx reporter. Therefore, it is better to pass a pointer to the SQ for further data extraction. Signed-off-by: Aya Levin Reviewed-by: Tariq Toukan Acked-by: Jiri Pirko Signed-off-by: Saeed Mahameed --- .../mellan

[net-next 05/16] net/mlx5e: Extend tx reporter diagnostics output

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Enhance tx reporter's diagnostics output to include: information common to all SQs: SQ size, SQ stride size. In addition add channel ix, tc, txq ix, cc and pc. $ devlink health diagnose pci/:00:0b.0 reporter tx Common config: SQ: stride size: 64 size: 1024 SQs: c

Re: [pull request][net 0/2] Mellanox, mlx5 fixes 2019-08-15

2019-08-15 Thread David Miller
From: Saeed Mahameed Date: Thu, 15 Aug 2019 18:47:04 + > This series introduces two fixes to mlx5 driver. > > 1) Eran fixes a compatibility issue with ethtool flash. > 2) Maxim fixes a race in XSK wakeup flow. > > Please pull and let me know if there is any problem. Pulled, thank you.

[pull request][net-next 00/16] Mellanox, mlx5 devlink RX health reporters

2019-08-15 Thread Saeed Mahameed
Hi Dave, This series is adding a new devlink health reporter for RX related errors from Aya. Last two patches from Vlad and Gavi, are trivial fixes for previously submitted patches on this release cycle. For more information please see tag log below. Please pull and let me know if there is any

[net-next 01/16] net/mlx5e: Rename reporter header file

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Rename reporter.h -> health.h so patches in the set can use it for health related functionality. Signed-off-by: Aya Levin Reviewed-by: Tariq Toukan Acked-by: Jiri Pirko Signed-off-by: Saeed Mahameed --- .../ethernet/mellanox/mlx5/core/en/{reporter.h => health.h} | 4 ++--

[net-next 02/16] net/mlx5e: Change naming convention for reporter's functions

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Change from mlx5e_tx_reporter_* to mlx5e_reporter_tx_*. In the following patches in the set rx reporter is added, the new naming convention is more uniformed. Signed-off-by: Aya Levin Reviewed-by: Tariq Toukan Acked-by: Jiri Pirko Signed-off-by: Saeed Mahameed --- drivers/ne

[net-next 07/16] net/mlx5e: Add helper functions for reporter's basics

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Introduce helper functions for create and destroy reporters and update channels. In the following patch, rx reporter is added and it will use these helpers too. Signed-off-by: Aya Levin Reviewed-by: Tariq Toukan Acked-by: Jiri Pirko Signed-off-by: Saeed Mahameed --- .../net/

[net-next 03/16] net/mlx5e: Generalize tx reporter's functionality

2019-08-15 Thread Saeed Mahameed
From: Aya Levin Prepare for code sharing with rx reporter, which is added in the following patches in the set. Introduce a generic error_ctx for agnostic recovery despatch. Signed-off-by: Aya Levin Reviewed-by: Tariq Toukan Acked-by: Jiri Pirko Signed-off-by: Saeed Mahameed --- .../net/ethe

Re: [PATCH net-next v2 0/4] net/rds: Fixes from internal Oracle repo

2019-08-15 Thread David Miller
From: Gerd Rausch Date: Thu, 15 Aug 2019 07:40:22 -0700 > This is the first set of (mostly old) patches from our internal repository > in an effort to synchronize what Oracle had been using internally > with what is shipped with the Linux kernel. Series applied.

Re: [patch net-next v4 0/2] netdevsim: implement support for devlink region and snapshots

2019-08-15 Thread David Miller
From: Jiri Pirko Date: Thu, 15 Aug 2019 15:46:32 +0200 > From: Jiri Pirko > > Implement devlink region support for netdevsim and test it. > > --- > Note the selftest patch depends on "[patch net-next] selftests: > netdevsim: add devlink params tests" patch sent earlier today. Series applied.

Re: [patch net-next v3 0/2] selftests: netdevsim: add devlink paramstests

2019-08-15 Thread David Miller
From: Jiri Pirko Date: Thu, 15 Aug 2019 15:42:27 +0200 > From: Jiri Pirko > > The first patch is just a helper addition as a dependency of the actual > test in patch number two. Series applied.

Re: [PATCH net-next] r8169: sync EEE handling for RTL8168h with vendor driver

2019-08-15 Thread David Miller
From: Heiner Kallweit Date: Thu, 15 Aug 2019 14:21:30 +0200 > Sync EEE init for RTL8168h with vendor driver and add two writes to > vendor-specific registers. > > Signed-off-by: Heiner Kallweit Applied.

Re: [PATCH net-next v2 0/2] net: phy: realtek: map vendor-specific EEE registers to standard MMD registers

2019-08-15 Thread David Miller
From: Heiner Kallweit Date: Thu, 15 Aug 2019 14:12:10 +0200 > EEE-related registers on newer integrated PHY's have the standard > layout, but are accessible not via MMD but via vendor-specific > registers. Emulating the standard MMD registers allows to use the > generic functions for EEE control

[net 1/2] net/mlx5e: Fix a race with XSKICOSQ in XSK wakeup flow

2019-08-15 Thread Saeed Mahameed
From: Maxim Mikityanskiy Add a missing spinlock around XSKICOSQ usage at the activation stage, because there is a race between a configuration change and the application calling sendto(). Fixes: db05815b36cb ("net/mlx5e: Add XSK zero-copy support") Signed-off-by: Maxim Mikityanskiy Reviewed-by:

[net 2/2] net/mlx5e: Fix compatibility issue with ethtool flash device

2019-08-15 Thread Saeed Mahameed
From: Eran Ben Elisha Cited patch deleted ethtool flash device support, as ethtool core can fallback into devlink flash callback. However, this is supported only if there is a devlink port registered over the corresponding netdevice. As mlx5e do not have devlink port support over native netdevic

[pull request][net 0/2] Mellanox, mlx5 fixes 2019-08-15

2019-08-15 Thread Saeed Mahameed
Hi Dave, This series introduces two fixes to mlx5 driver. 1) Eran fixes a compatibility issue with ethtool flash. 2) Maxim fixes a race in XSK wakeup flow. Please pull and let me know if there is any problem. Thanks, Saeed. --- The following changes since commit 2aafdf5a5786ebbd8ccfe132ed6267c

Re: [PATCH net-next 2/3] tcp: ulp: add functions to dump ulp-specific information

2019-08-15 Thread Eric Dumazet
On 8/15/19 6:00 PM, Davide Caratti wrote: > > + if (net_admin) { > + const struct tcp_ulp_ops *ulp_ops; > + > + rcu_read_lock(); > + ulp_ops = icsk->icsk_ulp_ops; > + if (ulp_ops) > + err = tcp_diag_put_ulp(skb, sk, ulp_o

Re: [PATCH net-next] net: phy: swphy: emulate register MII_ESTATUS

2019-08-15 Thread David Miller
From: Heiner Kallweit Date: Thu, 15 Aug 2019 13:19:22 +0200 > When the genphy driver binds to a swphy it will call > genphy_read_abilites that will try to read MII_ESTATUS if BMSR_ESTATEN > is set in MII_BMSR. So far this would read the default value 0x > and 1000FD and 1000HD are reported as

Re: [PATCH v2 bpf-next 1/4] bpf: unprivileged BPF access via /dev/bpf

2019-08-15 Thread Jordan Glover
On Thursday, August 15, 2019 5:28 PM, Alexei Starovoitov wrote: > On Thu, Aug 15, 2019 at 11:24:54AM +, Jordan Glover wrote: > > > On Wednesday, August 14, 2019 10:05 PM, Alexei Starovoitov > > alexei.starovoi...@gmail.com wrote: > > > > > On Wed, Aug 14, 2019 at 10:51:23AM -0700, Andy Luto

Re: [PATCH net-next] net: phy: read MII_CTRL1000 in genphy_read_status only if needed

2019-08-15 Thread David Miller
From: Heiner Kallweit Date: Thu, 15 Aug 2019 13:15:19 +0200 > Value of MII_CTRL1000 is needed only if LPA_1000MSFAIL is set. > Therefore move reading this register. > > Signed-off-by: Heiner Kallweit Applied.

Re: [PATCH net-next] net/rds: Add RDS6_INFO_SOCKETS and RDS6_INFO_RECV_MESSAGES options

2019-08-15 Thread David Miller
From: Ka-Cheong Poon Date: Thu, 15 Aug 2019 02:36:43 -0700 > Add support of the socket options RDS6_INFO_SOCKETS and > RDS6_INFO_RECV_MESSAGES which update the RDS_INFO_SOCKETS and > RDS_INFO_RECV_MESSAGES options respectively. The old options work > for IPv4 sockets only. > > Signed-off-by: Ka

Re: [PATCH v2 bpf-next 1/4] bpf: unprivileged BPF access via /dev/bpf

2019-08-15 Thread Andy Lutomirski
On Thu, Aug 15, 2019 at 10:29 AM Alexei Starovoitov wrote: > > On Thu, Aug 15, 2019 at 11:24:54AM +, Jordan Glover wrote: > > systemd --user processes aren't "less privileged". The are COMPLETELY > > unprivileged. > > Granting them cap_bpf is the same as granting it to every other > > unpriv

  1   2   3   >