[net-next 04/15] igc: Remove useless forward declaration

2019-08-27 Thread Jeff Kirsher
From: Sasha Neftin Move igc_phy_setup_autoneg, igc_wait_autoneg and igc_set_fc_watermarks up to avoid forward declaration. It is not necessary to forward declare these static methods. Signed-off-by: Sasha Neftin Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/inte

[net-next 08/15] iavf: allow permanent MAC address to change

2019-08-27 Thread Jeff Kirsher
From: Mitch Williams Allow the VF to override the "permanent" MAC address set by the host. This allows bonding to work in the case where the administrator has set the VF MAC. Note that the VF must still be set to Trusted on the host if this change is to be accepted by the PF driver. Signed-off-

[net-next 05/15] Documentation: iavf: Update the Intel LAN driver doc for iavf

2019-08-27 Thread Jeff Kirsher
Update the LAN driver documentation to include the latest feature implementation and driver capabilities. Signed-off-by: Jeff Kirsher Tested-by: Aaron Brown --- .../networking/device_drivers/intel/iavf.rst | 115 +- 1 file changed, 82 insertions(+), 33 deletions(-) diff --git

[net-next 15/15] i40e: Add support for X710 device

2019-08-27 Thread Jeff Kirsher
From: Mariusz Stachura Add I40E_DEV_ID_10G_BASE_T_BC to i40e_pci_tbl Signed-off-by: Mariusz Stachura Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/intel/i40e/i40e_main.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/net/ethernet/intel/i40e/i40e_m

[net-next 07/15] igc: Add NVM checksum validation

2019-08-27 Thread Jeff Kirsher
From: Sasha Neftin Add NVM checksum validation during probe functionality. Signed-off-by: Sasha Neftin Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/intel/igc/igc_main.c | 9 + 1 file changed, 9 insertions(+) diff --git a/drivers/net/ethernet/intel/igc/

[net-next 09/15] igc: Remove unneeded PCI bus defines

2019-08-27 Thread Jeff Kirsher
From: Sasha Neftin PCIe device control 2 defines does not use internally. This patch comes to clean up those. Signed-off-by: Sasha Neftin Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/intel/igc/igc_defines.h | 4 1 file changed, 4 deletions(-) diff --git a

[net-next 01/15] iavf: remove unused debug function iavf_debug_d

2019-08-27 Thread Jeff Kirsher
From: YueHaibing There is no caller of function iavf_debug_d() in tree since commit 75051ce4c5d8 ("iavf: Fix up debug print macro"), so it can be removed. Reported-by: Hulk Robot Signed-off-by: YueHaibing Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/intel/ia

[net-next 00/15][pull request] Intel Wired LAN Driver Updates 2019-08-27

2019-08-27 Thread Jeff Kirsher
This series contains a variety of cold and hot savoury changes to Intel drivers. Some of the fixes could be considered for stable even though the author did not request it. Hulk Robert cleans up (i.e. removes) a function that has no caller for the iavf driver. Radoslaw fixes an issue when there

[net-next 14/15] igc: Add tx_csum offload functionality

2019-08-27 Thread Jeff Kirsher
From: Sasha Neftin Add IP generic TX checksum offload functionality. Signed-off-by: Sasha Neftin Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/intel/igc/igc.h | 4 + drivers/net/ethernet/intel/igc/igc_base.h| 8 ++ drivers/net/ethernet/intel/igc/ig

[net-next 02/15] ixgbevf: Link lost in VM on ixgbevf when restoring from freeze or suspend

2019-08-27 Thread Jeff Kirsher
From: Radoslaw Tyl This patch fixed issue in VM which shows no link when hypervisor is restored from low-power state. The driver is responsible for re-enabling any features of the device that had been disabled during suspend calls, such as IRQs and bus mastering. Signed-off-by: Radoslaw Tyl Tes

[net-next 11/15] i40e: Implement debug macro hw_dbg using pr_debug

2019-08-27 Thread Jeff Kirsher
From: "Mauro S. M. Rodrigues" There are several uses of hw_dbg in the code, producing no output. This patch implements it using pr_debug. Initially the intention was to implement it using netdev_dbg, analogously to what is done in ixgbe for instance. That approach was avoided due to some early u

[net-next 06/15] fm10k: use a local variable for the frag pointer

2019-08-27 Thread Jeff Kirsher
From: Jacob Keller In the function fm10k_xmit_frame_ring, we recently switched to using the skb_frag_size accessor instead of directly using the size member of the skb fragment. This made the for loop slightly harder to read because it created a very long line that is difficult to split up. Avoi

[net-next 13/15] ixgbe: sync the first fragment unconditionally

2019-08-27 Thread Jeff Kirsher
From: Firo Yang In Xen environment, if Xen-swiotlb is enabled, ixgbe driver could possibly allocate a page, DMA memory buffer, for the first fragment which is not suitable for Xen-swiotlb to do DMA operations. Xen-swiotlb have to internally allocate another page for doing DMA operations. This mec

[net-next 10/15] i40e: fix hw_dbg usage in i40e_hmc_get_object_va

2019-08-27 Thread Jeff Kirsher
From: "Mauro S. M. Rodrigues" The mentioned function references a i40e_hw attribute, as parameter for hw_dbg, but it doesn't exist in the function scope. Fixes it by changing parameters from i40e_hmc_info to i40e_hw which can retrieve the necessary i40e_hmc_info. Signed-off-by: "Mauro S. M. Rodr

[net-next 12/15] i40e: Remove EMPR traces from debugfs facility

2019-08-27 Thread Jeff Kirsher
From: "Mauro S. M. Rodrigues" Since commit '5098850c9b9b ("i40e/i40evf: i40e_register.h updates")' it is no longer possible to trigger an EMP Reset from debugfs, but it's possible to request it either way, to end up with a bad reset request: echo empr > /sys/kernel/debug/i40e/0002\:01\:00.1/comm

[net-next 03/15] e1000e: Make speed detection on hotplugging cable more reliable

2019-08-27 Thread Jeff Kirsher
From: Kai-Heng Feng After hot plugging an 1Gbps Ethernet cable with 1Gbps link partner, the MII_BMSR may report 10Mbps, renders the network rather slow. The issue has much lower fail rate after commit 59653e6497d1 ("e1000e: Make watchdog use delayed work"), which essentially introduces some dela

Re: [PATCH net-next v2 2/3] dt-bindings: net: dsa: mt7530: Add support for port 5

2019-08-27 Thread René van Dorst
Hi Rob, Quoting Rob Herring : On Wed, Aug 21, 2019 at 04:45:46PM +0200, René van Dorst wrote: MT7530 port 5 has many modes/configurations. Update the documentation how to use port 5. Signed-off-by: René van Dorst Cc: devicet...@vger.kernel.org Cc: Rob Herring v1->v2: * Adding extra note

Re: [PATCH net] net/sched: pfifo_fast: fix wrong dereference in pfifo_fast_enqueue

2019-08-27 Thread Paolo Abeni
On Tue, 2019-08-27 at 23:18 +0200, Davide Caratti wrote: > Now that 'TCQ_F_CPUSTATS' bit can be cleared, depending on the value of > 'TCQ_F_NOLOCK' bit in the parent qdisc, we can't assume anymore that > per-cpu counters are there in the error path of skb_array_produce(). > Otherwise, the following

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Andy Lutomirski
On Tue, Aug 27, 2019 at 9:49 PM Alexei Starovoitov wrote: > > On Tue, Aug 27, 2019 at 07:00:40PM -0700, Andy Lutomirski wrote: > > > > Let me put this a bit differently. Part of the point is that > > CAP_TRACING should allow a user or program to trace without being able > > to corrupt the system.

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Andy Lutomirski
On Tue, Aug 27, 2019 at 9:43 PM Alexei Starovoitov wrote: > > On Tue, Aug 27, 2019 at 05:55:41PM -0700, Andy Lutomirski wrote: > > > > I was hoping for something in Documentation/admin-guide, not in a > > changelog that's hard to find. > > eventually yes. > > > > > > > > Changing the capability th

[PATCH net 1/2] nfp: flower: prevent ingress block binds on internal ports

2019-08-27 Thread Jakub Kicinski
From: John Hurley Internal port TC offload is implemented through user-space applications (such as OvS) by adding filters at egress via TC clsact qdiscs. Indirect block offload support in the NFP driver accepts both ingress qdisc binds and egress binds if the device is an internal port. However,

[PATCH net 2/2] nfp: flower: handle neighbour events on internal ports

2019-08-27 Thread Jakub Kicinski
From: John Hurley Recent code changes to NFP allowed the offload of neighbour entries to FW when the next hop device was an internal port. This allows for offload of tunnel encap when the end-point IP address is applied to such a port. Unfortunately, the neighbour event handler still rejects eve

[PATCH net 0/2] nfp: flower: fix bugs in merge tunnel encap code

2019-08-27 Thread Jakub Kicinski
John says: There are few bugs in the merge encap code that have come to light with recent driver changes. Effectively, flow bind callbacks were being registered twice when using internal ports (new 'busy' code triggers this). There was also an issue with neighbour notifier messages being ignored f

Re: BUG_ON in skb_segment, after bpf_skb_change_proto was applied

2019-08-27 Thread Shmulik Ladkani
On Tue, 27 Aug 2019 14:10:35 +0200 Daniel Borkmann wrote: > Given first point above wrt hitting rarely, it would be good to first get a > better understanding for writing a reproducer. Back then Yonghong added one > to the BPF kernel test suite [0], so it would be desirable to extend it for > the

Re: [PATCH net-next 1/4] r8169: prepare for adding RTL8125 support

2019-08-27 Thread Heiner Kallweit
On 28.08.2019 01:27, Andrew Lunn wrote: > On Tue, Aug 27, 2019 at 08:41:00PM +0200, Heiner Kallweit wrote: >> This patch prepares the driver for adding RTL8125 support: >> - change type of interrupt mask to u32 >> - restrict rtl_is_8168evl_up to RTL8168 chip versions >> - factor out reading MAC add

Re: [PATCH net-next] net: phy: force phy suspend when calling phy_stop

2019-08-27 Thread Heiner Kallweit
On 28.08.2019 03:34, Jian Shen wrote: > Some ethernet drivers may call phy_start() and phy_stop() from > ndo_open() and ndo_close() respectively. > > When network cable is unconnected, and operate like below: > step 1: ifconfig ethX up -> ndo_open -> phy_start ->start > autoneg, and phy is no link

[PATCH bpf-next 0/2] nfp: bpf: add simple map op cache

2019-08-27 Thread Jakub Kicinski
Hi! This set adds a small batching and cache mechanism to the driver. Map dumps require two operations per element - get next, and lookup. Each of those needs a round trip to the device, and on a loaded system scheduling out and in of the dumping process. This set makes the driver request a number

[PATCH bpf-next 1/2] nfp: bpf: rework MTU checking

2019-08-27 Thread Jakub Kicinski
If control channel MTU is too low to support map operations a warning will be printed. This is not enough, we want to make sure probe fails in such scenario, as this would clearly be a faulty configuration. Signed-off-by: Jakub Kicinski Reviewed-by: Quentin Monnet --- drivers/net/ethernet/netro

[PATCH bpf-next 2/2] nfp: bpf: add simple map op cache

2019-08-27 Thread Jakub Kicinski
Each get_next and lookup call requires a round trip to the device. However, the device is capable of giving us a few entries back, instead of just one. In this patch we ask for a small yet reasonable number of entries (4) on every get_next call, and on subsequent get_next/lookup calls check this l

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Alexei Starovoitov
On Tue, Aug 27, 2019 at 07:00:40PM -0700, Andy Lutomirski wrote: > > Let me put this a bit differently. Part of the point is that > CAP_TRACING should allow a user or program to trace without being able > to corrupt the system. CAP_BPF as you’ve proposed it *can* likely > crash the system. Really

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Alexei Starovoitov
On Wed, Aug 28, 2019 at 12:30:41PM +0900, Masami Hiramatsu wrote: > > kprobes can be created in the tracefs filesystem (which is separate from > > debugfs, tracefs just gets automatically mounted > > in /sys/kernel/debug/tracing when debugfs is mounted) from the > > kprobe_events file. /sys/kernel/

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Alexei Starovoitov
On Tue, Aug 27, 2019 at 05:55:41PM -0700, Andy Lutomirski wrote: > > I was hoping for something in Documentation/admin-guide, not in a > changelog that's hard to find. eventually yes. > > > > > Changing the capability that some existing operation requires could > > > break existing programs. Th

Re: [PATCH net-next v5 0/6] net: dsa: mv88e6xxx: Peridot/Topaz SERDES changes

2019-08-27 Thread David Miller
From: Marek Behún Date: Mon, 26 Aug 2019 23:31:49 +0200 > this is the fifth version of changes for the Topaz/Peridot family of > switches. The patches apply on net-next. > Changes since v4: > - added Reviewed-by and Tested-by tags on first 2 patches, the others >are changed are affected by c

Re: [PATCH net] tcp: remove empty skb from write queue in error cases

2019-08-27 Thread David Miller
From: Eric Dumazet Date: Mon, 26 Aug 2019 09:19:15 -0700 > Vladimir Rutsky reported stuck TCP sessions after memory pressure > events. Edge Trigger epoll() user would never receive an EPOLLOUT > notification allowing them to retry a sendmsg(). > > Jason tested the case of sk_stream_alloc_skb() r

Re: [PATCH V3 net 1/2] openvswitch: Properly set L4 keys on "later" IP fragments

2019-08-27 Thread Gregory Rose
On 8/27/2019 5:33 PM, Pravin Shelar wrote: On Tue, Aug 27, 2019 at 7:58 AM Greg Rose wrote: When IP fragments are reassembled before being sent to conntrack, the key from the last fragment is used. Unless there are reordering issues, the last fragment received will not contain the L4 ports,

Re: [net-next 00/15][pull request] 100GbE Intel Wired LAN Driver Updates 2019-08-26

2019-08-27 Thread Jeff Kirsher
On Tue, 2019-08-27 at 21:09 -0700, Jakub Kicinski wrote: > On Tue, 27 Aug 2019 09:38:17 -0700, Jeff Kirsher wrote: > > This series contains updates to ice driver only. > > Looks clear from uAPI perspective. It does mix fixes with -next, > but I guess that's your call. Yeah, I always debate about

Re: [net-next 00/15][pull request] 100GbE Intel Wired LAN Driver Updates 2019-08-26

2019-08-27 Thread Jakub Kicinski
On Tue, 27 Aug 2019 09:38:17 -0700, Jeff Kirsher wrote: > This series contains updates to ice driver only. Looks clear from uAPI perspective. It does mix fixes with -next, but I guess that's your call. Code-wise changes like this are perhaps the low-light: @@ -2105,7 +2108,10 @@ void ice_trigge

Re: [PATCH net] net/rds: Fix info leak in rds6_inc_info_copy()

2019-08-27 Thread David Miller
From: Ka-Cheong Poon Date: Mon, 26 Aug 2019 02:39:12 -0700 > The rds6_inc_info_copy() function has a couple struct members which > are leaking stack information. The ->tos field should hold actual > information and the ->flags field needs to be zeroed out. > > Fixes: 3eb450367d08 ("rds: add typ

Re: [PATCH net-next 0/3] sctp: add SCTP_ECN_SUPPORTED sockopt

2019-08-27 Thread David Miller
From: Neil Horman Date: Mon, 26 Aug 2019 07:02:21 -0400 > On Mon, Aug 26, 2019 at 04:30:01PM +0800, Xin Long wrote: >> This patchset is to make ecn flag per netns and endpoint and then >> add SCTP_ECN_SUPPORTED sockopt, as does for other feature flags. >> >> Xin Long (3): >> sctp: make ecn fla

Re: [PATCH net-next 0/2] Simplify DSA handling of VLAN subinterface offload

2019-08-27 Thread David Miller
From: Vladimir Oltean Date: Sun, 25 Aug 2019 22:46:28 +0300 > Depends on Vivien Didelot's patchset: > https://patchwork.ozlabs.org/project/netdev/list/?series=127197&state=* > > This patchset removes a few strange-looking guards for -EOPNOTSUPP in > dsa_slave_vlan_rx_add_vid and dsa_slave_vlan_r

Re: [PATCH v5 net-next 02/18] ionic: Add hardware init and device commands

2019-08-27 Thread Jakub Kicinski
On Tue, 27 Aug 2019 20:26:59 -0700, Shannon Nelson wrote: > On 8/27/19 8:16 PM, Jakub Kicinski wrote: > > On Tue, 27 Aug 2019 14:22:55 -0700, Shannon Nelson wrote: > diff --git a/drivers/net/ethernet/pensando/ionic/ionic_devlink.c > b/drivers/net/ethernet/pensando/ionic/ionic_devlink.c

Re: [PATCH net] net: dsa: tag_8021q: Future-proof the reserved fields in the custom VID

2019-08-27 Thread David Miller
From: Vladimir Oltean Date: Sun, 25 Aug 2019 21:32:12 +0300 > After witnessing the discussion in https://lkml.org/lkml/2019/8/14/151 > w.r.t. ioctl extensibility, it became clear that such an issue might > prevent that the 3 RSV bits inside the DSA 802.1Q tag might also suffer > the same fate and

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Masami Hiramatsu
On Tue, 27 Aug 2019 19:21:44 -0400 Steven Rostedt wrote: > > Here's my proposal for CAP_TRACING, documentation-style: > > > > --- begin --- > > > > CAP_TRACING enables a task to use various kernel features to trace > > running user programs and the kernel itself. CAP_TRACING also enables > >

Re: [PATCH v5 net-next 02/18] ionic: Add hardware init and device commands

2019-08-27 Thread Shannon Nelson
On 8/27/19 8:16 PM, Jakub Kicinski wrote: On Tue, 27 Aug 2019 14:22:55 -0700, Shannon Nelson wrote: diff --git a/drivers/net/ethernet/pensando/ionic/ionic_devlink.c b/drivers/net/ethernet/pensando/ionic/ionic_devlink.c index e24ef6971cd5..1ca1e33cca04 100644 --- a/drivers/net/ethernet/pensando/

Re: [PATCH net-next v4 0/3] net: ethernet: mediatek: convert to PHYLINK

2019-08-27 Thread David Miller
From: René van Dorst Date: Sun, 25 Aug 2019 19:43:38 +0200 > These patches converts mediatek driver to PHYLINK API. > > v3->v4: > * Phylink improvements and clean-ups after review > v2->v3: > * Phylink improvements and clean-ups after review > v1->v2: > * Rebase for mt76x8 changes > * Phylink im

Re: [PATCH net-next v2 0/6] net: dsa: explicit programmation of VLAN on CPU ports

2019-08-27 Thread David Miller
From: Vladimir Oltean Date: Sun, 25 Aug 2019 21:27:23 +0300 > On Sun, 25 Aug 2019 at 20:25, Vivien Didelot wrote: >> >> When a VLAN is programmed on a user port, every switch of the fabric also >> program the CPU ports and the DSA links as part of the VLAN. To do that, >> DSA makes use of bitmap

Re: [PATCH v5 net-next 02/18] ionic: Add hardware init and device commands

2019-08-27 Thread Jakub Kicinski
On Tue, 27 Aug 2019 14:22:55 -0700, Shannon Nelson wrote: > >> diff --git a/drivers/net/ethernet/pensando/ionic/ionic_devlink.c > >> b/drivers/net/ethernet/pensando/ionic/ionic_devlink.c > >> index e24ef6971cd5..1ca1e33cca04 100644 > >> --- a/drivers/net/ethernet/pensando/ionic/ionic_devlink.c > >

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Steven Rostedt
On Tue, 27 Aug 2019 18:12:59 -0700 Andy Lutomirski wrote: > Too many slashes :/ > > A group could work for v1. Maybe all the tools should get updated to use > this path? trace-cmd now does. In fact, if run as root, it will first check if tracefs is mounted, and if not, it will try to mount it

RE: [PATCH] r8152: Add rx_buf_sz field to struct r8152

2019-08-27 Thread Hayes Wang
Prashant Malani [mailto:pmal...@chromium.org] > Sent: Wednesday, August 28, 2019 2:02 AM > To: Hayes Wang; da...@davemloft.net > Cc: grund...@chromium.org; netdev@vger.kernel.org; nic_swsd; Prashant > Malani > Subject: [PATCH] r8152: Add rx_buf_sz field to struct r8152 > > tp->rx_buf_sz is set acc

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Andy Lutomirski
> On Aug 27, 2019, at 5:55 PM, Andy Lutomirski wrote: > > On Tue, Aug 27, 2019 at 5:34 PM Alexei Starovoitov > wrote: >> > From the previous discussion, you want to make progress toward solving > a lot of problems with CAP_BPF. One of them was making BPF > firewalling more generally useful. By

[PATCH net-next] net: phy: force phy suspend when calling phy_stop

2019-08-27 Thread Jian Shen
Some ethernet drivers may call phy_start() and phy_stop() from ndo_open() and ndo_close() respectively. When network cable is unconnected, and operate like below: step 1: ifconfig ethX up -> ndo_open -> phy_start ->start autoneg, and phy is no link. step 2: ifconfig ethX down -> ndo_close -> phy_s

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Andy Lutomirski
> On Aug 27, 2019, at 5:44 PM, Steven Rostedt wrote: > > On Tue, 27 Aug 2019 16:34:47 -0700 > Andy Lutomirski wrote: > CAP_TRACING does not override normal permissions on sysfs or debugfs. This means that, unless a new interface for programming kprobes and such is added, it do

Re: [RFC PATCH net-next] net: phy: force phy suspend when calling phy_stop

2019-08-27 Thread shenjian (K)
在 2019/8/28 3:41, Heiner Kallweit 写道: > On 27.08.2019 10:29, shenjian (K) wrote: >> >> >> 在 2019/8/27 13:51, Heiner Kallweit 写道: >>> On 27.08.2019 04:47, Jian Shen wrote: Some ethernet drivers may call phy_start() and phy_stop() from ndo_open and ndo_close() respectively. Whe

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Andy Lutomirski
On Tue, Aug 27, 2019 at 5:34 PM Alexei Starovoitov wrote: > > On Tue, Aug 27, 2019 at 04:01:08PM -0700, Andy Lutomirski wrote: > > [adding some security and tracing folks to cc] > > > > On Tue, Aug 27, 2019 at 1:52 PM Alexei Starovoitov wrote: > > > > > > Introduce CAP_BPF that allows loading all

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Steven Rostedt
On Tue, 27 Aug 2019 16:34:47 -0700 Andy Lutomirski wrote: > > > CAP_TRACING does not override normal permissions on sysfs or debugfs. > > > This means that, unless a new interface for programming kprobes and > > > such is added, it does not directly allow use of kprobes. > > > > kprobes can be

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Alexei Starovoitov
On Tue, Aug 27, 2019 at 07:21:44PM -0400, Steven Rostedt wrote: > > At least for CAP_TRACING (if it were to allow read/write access > to /sys/kernel/tracing), that would be very useful. It would be useful > to those that basically own their machines, and want to trace their > applications all the

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Alexei Starovoitov
On Tue, Aug 27, 2019 at 04:01:08PM -0700, Andy Lutomirski wrote: > [adding some security and tracing folks to cc] > > On Tue, Aug 27, 2019 at 1:52 PM Alexei Starovoitov wrote: > > > > Introduce CAP_BPF that allows loading all types of BPF programs, > > create most map types, load BTF, iterate pro

Re: [PATCH V3 net 1/2] openvswitch: Properly set L4 keys on "later" IP fragments

2019-08-27 Thread Pravin Shelar
On Tue, Aug 27, 2019 at 7:58 AM Greg Rose wrote: > > When IP fragments are reassembled before being sent to conntrack, the > key from the last fragment is used. Unless there are reordering > issues, the last fragment received will not contain the L4 ports, so the > key for the reassembled datagra

Re: [PATCH V3 net 2/2] openvswitch: Clear the L4 portion of the key for "later" fragments.

2019-08-27 Thread Pravin Shelar
On Tue, Aug 27, 2019 at 7:58 AM Greg Rose wrote: > > From: Justin Pettit > > Only the first fragment in a datagram contains the L4 headers. When the > Open vSwitch module parses a packet, it always sets the IP protocol > field in the key, but can only set the L4 fields on the first fragment. > T

[bpf-next] bpf: fix error check in bpf_tcp_gen_syncookie

2019-08-27 Thread Petar Penkov
From: Petar Penkov If a SYN cookie is not issued by tcp_v#_gen_syncookie, then the return value will be exactly 0, rather than <= 0. Let's change the check to reflect that, especially since mss is an unsigned value and cannot be negative. Fixes: 70d66244317e ("bpf: add bpf_tcp_gen_syncookie help

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Andy Lutomirski
On Tue, Aug 27, 2019 at 4:21 PM Steven Rostedt wrote: > > On Tue, 27 Aug 2019 16:01:08 -0700 > Andy Lutomirski wrote: > > > [adding some security and tracing folks to cc] > > > > On Tue, Aug 27, 2019 at 1:52 PM Alexei Starovoitov wrote: > > > > > > Introduce CAP_BPF that allows loading all types

Re: [PATCH v5 net-next 04/18] ionic: Add basic lif support

2019-08-27 Thread Shannon Nelson
On 8/26/19 9:42 PM, Jakub Kicinski wrote: On Mon, 26 Aug 2019 14:33:25 -0700, Shannon Nelson wrote: +static inline bool ionic_is_pf(struct ionic *ionic) +{ + return ionic->pdev && + ionic->pdev->device == PCI_DEVICE_ID_PENSANDO_IONIC_ETH_PF; +} + +static inline bool ionic_is_v

Re: [PATCH net-next 1/4] r8169: prepare for adding RTL8125 support

2019-08-27 Thread Andrew Lunn
On Tue, Aug 27, 2019 at 08:41:00PM +0200, Heiner Kallweit wrote: > This patch prepares the driver for adding RTL8125 support: > - change type of interrupt mask to u32 > - restrict rtl_is_8168evl_up to RTL8168 chip versions > - factor out reading MAC address from registers > - re-add function rtl_ge

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Steven Rostedt
On Tue, 27 Aug 2019 16:01:08 -0700 Andy Lutomirski wrote: > [adding some security and tracing folks to cc] > > On Tue, Aug 27, 2019 at 1:52 PM Alexei Starovoitov wrote: > > > > Introduce CAP_BPF that allows loading all types of BPF programs, > > create most map types, load BTF, iterate programs

Re: [PATCH net-next v2 3/3] dpaa2-eth: Add pause frame support

2019-08-27 Thread Andrew Lunn
On Tue, Aug 27, 2019 at 05:15:51PM +0300, Ioana Radulescu wrote: > Starting with firmware version MC10.18.0, we have support for > L2 flow control. Asymmetrical configuration (Rx or Tx only) is > supported, but not pause frame autonegotioation. > +static int set_pause(struct dpaa2_eth_priv *priv)

Re: [PATCH v5 net-next 02/18] ionic: Add hardware init and device commands

2019-08-27 Thread Shannon Nelson
On 8/27/19 12:50 PM, Andrew Lunn wrote: On Tue, Aug 27, 2019 at 10:39:20AM -0700, Shannon Nelson wrote: On 8/26/19 7:26 PM, Andrew Lunn wrote: On Mon, Aug 26, 2019 at 02:33:23PM -0700, Shannon Nelson wrote: +void ionic_debugfs_add_dev(struct ionic *ionic) +{ + struct dentry *dentry; + +

Re: [PATCH net-next v2 2/3] dpaa2-eth: Use stored link settings

2019-08-27 Thread Andrew Lunn
On Tue, Aug 27, 2019 at 05:15:50PM +0300, Ioana Radulescu wrote: > Whenever a link state change occurs, we get notified and save > the new link settings in the device's private data. In ethtool > get_link_ksettings, use the stored state instead of interrogating > the firmware each time. > > Signed

Re: [PATCH net-next v2 1/3] dpaa2-eth: Remove support for changing link settings

2019-08-27 Thread Andrew Lunn
On Tue, Aug 27, 2019 at 05:15:49PM +0300, Ioana Radulescu wrote: > We only support fixed-link for now, so there is no point in > offering users the option to change link settings via ethtool. > > Functionally there is no change, since firmware prevents us from > changing link parameters anyway. >

Re: [PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Andy Lutomirski
[adding some security and tracing folks to cc] On Tue, Aug 27, 2019 at 1:52 PM Alexei Starovoitov wrote: > > Introduce CAP_BPF that allows loading all types of BPF programs, > create most map types, load BTF, iterate programs and maps. > CAP_BPF alone is not enough to attach or run programs. > >

Re: [PATCH bpf-next] selftests/bpf: remove wrong nhoff in flow dissector test

2019-08-27 Thread Daniel Borkmann
On 8/27/19 12:27 AM, Stanislav Fomichev wrote: .nhoff = 0 is (correctly) reset to ETH_HLEN on the next line so let's drop it. Signed-off-by: Stanislav Fomichev Applied, thanks!

Re: [PATCH bpf-next v3 0/4] selftests/bpf: test_progs: misc fixes

2019-08-27 Thread Daniel Borkmann
On 8/22/19 1:44 AM, Stanislav Fomichev wrote: * add test__skip to indicate skipped tests * remove global success/error counts (use environment) * remove asserts from the tests * remove unused ret from send_signal test v3: * QCHECK -> CHECK_FAIL (Daniel Borkmann) v2: * drop patch that changes ou

Re: [PATCH bpf-next 0/4] bpf: precision tracking tests

2019-08-27 Thread Daniel Borkmann
On 8/23/19 7:52 AM, Alexei Starovoitov wrote: Add few additional tests for precision tracking in the verifier. Alexei Starovoitov (4): bpf: introduce verifier internal test flag tools/bpf: sync bpf.h selftests/bpf: verifier precise tests selftests/bpf: add precision tracking test

Re: [PATCH net-next v2 2/3] dt-bindings: net: dsa: mt7530: Add support for port 5

2019-08-27 Thread Rob Herring
On Wed, Aug 21, 2019 at 04:45:46PM +0200, René van Dorst wrote: > MT7530 port 5 has many modes/configurations. > Update the documentation how to use port 5. > > Signed-off-by: René van Dorst > Cc: devicet...@vger.kernel.org > Cc: Rob Herring > v1->v2: > * Adding extra note about RGMII2 and gpio

Re: [Patch net] net_sched: fix a NULL pointer deref in ipt action

2019-08-27 Thread David Miller
From: Cong Wang Date: Sun, 25 Aug 2019 10:01:32 -0700 > The net pointer in struct xt_tgdtor_param is not explicitly > initialized therefore is still NULL when dereferencing it. > So we have to find a way to pass the correct net pointer to > ipt_destroy_target(). > > The best way I find is just s

Re: [PATCH net-next v2 3/3] dt-bindings: net: ethernet: Update mt7622 docs and dts to reflect the new phylink API

2019-08-27 Thread Rob Herring
On Wed, Aug 21, 2019 at 04:43:36PM +0200, René van Dorst wrote: > This patch the removes the recently added mediatek,physpeed property. > Use the fixed-link property speed = <2500> to set the phy in 2.5Gbit. > See mt7622-bananapi-bpi-r64.dts for a working example. > > Signed-off-by: René van Dorst

Re: [PATCH v5 net-next 03/18] ionic: Add port management commands

2019-08-27 Thread Shannon Nelson
On 8/26/19 9:36 PM, Jakub Kicinski wrote: On Mon, 26 Aug 2019 14:33:24 -0700, Shannon Nelson wrote: The port management commands apply to the physical port associated with the PCI device, which might be shared among several logical interfaces. Signed-off-by: Shannon Nelson [...] diff --git

Re: [PATCH net] tcp: inherit timestamp on mtu probe

2019-08-27 Thread Eric Dumazet
On Tue, Aug 27, 2019 at 11:16 PM Willem de Bruijn wrote: > > On Tue, Aug 27, 2019 at 4:58 PM Eric Dumazet wrote: > > > > On Tue, Aug 27, 2019 at 10:54 PM Willem de Bruijn > > wrote: > > > > > Sure, that's more descriptive. > > > > > > One caveat, the function is exposed in a header, so it's a >

Re: [PATCH v5 net-next 02/18] ionic: Add hardware init and device commands

2019-08-27 Thread Shannon Nelson
On 8/26/19 9:24 PM, Jakub Kicinski wrote: On Mon, 26 Aug 2019 14:33:23 -0700, Shannon Nelson wrote: The ionic device has a small set of PCI registers, including a device control and data space, and a large set of message commands. Signed-off-by: Shannon Nelson diff --git a/drivers/net/ethernet

Re: [PATCH net] ipv6: Default fib6_type to RTN_UNICAST when not set

2019-08-27 Thread David Miller
From: David Ahern Date: Tue, 27 Aug 2019 11:51:32 -0600 > Specific request is for commit c7036d97acd2527cef145b5ef9ad1a37ed21bbe6 > ("ipv6: Default fib6_type to RTN_UNICAST when not set") to be queued for > stable releases prior to v5.2 Ok, I'll take care of this in my next round.

[PATCH net] net/sched: pfifo_fast: fix wrong dereference in pfifo_fast_enqueue

2019-08-27 Thread Davide Caratti
Now that 'TCQ_F_CPUSTATS' bit can be cleared, depending on the value of 'TCQ_F_NOLOCK' bit in the parent qdisc, we can't assume anymore that per-cpu counters are there in the error path of skb_array_produce(). Otherwise, the following splat can be seen: Unable to handle kernel paging request at v

Re: [PATCH net] tcp: inherit timestamp on mtu probe

2019-08-27 Thread Willem de Bruijn
On Tue, Aug 27, 2019 at 4:58 PM Eric Dumazet wrote: > > On Tue, Aug 27, 2019 at 10:54 PM Willem de Bruijn > wrote: > > > Sure, that's more descriptive. > > > > One caveat, the function is exposed in a header, so it's a > > bit more churn. If you don't mind that, I'll send the v2. > > Oh right it

Re: Unable to create htb tc classes more than 64K

2019-08-27 Thread Eric Dumazet
On 8/27/19 10:53 PM, Dave Taht wrote: > > Although this is very cool, I think in this case the OP is being > a router, not server? This mechanism is generic. EDT has not been designed for servers only. One HTB class (with one associated qdisc per leaf) per rate limiter does not scale, and con

Re: [PATCH net] tcp: inherit timestamp on mtu probe

2019-08-27 Thread Eric Dumazet
On Tue, Aug 27, 2019 at 10:54 PM Willem de Bruijn wrote: > Sure, that's more descriptive. > > One caveat, the function is exposed in a header, so it's a > bit more churn. If you don't mind that, I'll send the v2. Oh right it is also used from tcp_shifted_skb() after Martin KaFai Lau fix ...

Re: [PATCH net] tcp: inherit timestamp on mtu probe

2019-08-27 Thread Willem de Bruijn
On Tue, Aug 27, 2019 at 4:07 PM Eric Dumazet wrote: > > On Tue, Aug 27, 2019 at 9:09 PM Willem de Bruijn > wrote: > > > > From: Willem de Bruijn > > > > TCP associates tx timestamp requests with a byte in the bytestream. > > If merging skbs in tcp_mtu_probe, migrate the tstamp request. > > > > S

[PATCH bpf-next] bpf, capabilities: introduce CAP_BPF

2019-08-27 Thread Alexei Starovoitov
Introduce CAP_BPF that allows loading all types of BPF programs, create most map types, load BTF, iterate programs and maps. CAP_BPF alone is not enough to attach or run programs. Networking: CAP_BPF and CAP_NET_ADMIN are necessary to: - attach to cgroup-bpf hooks like INET_INGRESS, INET_SOCK_CRE

Re: Unable to create htb tc classes more than 64K

2019-08-27 Thread Dave Taht
On Sun, Aug 25, 2019 at 11:47 PM Eric Dumazet wrote: > > > > On 8/25/19 7:52 PM, Cong Wang wrote: > > On Wed, Aug 21, 2019 at 11:00 PM Akshat Kakkar > > wrote: > >> > >> On Thu, Aug 22, 2019 at 3:37 AM Cong Wang wrote: > I am using ipset + iptables to classify and not filters. Besides, if

Re: [PATCH 1/2] rtnetlink: gate MAC address with an LSM hook

2019-08-27 Thread Paul Moore
On Fri, Aug 23, 2019 at 7:41 AM Jeffrey Vander Stoep wrote: > On Fri, Aug 23, 2019 at 1:19 AM David Miller wrote: > > From: Jeff Vander Stoep > > Date: Wed, 21 Aug 2019 15:45:47 +0200 > > > > > MAC addresses are often considered sensitive because they are > > > usually unique and can be used to

Re: [PATCH net] tcp: inherit timestamp on mtu probe

2019-08-27 Thread Eric Dumazet
On Tue, Aug 27, 2019 at 9:09 PM Willem de Bruijn wrote: > > From: Willem de Bruijn > > TCP associates tx timestamp requests with a byte in the bytestream. > If merging skbs in tcp_mtu_probe, migrate the tstamp request. > > Similar to MSG_EOR, do not allow moving a timestamp from any segment > in

Re: [PATCH v5 net-next 02/18] ionic: Add hardware init and device commands

2019-08-27 Thread Andrew Lunn
On Tue, Aug 27, 2019 at 10:39:20AM -0700, Shannon Nelson wrote: > On 8/26/19 7:26 PM, Andrew Lunn wrote: > >On Mon, Aug 26, 2019 at 02:33:23PM -0700, Shannon Nelson wrote: > >>+void ionic_debugfs_add_dev(struct ionic *ionic) > >>+{ > >>+ struct dentry *dentry; > >>+ > >>+ dentry = debugfs_creat

Re: [RFC PATCH net-next] net: phy: force phy suspend when calling phy_stop

2019-08-27 Thread Heiner Kallweit
On 27.08.2019 10:29, shenjian (K) wrote: > > > 在 2019/8/27 13:51, Heiner Kallweit 写道: >> On 27.08.2019 04:47, Jian Shen wrote: >>> Some ethernet drivers may call phy_start() and phy_stop() from >>> ndo_open and ndo_close() respectively. >>> >>> When network cable is unconnected, and operate like

Re: [PATCH 04/38] mlx5: Convert cq_table to XArray

2019-08-27 Thread Saeed Mahameed
On Tue, 2019-08-20 at 15:32 -0700, Matthew Wilcox wrote: > From: "Matthew Wilcox (Oracle)" > > Since mlx5_cq_table would have shrunk down to just the xarray, > eliminate > it and embed the xarray directly into mlx5_eq. > > Signed-off-by: Matthew Wilcox (Oracle) > --- > drivers/net/ethernet/mel

Re: [PATCH 03/38] mlx4: Convert qp_table_tree to XArray

2019-08-27 Thread Saeed Mahameed
On Tue, 2019-08-20 at 15:32 -0700, Matthew Wilcox wrote: > From: "Matthew Wilcox (Oracle)" > > This XArray appears to be modifiable from interrupt context, so we > have > to be a little more careful with the locking. However, the lookup > can > be done without the spinlock held. I cannot determ

[PATCH net] tcp: inherit timestamp on mtu probe

2019-08-27 Thread Willem de Bruijn
From: Willem de Bruijn TCP associates tx timestamp requests with a byte in the bytestream. If merging skbs in tcp_mtu_probe, migrate the tstamp request. Similar to MSG_EOR, do not allow moving a timestamp from any segment in the probe but the last. This to avoid merging multiple timestamps. Tes

Re: [PATCH spi for-5.4 2/5] spi: Add a PTP system timestamp to the transfer structure

2019-08-27 Thread Mark Brown
On Sat, Aug 24, 2019 at 03:38:16PM +0300, Vladimir Oltean wrote: > On Thu, 22 Aug 2019 at 21:19, Mark Brown wrote: > > On Sun, Aug 18, 2019 at 09:25:57PM +0300, Vladimir Oltean wrote: > > > + if (!ctlr->ptp_sts_supported) { > > > + list_for_each_entry(xfer, &mesg->transfers, trans

Re: [PATCH v5 net-next 01/18] ionic: Add basic framework for IONIC Network device driver

2019-08-27 Thread Shannon Nelson
On 8/26/19 9:06 PM, Jakub Kicinski wrote: On Mon, 26 Aug 2019 14:33:22 -0700, Shannon Nelson wrote: +struct ionic { + struct pci_dev *pdev; + struct device *dev; + struct devlink *dl; No need for the dl pointer here. priv_to_devlink can be used to obtain the devlink pointer ba

Re: [PATCH v5 net-next 14/18] ionic: Add Tx and Rx handling

2019-08-27 Thread Shannon Nelson
On 8/26/19 7:32 PM, Yunsheng Lin wrote: On 2019/8/27 5:33, Shannon Nelson wrote: Add both the Tx and Rx queue setup and handling. The related stats display comes later. Instead of using the generic napi routines used by the slow-path commands, the Tx and Rx paths are simplified and inlined in

[PATCH net] net: sched: act_sample: fix psample group handling on overwrite

2019-08-27 Thread Vlad Buslov
Action sample doesn't properly handle psample_group pointer in overwrite case. Following issues need to be fixed: - In tcf_sample_init() function RCU_INIT_POINTER() is used to set s->psample_group, even though we neither setting the pointer to NULL, nor preventing concurrent readers from acces

[PATCH net-next 4/4] r8169: add support for EEE on RTL8125

2019-08-27 Thread Heiner Kallweit
This adds EEE support for RTL8125 based on the vendor driver. Supported is EEE for 100Mbps and 1Gbps. Realtek recommended to not yet enable EEE for 2.5Gbps due to potential compatibility issues. Also ethtool doesn't support yet controlling EEE for 2.5Gbps and 5Gbps. Signed-off-by: Heiner Kallweit

[PATCH net-next 3/4] r8169: add RTL8125 PHY initialization

2019-08-27 Thread Heiner Kallweit
This patch adds PHY initialization magic copied from the r8125 vendor driver. In addition it supports loading the firmware for chip version RTL_GIGA_MAC_VER_61. Signed-off-by: Heiner Kallweit --- drivers/net/ethernet/realtek/r8169_main.c | 130 +- 1 file changed, 127 insertio

[PATCH net-next 2/4] r8169: add support for RTL8125

2019-08-27 Thread Heiner Kallweit
This adds support for 2.5Gbps chip RTL8125, it's partially based on the r8125 vendor driver. Tested with a Delock 89531 PCIe card against a Netgear GS110MX Multi-Gig switch. Firmware isn't strictly needed, but on some systems there may be compatibility issues w/o firmware. Firmware has been submitt

  1   2   >