Re: [RFC/RFT PATCH 4/4] [debug] ARM: am335x: illustrate hwstamp

2017-06-13 Thread Tony Lindgren
* Grygorii Strashko [170613 16:20]: > This patch allows to test CPTS HW_TS_PUSH functionality on am335x boards > > below sequence of commands will enable Timer7 to trigger 1sec > periodic pulses on CPTS HW4_TS_PUSH input pin: > > # echo 10 >

Re: [PATCH] ip6_tunnel: Correct tos value in collect_md mode

2017-06-13 Thread Peter Dawson
On Wed, 14 Jun 2017 10:54:31 +0800 严海双 wrote: > > Changes since v2: > > * mask key->tos with RT_TOS() suggested by Daniel Can you help me understand the rationale for this change? Is there are bug introduced by dsfield = ip6_tclass(key->label); ? The

Re: [PATCH v2 net-next 8/9] bpf: nfp: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Jakub Kicinski
On Tue, 13 Jun 2017 20:19:53 -0700, Martin KaFai Lau wrote: > On Tue, Jun 13, 2017 at 07:19:50PM -0700, Jakub Kicinski wrote: > > On Tue, 13 Jun 2017 17:37:50 -0700, Martin KaFai Lau wrote: > > > On Tue, Jun 13, 2017 at 04:52:32PM -0700, Jakub Kicinski wrote: > > > > On Tue, 13 Jun 2017

Re: [PATCH v2 net-next 8/9] bpf: nfp: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
On Tue, Jun 13, 2017 at 07:19:50PM -0700, Jakub Kicinski wrote: > On Tue, 13 Jun 2017 17:37:50 -0700, Martin KaFai Lau wrote: > > On Tue, Jun 13, 2017 at 04:52:32PM -0700, Jakub Kicinski wrote: > > > On Tue, 13 Jun 2017 14:08:40 -0700, Martin KaFai Lau wrote: > > > > - case XDP_QUERY_PROG: >

Re: [PATCH V2 net-next 6/8] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Andrew Lunn
> + if (le16_to_cpu(HCLGE_MDIO_STA_VAL(mdio_cmd->sta))) { > + dev_err(>pdev->dev, "mdio read data error\n"); > + return -ENOMEM; > + } If it is not zero, it is an error. !0 is always !0, big or little endian, so there is no point doing the le16_to_cpu(). Where is

Re: [PATCH] ip6_tunnel: Correct tos value in collect_md mode

2017-06-13 Thread 严海双
> On 14 Jun 2017, at 10:48 AM, Haishuang Yan > wrote: > > Same as ip_gre, geneve and vxlan, use key->tos as tos value. > > CC: Peter Dawson > Fixes: 0e9a709560db ("ip6_tunnel, ip6_gre: fix setting of DSCP on > encapsulated packets”) >

[PATCH] of: update ePAPR references to point to Devicetree Specification

2017-06-13 Thread frowand . list
From: Frank Rowand The Devicetree Specification has superseded the ePAPR as the base specification for bindings. Update files in Documentation to reference the new document. Some files are not updated because there is no hypervisor chapter in the Devicetree

[PATCH] ip6_tunnel: Correct tos value in collect_md mode

2017-06-13 Thread Haishuang Yan
Same as ip_gre, geneve and vxlan, use key->tos as tos value. CC: Peter Dawson Fixes: 0e9a709560db ("ip6_tunnel, ip6_gre: fix setting of DSCP on encapsulated packets”) Suggested-by: Daniel Borkmann Signed-off-by: Haishuang Yan

Re: [PATCH V2 net-next 6/8] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Andrew Lunn
> +struct hclge_mdio_cfg_cmd { > + u8 ctrl_bit; > + u8 prtad; /* The external port address */ > + u8 devad; /* The external device address */ > + u8 rsvd; > + __le16 addr_c45;/* Only valid for c45 */ > + __le16 data_wr; > + __le16 data_rd; > + __le16

Re: [PATCH V2 net-next 7/8] net: hns3: Add Ethtool support to HNS3 driver

2017-06-13 Thread Andrew Lunn
> +static const struct hns3_link_mode_mapping hns3_lm_map[] = { > + {HNS3_LM_FIBRE_BIT, ETHTOOL_LINK_MODE_FIBRE_BIT}, > + {HNS3_LM_AUTONEG_BIT, ETHTOOL_LINK_MODE_Autoneg_BIT}, > + {HNS3_LM_TP_BIT, ETHTOOL_LINK_MODE_TP_BIT}, > + {HNS3_LM_PAUSE_BIT, ETHTOOL_LINK_MODE_Pause_BIT}, > +

Re: Repeatable inet6_dump_fib crash in stock 4.12.0-rc4+

2017-06-13 Thread David Ahern
On 6/13/17 3:42 PM, Cong Wang wrote: > On Tue, Jun 13, 2017 at 1:16 PM, Ben Greear wrote: >> On 06/09/2017 02:25 PM, Eric Dumazet wrote: >>> >>> On Fri, 2017-06-09 at 07:27 -0600, David Ahern wrote: On 6/8/17 11:55 PM, Cong Wang wrote: > Apparently

Re: [PATCH V2 net-next 7/8] net: hns3: Add Ethtool support to HNS3 driver

2017-06-13 Thread Andrew Lunn
> + switch (media_type) { > + case HNAE3_MEDIA_TYPE_FIBER: > + cmd->base.port = PORT_FIBRE; > + supported_caps = HNS3_LM_FIBRE_BIT | HNS3_LM_AUTONEG_BIT | > + HNS3_LM_PAUSE_BIT | HNS3_LM_4BASELR4_FULL_BIT | > +

Re: [PATCH v2 net-next 8/9] bpf: nfp: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Jakub Kicinski
On Tue, 13 Jun 2017 17:37:50 -0700, Martin KaFai Lau wrote: > On Tue, Jun 13, 2017 at 04:52:32PM -0700, Jakub Kicinski wrote: > > On Tue, 13 Jun 2017 14:08:40 -0700, Martin KaFai Lau wrote: > > > - case XDP_QUERY_PROG: > > > - xdp->prog_attached = !!nn->dp.xdp_prog; > > > + case

Re: [PATCH V2 net-next 2/8] net: hns3: Add support of the HNAE3 framework

2017-06-13 Thread Andrew Lunn
On Wed, Jun 14, 2017 at 12:10:29AM +0100, Salil Mehta wrote: > +static int __init hnae3_init(void) > +{ > + return 0; > +} > + .. > +subsys_initcall(hnae3_init); And the point of this is? Andrew

Re: [PATCH V2 net-next 2/8] net: hns3: Add support of the HNAE3 framework

2017-06-13 Thread Andrew Lunn
On Wed, Jun 14, 2017 at 12:10:29AM +0100, Salil Mehta wrote: > This patch adds the support of the HNAE3 (Hisilicon Network > Acceleration Engine 3) framework support to the HNS3 driver. > > Framework facilitates clients like ENET(HNS3 Ethernet Driver), RoCE > and user-space Ethernet drivers (like

Re: [PATCH net-next 6/9] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Andrew Lunn
> Since I would be touching the core, lots of drivers will get impacted and will > have to wait till everyone gives clean signal. This will impact our internal > deadlines. But as I said I am eager to cooperate & contribute :) Just as an FYI. Your internal deadlines are irrelevant. We will

[net-next 9/9] ixgbe: pci_set_drvdata must be called before register_netdev

2017-06-13 Thread Jeff Kirsher
From: Jeff Mahoney We call pci_set_drvdata immediately after calling register_netdev, which leaves a window where tasks writing to the sriov_numvfs sysfs attribute can sneak in and crash the kernel. register_netdev cleans up after itself so placing pci_set_drvdata immediately

[net-next 7/9] ixgbe: fix writes to PFQDE

2017-06-13 Thread Jeff Kirsher
From: Emil Tantilov ixgbe_write_qde() was ignoring the qde parameter which resulted in PFQDE.HIDE_VLAN not being set for X550. Signed-off-by: Emil Tantilov Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher

[net-next 8/9] ixgbe: Resolve cppcheck format string warning

2017-06-13 Thread Jeff Kirsher
From: Tony Nguyen cppcheck warns that the format string is incorrect in the function ixgbe_get_strings(). Since the value cannot be negative, change the variable to unsigned which matches the format specifier. Signed-off-by: Tony Nguyen

[net-next 6/9] ixgbevf: Bump version number

2017-06-13 Thread Jeff Kirsher
From: Tony Nguyen Update ixgbevf version number. Signed-off-by: Tony Nguyen Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher ---

[net-next 5/9] ixgbe: Bump version number

2017-06-13 Thread Jeff Kirsher
From: Tony Nguyen Update ixgbe version number. Signed-off-by: Tony Nguyen Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher --- drivers/net/ethernet/intel/ixgbe/ixgbe_main.c | 2

[net-next 2/9] ixgbe: avoid permanent lock of *_PTP_TX_IN_PROGRESS

2017-06-13 Thread Jeff Kirsher
From: Jacob Keller The ixgbe driver uses a state bit lock to avoid handling more than one Tx timestamp request at once. This is required because hardware is limited to a single set of registers for Tx timestamps. The state bit lock is not properly cleaned up during

[net-next 3/9] ixgbe: add statistic indicating number of skipped Tx timestamps

2017-06-13 Thread Jeff Kirsher
From: Jacob Keller The ixgbe driver can only handle one Tx timestamp request at a time. This means it is possible for an application timestamp request to be ignored. There is no easy way for an administrator to determine if this occurred. Add a new statistic which

[net-next 4/9] ixgbe: check for Tx timestamp timeouts during watchdog

2017-06-13 Thread Jeff Kirsher
From: Jacob Keller The ixgbe driver has logic to handle only one Tx timestamp at a time, using a state bit lock to avoid multiple requests at once. It may be possible, if incredibly unlikely, that a Tx timestamp event is requested but never completes. Since we use an

[net-next 1/9] ixgbe: fix race condition with PTP_TX_IN_PROGRESS bits

2017-06-13 Thread Jeff Kirsher
From: Jacob Keller Hardware related to the ixgbe driver is limited to handling a single Tx timestamp request at a time. Thus, the driver ignores requests for Tx timestamp while waiting for the current request to finish. It uses a state bit lock which enforces that only

Re: [PATCH v2 net-next 8/9] bpf: nfp: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
On Tue, Jun 13, 2017 at 04:52:32PM -0700, Jakub Kicinski wrote: > On Tue, 13 Jun 2017 14:08:40 -0700, Martin KaFai Lau wrote: > > - case XDP_QUERY_PROG: > > - xdp->prog_attached = !!nn->dp.xdp_prog; > > + case XDP_QUERY_PROG: { > > + const struct bpf_prog *xdp_prog; > > + >

[net-next 0/9][pull request] 10GbE Intel Wired LAN Driver Updates 2017-06-13

2017-06-13 Thread Jeff Kirsher
This series contains updates to ixgbe and ixgbevf only. Jake completes his fix ups for our drivers with the ixgbe changes to resolve a race condition in processing timestamp requests. These fixes are the same fixes Jake applied earlier to the other drivers, including the added statistic to help

linux-next: manual merge of the net-next tree with the net tree

2017-06-13 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the net-next tree got a conflict in: net/batman-adv/routing.c between commit: a1a745ef980a ("batman-adv: fix memory leak when dropping packet from other gateway") from the net tree and commit: 22f0502ed9f3 ("batman-adv: Print correct function names

Re: [PATCH 0/4] bpf: Changes needed (or desired) for MIPS support

2017-06-13 Thread Daniel Borkmann
On 06/14/2017 01:49 AM, David Daney wrote: This is a grab bag of changes to the bpf testing infrastructure I developed working on MIPS eBPF JIT support. The change to bpf_jit_disasm is probably universally beneficial, the others are more MIPS specific. I think these could go independently

Re: [PATCH 4/4] samples/bpf: Fix tracex5 to work with MIPS syscalls.

2017-06-13 Thread Daniel Borkmann
On 06/14/2017 01:49 AM, David Daney wrote: There are two problems: 1) In MIPS the __NR_* macros expand to an expression, this causes the sections of the object file to be named like: . . . [ 5] kprobe/(5000 + 1) PROGBITS 000160 ... [ 6] kprobe/(5000 +

Re: [PATCH 3/4] bpf: Add MIPS support to samples/bpf.

2017-06-13 Thread Daniel Borkmann
On 06/14/2017 01:49 AM, David Daney wrote: Signed-off-by: David Daney Acked-by: Daniel Borkmann

linux-next: manual merge of the net-next tree with the net tree

2017-06-13 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the net-next tree got a conflict in: drivers/net/ethernet/qlogic/qed/qed_debug.c between commit: ace17c369295 ("qed: fix dump of context data") from the net tree and commit: 7b6859fbdcc4 ("qed: Utilize FW 8.20.0.0") from the net-next tree. I fixed

Re: [PATCH 2/4] test_bpf: Add test to make conditional jump cross a large number of insns.

2017-06-13 Thread Daniel Borkmann
On 06/14/2017 01:49 AM, David Daney wrote: On MIPS, conditional branches can only span 32k instructions. To exceed this limit in the JIT with the BPF maximum of 4k insns, we need to choose eBPF insns that expand to more than 8 machine instructions. Use BPF_LD_ABS as it is quite complex. This

Re: [PATCH 1/4] tools: bpf_jit_disasm: Handle large images.

2017-06-13 Thread Daniel Borkmann
On 06/14/2017 01:49 AM, David Daney wrote: Dynamically allocate memory so that JIT images larger than the size of the statically allocated array can be handled. Signed-off-by: David Daney Acked-by: Daniel Borkmann

Re: [PATCH v2 4/5] MIPS: Add support for eBPF JIT.

2017-06-13 Thread Daniel Borkmann
On 06/14/2017 12:28 AM, David Daney wrote: Since the eBPF machine has 64-bit registers, we only support this in 64-bit kernels. As of the writing of this commit log test-bpf is showing: test_bpf: Summary: 316 PASSED, 0 FAILED, [308/308 JIT'ed] All current test cases are successfully

Re: [PATCH V2 net-next 7/8] net: hns3: Add Ethtool support to HNS3 driver

2017-06-13 Thread Stephen Hemminger
On Wed, 14 Jun 2017 00:10:34 +0100 Salil Mehta wrote: > +/* netdev related stats */ > +#define HNS3_NETDEV_STAT(_string, _member) \ > + { _string, \ > + FIELD_SIZEOF(struct rtnl_link_stats64,

Re: [PATCH V2 net-next 1/8] net: hns3: Add support of HNS3 Ethernet Driver for hip08 SoC

2017-06-13 Thread Stephen Hemminger
On Wed, 14 Jun 2017 00:10:28 +0100 Salil Mehta wrote: > +static irqreturn_t hns3_irq_handle(int irq, void *dev) > +{ > + struct hns3_enet_tqp_vector *tqp_vector = dev; > + > + napi_schedule(_vector->napi); In order to do NAPI correctly, the IRQ must be disabled.

Re: [PATCH v2 net-next 8/9] bpf: nfp: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Jakub Kicinski
On Tue, 13 Jun 2017 14:08:40 -0700, Martin KaFai Lau wrote: > - case XDP_QUERY_PROG: > - xdp->prog_attached = !!nn->dp.xdp_prog; > + case XDP_QUERY_PROG: { > + const struct bpf_prog *xdp_prog; > + > + xdp_prog = nn->dp.xdp_prog; > + if

[PATCH 2/4] test_bpf: Add test to make conditional jump cross a large number of insns.

2017-06-13 Thread David Daney
On MIPS, conditional branches can only span 32k instructions. To exceed this limit in the JIT with the BPF maximum of 4k insns, we need to choose eBPF insns that expand to more than 8 machine instructions. Use BPF_LD_ABS as it is quite complex. This forces the JIT to invert the sense of the

[PATCH 0/4] bpf: Changes needed (or desired) for MIPS support

2017-06-13 Thread David Daney
This is a grab bag of changes to the bpf testing infrastructure I developed working on MIPS eBPF JIT support. The change to bpf_jit_disasm is probably universally beneficial, the others are more MIPS specific. David Daney (4): tools: bpf_jit_disasm: Handle large images. test_bpf: Add test

[PATCH 1/4] tools: bpf_jit_disasm: Handle large images.

2017-06-13 Thread David Daney
Dynamically allocate memory so that JIT images larger than the size of the statically allocated array can be handled. Signed-off-by: David Daney --- tools/net/bpf_jit_disasm.c | 37 ++--- 1 file changed, 26 insertions(+), 11 deletions(-)

[PATCH 4/4] samples/bpf: Fix tracex5 to work with MIPS syscalls.

2017-06-13 Thread David Daney
There are two problems: 1) In MIPS the __NR_* macros expand to an expression, this causes the sections of the object file to be named like: . . . [ 5] kprobe/(5000 + 1) PROGBITS 000160 ... [ 6] kprobe/(5000 + 0) PROGBITS 000258 ... [

[PATCH 3/4] bpf: Add MIPS support to samples/bpf.

2017-06-13 Thread David Daney
Signed-off-by: David Daney --- samples/bpf/bpf_helpers.h | 13 + 1 file changed, 13 insertions(+) diff --git a/samples/bpf/bpf_helpers.h b/samples/bpf/bpf_helpers.h index 9a9c95f..76526da 100644 --- a/samples/bpf/bpf_helpers.h +++ b/samples/bpf/bpf_helpers.h

Re: [PATCH V2 net-next 6/8] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Florian Fainelli
On 06/13/2017 04:10 PM, Salil Mehta wrote: > This patch adds the support of MDIO bus interface for HNS3 driver. > Code provides various interfaces to start and stop the PHY layer > and to read and write the MDIO bus or PHY. > > Signed-off-by: Daode Huang >

[RFC/RFT PATCH 4/4] [debug] ARM: am335x: illustrate hwstamp

2017-06-13 Thread Grygorii Strashko
This patch allows to test CPTS HW_TS_PUSH functionality on am335x boards below sequence of commands will enable Timer7 to trigger 1sec periodic pulses on CPTS HW4_TS_PUSH input pin: # echo 10 > /sys/class/pwm/pwmchip0/pwm0/period # echo 5 >

[RFC/RFT PATCH 0/4] net: ethernat: ti: cpts: enable irq and HW_TS_PUSH

2017-06-13 Thread Grygorii Strashko
Intention of this post is to get some early review and wider testing. This series adds CPTS IRQ support, which allows to fix TX timestamping issue and add support for HW_TS_PUSH events. The idea of using CPTS IRQ for proper support of HW_TS_PUSH events was originally discussed in [1]. Further

[RFC/RFT PATCH 1/4] net: ethernet: ti: cpts: use own highpri workqueue

2017-06-13 Thread Grygorii Strashko
There could be significant delay in CPTS work schedule under high system load and on -RT which could cause CPTS misbehavior due to internal counter overflow. Usage of own highpri ordered workqueue allows to avoid such kind of issues and makes it possible to tune priority of CPTS workqueue thread

[RFC/RFT PATCH 2/4] net: ethernat: ti: cpts: enable irq

2017-06-13 Thread Grygorii Strashko
There are two reasons for this change: 1) enabling of HW_TS_PUSH events as suggested by Richard Cochran and discussed in [1] 2) fixing an TX timestamping miss issue which happens with low speed ethernet connections and was reproduced on am57xx and am335x boards. Issue description: With the low

[RFC/RFT PATCH 3/4] net: ethernet: ti: cpts: add support of cpts HW_TS_PUSH

2017-06-13 Thread Grygorii Strashko
This patch adds support of the CPTS HW_TS_PUSH events which are generated by external low frequency time stamp channels on TI's OMAP CPSW[ and Keystone 2 platforms]. It supports up to 8 external time stamp channels for HW_TS_PUSH input pins (the number of supported channel is different for

[PATCH V2 net-next 0/8] Hisilicon Network Subsystem 3 Ethernet Driver

2017-06-13 Thread Salil Mehta
This patch-set contains the support of the HNS3 (Hisilicon Network Subsystem 3) Ethernet driver for hip08 family of SoCs and future upcoming SoCs. Hisilicon's new hip08 SoCs have integrated ethernet based on PCI Express and hence there was a need of new driver over the previous HNS driver which

[PATCH V2 net-next 1/8] net: hns3: Add support of HNS3 Ethernet Driver for hip08 SoC

2017-06-13 Thread Salil Mehta
This patch adds the support of Hisilicon Network Subsystem 3 Ethernet driver to hip08 family of SoCs. This driver includes basic Rx/Tx functionality. It also includes the client registration code with the HNAE3(Hisilicon Network Acceleration Engine 3) framework. This work provides the initial

[PATCH V2 net-next 3/8] net: hns3: Add HNS3 IMP(Integrated Mgmt Proc) Cmd Interface Support

2017-06-13 Thread Salil Mehta
This patch adds the support of IMP (Integrated Management Processor) command interface to the HNS3 driver. Each PF/VF has support of CQP(Command Queue Pair) ring interface. Each CQP consis of send queue CSQ and receive queue CRQ. There are various commands a PF/VF may support, like for Flow Table

[PATCH V2 net-next 2/8] net: hns3: Add support of the HNAE3 framework

2017-06-13 Thread Salil Mehta
This patch adds the support of the HNAE3 (Hisilicon Network Acceleration Engine 3) framework support to the HNS3 driver. Framework facilitates clients like ENET(HNS3 Ethernet Driver), RoCE and user-space Ethernet drivers (like ODP etc.) to register with HNAE3 devices and their associated

[PATCH V2 net-next 7/8] net: hns3: Add Ethtool support to HNS3 driver

2017-06-13 Thread Salil Mehta
This patch adds the support of the Ethtool interface to the HNS3 Ethernet driver. Various commands to read the statistics, configure the offloading, loopback selftest etc. are supported. Signed-off-by: Daode Huang Signed-off-by: lipeng

Re: [PATCH] Add printk for bonding module packets_per_slave parameter

2017-06-13 Thread kbuild test robot
Hi Michael, [auto build test WARNING on net-next/master] [also build test WARNING on v4.12-rc5 next-20170613] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Michael-Dilmore/Add-printk

[PATCH V2 net-next 6/8] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Salil Mehta
This patch adds the support of MDIO bus interface for HNS3 driver. Code provides various interfaces to start and stop the PHY layer and to read and write the MDIO bus or PHY. Signed-off-by: Daode Huang Signed-off-by: lipeng Signed-off-by: Salil

[PATCH V2 net-next 5/8] net: hns3: Add support of TX Scheduler & Shaper to HNS3 driver

2017-06-13 Thread Salil Mehta
THis patch adds the support of the Scheduling and Shaping functionalities during the transmit leg. This also adds the support of Pause at MAC level. (Pause at per-priority level shall be added later along with the DCB feature). Hardware as such consists of two types of cofiguration of 6 level

[PATCH V2 net-next 4/8] net: hns3: Add HNS3 Acceleration Engine & Compatibility Layer Support

2017-06-13 Thread Salil Mehta
This patch adds the support of Hisilicon Network Subsystem Accceleration Engine and common operations to access it. This layer provides access to the hardware configuration, hardware statistics. This layer is also responsible for triggering the initialization of the PHY layer through the below

[PATCH V2 net-next 8/8] net: hns3: Add HNS3 driver to kernel build framework & MAINTAINERS

2017-06-13 Thread Salil Mehta
This patch updates the MAINTAINERS file with HNS3 Ethernet driver maintainers names and other details. This also introduces the new Makefiles required to build the HNS3 Ethernet driver and updates the existing Kconfig file in the hisilicon folder. Signed-off-by: Salil Mehta

RE: [PATCH net-next 6/9] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Salil Mehta
Hi Andrew, > -Original Message- > From: Andrew Lunn [mailto:and...@lunn.ch] > Sent: Tuesday, June 13, 2017 11:41 PM > To: Salil Mehta > Cc: Florian Fainelli; da...@davemloft.net; Zhuangyuzeng (Yisen); > huangdaode; lipeng (Y); mehta.salil@gmail.com; > netdev@vger.kernel.org;

[PATCH 0/2] bpf: permit bpf program narrower loads for ctx fields

2017-06-13 Thread Yonghong Song
Today, if users try to access a ctx field through a narrower load, e.g., __be16 prot = __sk_buff->protocol, verifier will fail. This set contains the verifier change to permit such loads for certain ctx fields as well as the new test cases in selftests/bpf. Yonghong Song (2): bpf: permits

[PATCH 1/2] bpf: permits narrower load from bpf program context fields

2017-06-13 Thread Yonghong Song
Currently, verifier will reject a program if it contains an narrower load from the bpf context structure. For example, __u8 h = __sk_buff->hash, or __u16 p = __sk_buff->protocol __u32 sample_period = bpf_perf_event_data->sample_period which are narrower loads of 4-byte or

[PATCH 2/2] selftests/bpf: Add test cases to test narrower ctx field loads

2017-06-13 Thread Yonghong Song
Add test cases in test_verifier and test_progs. Negative tests are added in test_verifier as well. The test in test_progs will compare the value of narrower ctx field load result vs. the masked value of normal full-field load result, and will fail if they are not the same. Acked-by: Daniel

Re: [PATCH net-next 6/9] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Andrew Lunn
> > Hum why do you do this? mdiobus_register() will scan through your bus > > provided that you set an appropriate phy_mask value (here you tell it > > not to) and you already provide the PHY address to scan for > > > I know this looks weird but the reason why it appears as it is in code is: > >

[PATCH v2 1/5] MIPS: Optimize uasm insn lookup.

2017-06-13 Thread David Daney
Instead of doing a linear search through the insn_table for each instruction, use the opcode as direct index into the table. This will give constant time lookup performance as the number of supported opcodes increases. Make the tables const as they are only ever read. For uasm-mips.c sort the

[PATCH v2 0/5] MIPS: Implement eBPF JIT.

2017-06-13 Thread David Daney
Changes in v2: - Squash a couple of the uasm cleanups. - Make insn_table_MM const (suggested by Matt Redfearn) - Put the eBPF in its own source file (should fix build warnings/errors on 32-bit kernel builds). - Use bpf_jit_binary_alloc() (suggested by Daniel Borkmann) -

[PATCH v2 2/5] MIPS: Correctly define DBSHFL type instruction opcodes.

2017-06-13 Thread David Daney
DSHD was incorrectly classified as being BSHFL, and DSHD was missing altogether. Signed-off-by: David Daney --- arch/mips/include/uapi/asm/inst.h | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/arch/mips/include/uapi/asm/inst.h

[PATCH v2 5/5] MIPS: Give __secure_computing() access to syscall arguments.

2017-06-13 Thread David Daney
KProbes of __seccomp_filter() are not very useful without access to the syscall arguments. Do what x86 does, and populate a struct seccomp_data to be passed to __secure_computing(). This allows samples/bpf/tracex5 to extract a sensible trace. Signed-off-by: David Daney

[PATCH v2 4/5] MIPS: Add support for eBPF JIT.

2017-06-13 Thread David Daney
Since the eBPF machine has 64-bit registers, we only support this in 64-bit kernels. As of the writing of this commit log test-bpf is showing: test_bpf: Summary: 316 PASSED, 0 FAILED, [308/308 JIT'ed] All current test cases are successfully compiled. Many examples in samples/bpf are usable,

[PATCH v2 3/5] MIPS: Add some instructions to uasm.

2017-06-13 Thread David Daney
Follow on patches for eBPF JIT require these additional instructions: insn_bgtz, insn_blez, insn_break, insn_ddivu, insn_dmultu, insn_dsbh, insn_dshd, insn_dsllv, insn_dsra32, insn_dsrav, insn_dsrlv, insn_lbu, insn_movn, insn_movz, insn_multu, insn_nor, insn_sb, insn_sh, insn_slti,

Re: [PATCH RFC net-next 4/4] net/mlx5: Add CONFIG_MLX5_ESWITCH Kconfig

2017-06-13 Thread Saeed Mahameed
On Tue, Jun 13, 2017 at 9:21 PM, Jes Sorensen wrote: > On 06/13/2017 01:58 PM, Saeed Mahameed wrote: >> >> On Mon, Jun 12, 2017 at 9:20 PM, Jes Sorensen wrote: >>> >>> On 06/07/2017 07:42 PM, Saeed Mahameed wrote: This patch gives the option to

Odd use of %14pM in net/batman-adv/distributed-arp-table.c

2017-06-13 Thread Joe Perches
An output mac address is 17 bytes 1 12345678901234567 00:11:22:33:44:55 but in net/batman-adv/distributed-arp-table.c int batadv_dat_cache_seq_print_text(struct seq_file *seq, void *offset) { [...] seq_printf(seq, " * %15pI4 %14pM %4i %6i:%02i\n",

Re: Repeatable inet6_dump_fib crash in stock 4.12.0-rc4+

2017-06-13 Thread Cong Wang
On Tue, Jun 13, 2017 at 1:16 PM, Ben Greear wrote: > On 06/09/2017 02:25 PM, Eric Dumazet wrote: >> >> On Fri, 2017-06-09 at 07:27 -0600, David Ahern wrote: >>> >>> On 6/8/17 11:55 PM, Cong Wang wrote: Apparently fn->parent is NULL here for some reason, but I

RE: [PATCH net-next 6/9] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Salil Mehta
Hi Florian, > -Original Message- > From: Florian Fainelli [mailto:f.faine...@gmail.com] > Sent: Saturday, June 10, 2017 8:04 PM > To: Salil Mehta; da...@davemloft.net > Cc: Zhuangyuzeng (Yisen); huangdaode; lipeng (Y); > mehta.salil@gmail.com; netdev@vger.kernel.org; linux- >

[PATCH] rtlwifi: rtl8821ae: remove unused variable

2017-06-13 Thread Gustavo A. R. Silva
Remove unused variable rtlhal. Addresses-Coverity-ID: 1248810 Signed-off-by: Gustavo A. R. Silva --- drivers/net/wireless/realtek/rtlwifi/rtl8821ae/hw.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8821ae/hw.c

Re: [PATCH] via-rhine: add support for changing MTU

2017-06-13 Thread David Miller
From: Magnus Damm Date: Wed, 14 Jun 2017 02:18:27 +0900 > From: Magnus Damm > > Allow adjusting the MTU for via-rhine devices in case of no TX alignment > buffer is used. > > Lightly tested on ALIX2D13 hardware by making use of VXLAN with MTU

Re: [RFC PATCH net-next 15/15] bpf: Sample bpf program to set sndcwnd clamp

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 11:00:04 -0700 > +SEC("sockops") > +int bpf_clamp(struct __sk_buff *skb) > +{ > + struct bpf_socket_ops *skops = (struct bpf_socket_ops *) skb; > + char fmt1[] = "BPF command: %d\n"; > + char fmt2[] = " Returning %d\n"; > +

Re: [RFC PATCH net-next 13/15] bpf: Sample BPF program to set initial cwnd

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 11:00:02 -0700 > +SEC("sockops") > +int bpf_iw(struct __sk_buff *skb) > +{ > + struct bpf_socket_ops *skops = (struct bpf_socket_ops *) skb; > + char fmt1[] = "BPF command: %d\n"; > + char fmt2[] = " Returning %d\n"; > +

Re: [RFC PATCH net-next 11/15] bpf: Sample BPF program to set congestion control

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 11:00:00 -0700 > +SEC("sockops") > +int bpf_cong(struct __sk_buff *skb) > +{ > + struct bpf_socket_ops *skops = (struct bpf_socket_ops *) skb; > + char fmt1[] = "BPF command: %d\n"; > + char fmt2[] = " Returning %d\n"; > +

Re: [PATCH] Add printk for bonding module packets_per_slave parameter

2017-06-13 Thread kbuild test robot
Hi Michael, [auto build test WARNING on net-next/master] [also build test WARNING on v4.12-rc5 next-20170613] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Michael-Dilmore/Add-printk

Re: [RFC PATCH net-next 10/15] bpf: Add support for changing congestion control

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 10:59:59 -0700 > @@ -2698,8 +2698,15 @@ BPF_CALL_5(bpf_setsockopt, struct bpf_socket_ops_kern > *, bpf_socket, > } > } else if (level == SOL_TCP && > bpf_socket->sk->sk_prot->setsockopt ==

Re: [RFC PATCH net-next 09/15] bpf: Sample BPF program to set buffer sizes

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 10:59:58 -0700 > diff --git a/samples/bpf/tcp_bufs_kern.c b/samples/bpf/tcp_bufs_kern.c > new file mode 100644 > index 000..a407b73 > --- /dev/null > +++ b/samples/bpf/tcp_bufs_kern.c ... > +SEC("sockops") > +int bpf_bufs(struct

Re: [PATCH nf-next] netns: add and use net_ns_barrier

2017-06-13 Thread Cong Wang
On Tue, Jun 13, 2017 at 11:07 AM, Florian Westphal wrote: > Historically it wasn't needed because we just clear out the helper area > in the affected conntracks (i.e, future packets are not inspected by > the helper anymore). > > When conntracks were made per-netns this problem

Re: [RFC PATCH net-next 07/15] bpf: Add setsockopt helper function to bpf

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 10:59:56 -0700 > +BPF_CALL_5(bpf_setsockopt, struct bpf_socket_ops_kern *, bpf_socket, > +int, level, int, optname, char *, optval, int, optlen) > +{ > + int val; > + int ret = 0; > + struct sock *sk =

Re: [PATCH net-next 6/9] net: hns3: Add MDIO support to HNS3 Ethernet driver for hip08 SoC

2017-06-13 Thread Andrew Lunn
> You are correct is_c45 should not be derived from the type of PHY like > it is being done here. I have changed this code and now we are getting this > information from the IMP(Integrated Management Processor) which handles > the NIC commands and also maintains Ethernet specific configuration.

Re: [RFC PATCH net-next 05/15] bpf: Support for setting initial receive window

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 10:59:54 -0700 > diff --git a/net/ipv4/tcp_minisocks.c b/net/ipv4/tcp_minisocks.c > index d0642df..a0032ea 100644 > --- a/net/ipv4/tcp_minisocks.c > +++ b/net/ipv4/tcp_minisocks.c > @@ -352,6 +352,7 @@ void tcp_openreq_init_rwin(struct

Re: [RFC PATCH net-next 06/15] bpf: Sample bpf program to set initial window

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 10:59:55 -0700 > +SEC("sockops") > +int bpf_rwnd(struct __sk_buff *skb) > +{ > + struct bpf_socket_ops *skops = (struct bpf_socket_ops *) skb; > + char fmt1[] = "BPF command: %d\n"; > + char fmt2[] = " Returning %d\n"; > +

Re: [RFC PATCH net-next 04/15] bpf: Sample bpf program to set SYN/SYN-ACK RTOs

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 10:59:53 -0700 > + > + // Check for TIMEOUT_INIT operation and IPv6 addresses > + if (op == BPF_SOCKET_OPS_TIMEOUT_INIT && > + skops->family == AF_INET6) { > + > + // If the first 5.5 bytes of the IPv6

Re: [RFC PATCH net-next 01/15] net: BPF support for socket ops

2017-06-13 Thread David Miller
From: Lawrence Brakmo Date: Tue, 13 Jun 2017 10:59:50 -0700 > diff --git a/include/linux/filter.h b/include/linux/filter.h > index a20ba40..8f69b8b 100644 > --- a/include/linux/filter.h > +++ b/include/linux/filter.h > @@ -899,4 +899,14 @@ static inline int

[PATCH v2 net-next 8/9] bpf: nfp: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
Add support to nfp to report bpf_prog ID during XDP_QUERY_PROG. Signed-off-by: Martin KaFai Lau Cc: Jakub Kicinski Acked-by: Alexei Starovoitov Acked-by: Daniel Borkmann ---

[PATCH v2 net-next 3/9] bpf: mlx5e: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
Add support to mlx5e to report bpf_prog ID during XDP_QUERY_PROG. Signed-off-by: Martin KaFai Lau Cc: Tariq Toukan Cc: Saeed Mahameed Acked-by: Alexei Starovoitov Acked-by: Daniel Borkmann Acked-by:

[PATCH v2 net-next 5/9] bpf: bnxt: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
Add support to bnxt to report bpf_prog ID during XDP_QUERY_PROG. Signed-off-by: Martin KaFai Lau Cc: Michael Chan Acked-by: Alexei Starovoitov Acked-by: Daniel Borkmann ---

[PATCH v2 net-next 9/9] bpf: qede: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
Add support to qede to report bpf_prog ID during XDP_QUERY_PROG. Signed-off-by: Martin KaFai Lau Cc: Mintz Yuval Acked-by: Alexei Starovoitov Acked-by: Daniel Borkmann --- drivers/net/ethernet/qlogic/qede/qede_filter.c

[PATCH v2 net-next 1/9] net: Add IFLA_XDP_PROG_ID

2017-06-13 Thread Martin KaFai Lau
Expose prog_id through IFLA_XDP_PROG_ID. This patch makes modification to generic_xdp. The later patches will modify other xdp-supported drivers. prog_id is added to struct net_dev_xdp. iproute2 patch will be followed. Here is how the 'ip link' will look like: > ip link show eth0 3: eth0:

[PATCH v2 net-next 6/9] bpf: thunderx: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
Add support to thunderx to report bpf_prog ID during XDP_QUERY_PROG. Signed-off-by: Martin KaFai Lau Cc: Sunil Goutham Acked-by: Alexei Starovoitov Acked-by: Daniel Borkmann ---

[PATCH v2 net-next 7/9] bpf: ixgbe: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
Add support to ixgbe to report bpf_prog ID during XDP_QUERY_PROG. Signed-off-by: Martin KaFai Lau Cc: Alexander Duyck Cc: John Fastabend Acked-by: Alexei Starovoitov Acked-by: Daniel Borkmann

[PATCH v2 net-next 0/9] bpf: xdp: Report bpf_prog ID in IFLA_XDP

2017-06-13 Thread Martin KaFai Lau
This is the first usage of the new bpf_prog ID. It is for reporting the ID of a xdp_prog through netlink. It rides on the existing IFLA_XDP. This patch adds IFLA_XDP_PROG_ID for the bpf_prog ID reporting. It starts with changing the generic_xdp first. After that, the hardware driver is

[PATCH v2 net-next 4/9] bpf: virtio_net: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
Add support to virtio_net to report bpf_prog ID during XDP_QUERY_PROG. Signed-off-by: Martin KaFai Lau Cc: John Fastabend Cc: Jason Wang Acked-by: Alexei Starovoitov Acked-by: Daniel Borkmann ---

[PATCH v2 net-next 2/9] bpf: mlx4: Report bpf_prog ID during XDP_QUERY_PROG

2017-06-13 Thread Martin KaFai Lau
Add support to mlx4 to report bpf_prog ID during XDP_QUERY_PROG. Signed-off-by: Martin KaFai Lau Cc: Tariq Toukan Cc: Saeed Mahameed Acked-by: Alexei Starovoitov Acked-by: Daniel Borkmann ---

Re: [PATCH net-next] networking: use skb_put_zero()

2017-06-13 Thread David Miller
These are bogus reports I think. Johannes's changes depends upon the wireless GIT tree I pulled in right before I applied his patch.

  1   2   3   >