[PATCH v3 4/4] xfrm: clone whole liftime_cur structure in xfrm_do_migrate

2020-09-03 Thread Antony Antony
When we clone state only add_time was cloned. It missed values like bytes, packets. Now clone the all members of the structure. v1->v3: - use memcpy to copy the entire structure Fixes: 80c9abaabf42 ("[XFRM]: Extension for dynamic update of endpoint address(es)") Signed-off-by: Antony Antony -

[PATCH v3 3/4] xfrm: clone XFRMA_SEC_CTX in xfrm_do_migrate

2020-09-03 Thread Antony Antony
XFRMA_SEC_CTX was not cloned from the old to the new. Migrate this attribute during XFRMA_MSG_MIGRATE v1->v2: - return -ENOMEM on error v2->v3: - fix return type to int Fixes: 80c9abaabf42 ("[XFRM]: Extension for dynamic update of endpoint address(es)") Signed-off-by: Antony Antony --- net/x

[PATCH v3 2/4] xfrm: clone XFRMA_REPLAY_ESN_VAL in xfrm_do_migrate

2020-09-03 Thread Antony Antony
XFRMA_REPLAY_ESN_VAL was not cloned completely from the old to the new. Migrate this attribute during XFRMA_MSG_MIGRATE v1->v2: - move curleft cloning to a separate patch Fixes: af2f464e326e ("xfrm: Assign esn pointers when cloning a state") Signed-off-by: Antony Antony --- include/net/xfrm.h

[PATCH v3 1/4] xfrm: clone XFRMA_SET_MARK in xfrm_do_migrate

2020-09-03 Thread Antony Antony
XFRMA_SET_MARK and XFRMA_SET_MARK_MASK was not cloned from the old to the new. Migrate these two attributes during XFRMA_MSG_MIGRATE Fixes: 9b42c1f179a6 ("xfrm: Extend the output_mark to support input direction and masking.") Signed-off-by: Antony Antony --- net/xfrm/xfrm_state.c | 1 + 1 file

RE: [PATCH v2 net-next 6/9] bpf: helpers: add bpf_xdp_adjust_mb_header helper

2020-09-03 Thread John Fastabend
Lorenzo Bianconi wrote: > Introduce bpf_xdp_adjust_mb_header helper in order to adjust frame > headers moving *offset* bytes from/to the second buffer to/from the > first one. > This helper can be used to move headers when the hw DMA SG is not able > to copy all the headers in the first fragment an

[PATCH bpf-next 1/2] samples: bpf: Replace bpf_program__title() with bpf_program__section_name()

2020-09-03 Thread Daniel T. Lee
>From commit 521095842027 ("libbpf: Deprecate notion of BPF program "title" in favor of "section name""), the term title has been replaced with section name in libbpf. Since the bpf_program__title() has been deprecated, this commit switches this function to bpf_program__section_name(). Due to this

[PATCH bpf-next 2/2] samples: bpf: add xsk_fwd test file to .gitignore

2020-09-03 Thread Daniel T. Lee
This commit adds xsk_fwd test file to .gitignore which is newly added to samples/bpf. Signed-off-by: Daniel T. Lee --- samples/bpf/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/samples/bpf/.gitignore b/samples/bpf/.gitignore index 034800c4d1e6..b2f29bc8dc43 100644 --- a/samples/

[PATCH 1/2] samples: bpf: Replace bpf_program__title() with bpf_program__section_name()

2020-09-03 Thread Daniel T. Lee
>From commit 521095842027 ("libbpf: Deprecate notion of BPF program "title" in favor of "section name""), the term title has been replaced with section name in libbpf. Since the bpf_program__title() has been deprecated, this commit switches this function to bpf_program__section_name(). Due to this

[PATCH 2/2] samples: bpf: add xsk_fwd test file to .gitignore

2020-09-03 Thread Daniel T. Lee
This commit adds xsk_fwd test file to .gitignore which is newly added to samples/bpf. Signed-off-by: Daniel T. Lee --- samples/bpf/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/samples/bpf/.gitignore b/samples/bpf/.gitignore index 034800c4d1e6..b2f29bc8dc43 100644 --- a/samples/

[PATCH v5 4/7] net: dsa: hellcreek: Add support for hardware timestamping

2020-09-03 Thread Kurt Kanzenbach
From: Kamil Alkhouri The switch has the ability to take hardware generated time stamps per port for PTPv2 event messages in Rx and Tx direction. That is useful for achieving needed time synchronization precision for TSN devices/switches. So add support for it. There are two directions: * RX

[PATCH v5 2/7] net: dsa: Add DSA driver for Hirschmann Hellcreek switches

2020-09-03 Thread Kurt Kanzenbach
Add a basic DSA driver for Hirschmann Hellcreek switches. Those switches are implementing features needed for Time Sensitive Networking (TSN) such as support for the Time Precision Protocol and various shapers like the Time Aware Shaper. This driver includes basic support for networking: * VLAN

[PATCH v5 7/7] dt-bindings: net: dsa: Add documentation for Hellcreek switches

2020-09-03 Thread Kurt Kanzenbach
Add basic documentation and example. Signed-off-by: Kurt Kanzenbach Reviewed-by: Rob Herring Reviewed-by: Florian Fainelli --- .../bindings/net/dsa/hellcreek.yaml | 127 ++ 1 file changed, 127 insertions(+) create mode 100644 Documentation/devicetree/bindings/net/dsa

[PATCH v5 0/7] Hirschmann Hellcreek DSA driver

2020-09-03 Thread Kurt Kanzenbach
Hi, this series adds a DSA driver for the Hirschmann Hellcreek TSN switch IP. Characteristics of that IP: * Full duplex Ethernet interface at 100/1000 Mbps on three ports * IEEE 802.1Q-compliant Ethernet Switch * IEEE 802.1Qbv Time-Aware scheduling support * IEEE 1588 and IEEE 802.1AS support

[PATCH v5 6/7] dt-bindings: Add vendor prefix for Hirschmann

2020-09-03 Thread Kurt Kanzenbach
Hirschmann is building devices for automation and networking. Add them to the vendor prefixes. Signed-off-by: Kurt Kanzenbach Reviewed-by: Florian Fainelli Acked-by: Rob Herring --- Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Doc

[PATCH v5 3/7] net: dsa: hellcreek: Add PTP clock support

2020-09-03 Thread Kurt Kanzenbach
From: Kamil Alkhouri The switch has internal PTP hardware clocks. Add support for it. There are three clocks: * Synchronized * Syntonized * Free running Currently the synchronized clock is exported to user space which is a good default for the beginning. The free running clock might be expor

[PATCH v5 5/7] net: dsa: hellcreek: Add PTP status LEDs

2020-09-03 Thread Kurt Kanzenbach
The switch has two controllable I/Os which are usually connected to LEDs. This is useful to immediately visually see the PTP status. These provide two signals: * is_gm This LED can be activated if the current device is the grand master in that PTP domain. * sync_good This LED can be

[PATCH v5 1/7] net: dsa: Add tag handling for Hirschmann Hellcreek switches

2020-09-03 Thread Kurt Kanzenbach
The Hirschmann Hellcreek TSN switches have a special tagging protocol for frames exchanged between the CPU port and the master interface. The format is a one byte trailer indicating the destination or origin port. It's quite similar to the Micrel KSZ tagging. That's why the implementation is based

Re: [PATCH net-next 0/3] net: phy: Support enabling clocks prior to bus probe

2020-09-03 Thread Adam Rudziński
W dniu 2020-09-04 o 06:04, Florian Fainelli pisze: On 9/2/2020 9:39 PM, Florian Fainelli wrote: Hi all, This patch series takes care of enabling the Ethernet PHY clocks in DT-based systems (we have no way to do it for ACPI, and ACPI would likely keep all of this hardware enabled anyway). P

Re: [PATCH net-next 3/3] net: phy: bcm7xxx: request and manage GPHY clock

2020-09-03 Thread Marco Felsch
On 20-09-02 21:39, Florian Fainelli wrote: > The internal Gigabit PHY on Broadcom STB chips has a digital clock which > drives its MDIO interface among other things, the driver now requests > and manage that clock during .probe() and .remove() accordingly. Hi Florian, Seems like you added the sam

Re: [PATCH net-next 3/3] net: phy: bcm7xxx: request and manage GPHY clock

2020-09-03 Thread Marco Felsch
Hi Florian, On 20-09-02 21:39, Florian Fainelli wrote: > The internal Gigabit PHY on Broadcom STB chips has a digital clock which > drives its MDIO interface among other things, the driver now requests > and manage that clock during .probe() and .remove() accordingly. > > Signed-off-by: Florian F

RE: [PATCH v2 net-next 0/9] mvneta: introduce XDP multi-buffer support

2020-09-03 Thread John Fastabend
Lorenzo Bianconi wrote: > - Finalize XDP multi-buffer support for mvneta driver introducing the > capability to map non-linear buffers on tx side. > - Introduce multi-buffer bit (mb) in xdp_frame/xdp_buffer to specify if > shared_info area has been properly initialized. > - Initialize multi-buf

RE: [EXT] Re: [net-next PATCH 0/2] Introduce mbox tracepoints for Octeontx2

2020-09-03 Thread Sunil Kovvuri Goutham
> -Original Message- > From: Jakub Kicinski > Sent: Friday, September 4, 2020 12:48 AM > To: sundeep.l...@gmail.com > Cc: da...@davemloft.net; netdev@vger.kernel.org; Sunil Kovvuri Goutham > ; Subbaraya Sundeep Bhatta > > Subject: [EXT] Re: [net-next PATCH 0/2] Introduce mbox tracepoin

Re: Packet gets stuck in NOLOCK pfifo_fast qdisc

2020-09-03 Thread John Fastabend
Cong Wang wrote: > On Thu, Sep 3, 2020 at 1:40 AM Paolo Abeni wrote: > > > > On Wed, 2020-09-02 at 22:01 -0700, Cong Wang wrote: > > > Can you test the attached one-line fix? I think we are overthinking, > > > probably all > > > we need here is a busy wait. > > > > I think that will solve, but I a

Re: [PATCH net-next RFC v3 02/14] devlink: Add reload actions counters

2020-09-03 Thread Moshe Shemesh
On 9/2/2020 3:01 AM, Jakub Kicinski wrote: External email: Use caution opening links or attachments On Tue, 1 Sep 2020 22:05:36 +0300 Moshe Shemesh wrote: +void devlink_reload_actions_cnts_update(struct devlink *devlink, unsigned long actions_done) +{ + int action; + + for (action = 0; ac

[PATCH bpf-next 1/2] libbpf: fix another __u64 cast in printf

2020-09-03 Thread Andrii Nakryiko
Another issue of __u64 needing either %lu or %llu, depending on the architecture. Fix with cast to `unsigned long long`. Fixes: 7e06aad52929 ("libbpf: Add multi-prog section support for struct_ops") Signed-off-by: Andrii Nakryiko --- tools/lib/bpf/libbpf.c | 2 +- 1 file changed, 1 insertion(+),

[PATCH bpf-next 2/2] libbpf: fix potential multiplication overflow

2020-09-03 Thread Andrii Nakryiko
Detected by LGTM static analyze in Github repo, fix potential multiplication overflow before result is casted to size_t. Fixes: 8505e8709b5e ("libbpf: Implement generalized .BTF.ext func/line info adjustment") Signed-off-by: Andrii Nakryiko --- tools/lib/bpf/libbpf.c | 2 +- 1 file changed, 1 i

Re: [PATCH net-next 0/3] net: phy: Support enabling clocks prior to bus probe

2020-09-03 Thread Florian Fainelli
On 9/2/2020 9:39 PM, Florian Fainelli wrote: Hi all, This patch series takes care of enabling the Ethernet PHY clocks in DT-based systems (we have no way to do it for ACPI, and ACPI would likely keep all of this hardware enabled anyway). Please test on your respective platforms, mine still s

Re: [PATCH net-next] net: dsa: bcm_sf2: Ensure that MDIO diversion is used

2020-09-03 Thread Florian Fainelli
On 9/3/2020 3:03 PM, Andrew Lunn wrote: The firmware provides the Device Tree but here is the relevant section for you pasted below. The problematic device is a particular revision of the silicon (D0) which got later fixed (E0) however the Device Tree was created after the fixed platform, not

Re: Packet gets stuck in NOLOCK pfifo_fast qdisc

2020-09-03 Thread Kehuan Feng
Hi Hillf, Cong, Paolo, Sorry for the late reply due to other urgent task. I tried Hillf's patch (shown below on my tree) and it doesn't help and the jitter shows up very quickly. --- ./include/net/sch_generic.h.orig 2020-08-21 15:13:51.787952710 +0800 +++ ./include/net/sch_generic.h 2020-09-04 1

[PATCH] atm: eni: fix the missed pci_disable_device() for eni_init_one()

2020-09-03 Thread Jing Xiangfeng
eni_init_one() misses to call pci_disable_device() in an error path. Jump to err_disable to fix it. Signed-off-by: Jing Xiangfeng --- drivers/atm/eni.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/atm/eni.c b/drivers/atm/eni.c index 39be444534d0..316a9947541f 10064

[Patch net] act_ife: load meta modules before tcf_idr_check_alloc()

2020-09-03 Thread Cong Wang
The following deadlock scenario is triggered by syzbot: Thread A: Thread B: tcf_idr_check_alloc() ... populate_metalist() rtnl_unlock() rtnl_lock() ... request_module()

Re: [GIT] Networking

2020-09-03 Thread pr-tracker-bot
The pull request you sent on Thu, 03 Sep 2020 17:03:19 -0700 (PDT): > git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git refs/heads/master has been merged into torvalds/linux.git: https://git.kernel.org/torvalds/c/3e8d3bdc2a757cc6be5470297947799a7df445cc Thank you! -- Deet-doot-dot,

Re: [PATCH net-next] net: sch_generic: aviod concurrent reset and enqueue op for lockless qdisc

2020-09-03 Thread John Fastabend
Cong Wang wrote: > On Wed, Sep 2, 2020 at 7:22 PM Yunsheng Lin wrote: > > > > On 2020/9/3 9:48, Cong Wang wrote: > > > On Wed, Sep 2, 2020 at 6:22 PM Yunsheng Lin > > > wrote: > > >> > > >> On 2020/9/3 8:35, Cong Wang wrote: > > >>> On Tue, Sep 1, 2020 at 11:35 PM Yunsheng Lin > > >>> wrote: >

Re: [PATCH bpf-next v3 3/8] libbpf: Add BPF_PROG_BIND_MAP syscall and use it on .metadata section

2020-09-03 Thread Alexei Starovoitov
On Wed, Sep 02, 2020 at 07:31:33PM -0700, Andrii Nakryiko wrote: > On Fri, Aug 28, 2020 at 12:37 PM Stanislav Fomichev wrote: > > > > From: YiFei Zhu > > > > The patch adds a simple wrapper bpf_prog_bind_map around the syscall. > > And when using libbpf to load a program, it will probe the kernel

Re: [PATCH v2 net-next 6/9] bpf: helpers: add bpf_xdp_adjust_mb_header helper

2020-09-03 Thread Alexei Starovoitov
On Thu, Sep 03, 2020 at 10:58:50PM +0200, Lorenzo Bianconi wrote: > +BPF_CALL_2(bpf_xdp_adjust_mb_header, struct xdp_buff *, xdp, > +int, offset) > +{ > + void *data_hard_end, *data_end; > + struct skb_shared_info *sinfo; > + int frag_offset, frag_len; > + u8 *addr; > + > +

Re: [PATCH v2 net-next 6/9] bpf: helpers: add bpf_xdp_adjust_mb_header helper

2020-09-03 Thread Alexei Starovoitov
On Thu, Sep 03, 2020 at 10:58:50PM +0200, Lorenzo Bianconi wrote: > Introduce bpf_xdp_adjust_mb_header helper in order to adjust frame > headers moving *offset* bytes from/to the second buffer to/from the > first one. > This helper can be used to move headers when the hw DMA SG is not able > to cop

Re: [PATCH v2 net-next 0/9] mvneta: introduce XDP multi-buffer support

2020-09-03 Thread Alexei Starovoitov
On Thu, Sep 03, 2020 at 10:58:44PM +0200, Lorenzo Bianconi wrote: > For the moment we have not implemented any self-test for the introduced the > bpf > helpers. We can address this in a follow up series if the proposed approach > is accepted. selftest has to be part of the same patch set.

Re: [PATCH v2 net-next 1/9] xdp: introduce mb in xdp_buff/xdp_frame

2020-09-03 Thread Alexei Starovoitov
On Thu, Sep 03, 2020 at 10:58:45PM +0200, Lorenzo Bianconi wrote: > Introduce multi-buffer bit (mb) in xdp_frame/xdp_buffer to specify > if shared_info area has been properly initialized for non-linear > xdp buffers > > Signed-off-by: Lorenzo Bianconi > --- > include/net/xdp.h | 8 ++-- > ne

Re: [PATCH bpf 0/2] bpf: do not use bucket_lock for hashmap iterator

2020-09-03 Thread Alexei Starovoitov
On Wed, Sep 2, 2020 at 4:54 PM Yonghong Song wrote: > > Currently, the bpf hashmap iterator takes a bucket_lock, a spin_lock, > before visiting each element in the bucket. This will cause a deadlock > if a map update/delete operates on an element with the same > bucket id of the visited map. > > T

Re: [PATCH] selftests/bpf: Fix check in global_data_init.

2020-09-03 Thread Alexei Starovoitov
On Thu, Sep 3, 2020 at 1:36 PM Andrii Nakryiko wrote: > > On Thu, Sep 3, 2020 at 1:06 PM Hao Luo wrote: > > > > The returned value of bpf_object__open_file() should be checked with > > libbpf_get_error() rather than NULL. This fix prevents test_progs from > > crash when test_global_data.o is not

Re: [PATCH v3 bpf-next 00/14] Add libbpf full support for BPF-to-BPF calls

2020-09-03 Thread Alexei Starovoitov
On Thu, Sep 03, 2020 at 01:35:28PM -0700, Andrii Nakryiko wrote: > > This patch set removes all such restrictions and adds complete support for > using BPF sub-program calls on BPF side. This is achieved through libbpf > tracking subprograms individually and detecting which subprograms are used by

[PATCH v2 net-next 2/2] ionic: add devlink firmware update

2020-09-03 Thread Shannon Nelson
Add support for firmware update through the devlink interface. This update copies the firmware object into the device, asks the current firmware to install it, then asks the firmware to select the new firmware for the next boot-up. The install and select steps are launched as asynchronous requests

[PATCH v2 net-next 1/2] ionic: update the fw update api

2020-09-03 Thread Shannon Nelson
Add the rest of the firmware api bits needed to support the driver running a firmware update. Signed-off-by: Shannon Nelson --- .../net/ethernet/pensando/ionic/ionic_if.h| 33 ++- .../net/ethernet/pensando/ionic/ionic_main.c | 4 +++ 2 files changed, 29 insertions(+), 8 del

[PATCH v2 net-next 0/2] ionic: add devlink dev flash support

2020-09-03 Thread Shannon Nelson
Add support for using devlink's dev flash facility to update the firmware on an ionic device. This is a simple model of pushing the firmware file to the NIC, asking the NIC to unpack and install the file into the device, and then selecting it for the next boot. If any of these steps fail, the who

[GIT] Networking

2020-09-03 Thread David Miller
1) Use netif_rx_ni() when necessary in batman-adv stack, from Jussi Kivilinna. 2) Fix loss of RTT samples in rxrpc, from David Howells. 3) Memory leak in hns_nic_dev_probe(), from Dignhao Liu. 4) ravb module cannot be unloaded, fix from Yuusuke Ashizuka. 5) We disable BH for too lokng in s

Re: [PATCH bpf 1/2] bpf: do not use bucket_lock for hashmap iterator

2020-09-03 Thread Alexei Starovoitov
On Wed, Sep 02, 2020 at 07:44:34PM -0700, Yonghong Song wrote: > > > On 9/2/20 6:25 PM, Andrii Nakryiko wrote: > > On Wed, Sep 2, 2020 at 4:56 PM Yonghong Song wrote: > > > > > > Currently, for hashmap, the bpf iterator will grab a bucket lock, a > > > spinlock, before traversing the elements i

Re: [PATCH RESEND] smsc9420: switch from 'pci_' to 'dma_' API

2020-09-03 Thread David Miller
From: Christophe JAILLET Date: Thu, 3 Sep 2020 22:10:55 +0200 > The wrappers in include/linux/pci-dma-compat.h should go away. > > The patch has been generated with the coccinelle script below and has been > hand modified to replace GFP_ with a correct flag. > It has been compile tested. > > W

Re: [PATCH RESEND] epic100: switch from 'pci_' to 'dma_' API

2020-09-03 Thread David Miller
From: Christophe JAILLET Date: Thu, 3 Sep 2020 22:05:09 +0200 > The wrappers in include/linux/pci-dma-compat.h should go away. > > The patch has been generated with the coccinelle script below and has been > hand modified to replace GFP_ with a correct flag. > It has been compile tested. > > W

Re: [PATCH net 0/4] net/smc: fixes 2020-09-03

2020-09-03 Thread David Miller
From: Karsten Graul Date: Thu, 3 Sep 2020 21:53:14 +0200 > Please apply the following patch series for smc to netdev's net tree. > > Patch 1 fixes the toleration of older SMC implementations. Patch 2 > takes care of a problem that happens when SMCR is used after SMCD > initialization failed. Pa

Re: [PATCH net-next v2] net: phy: dp83867: Fix various styling and space issues

2020-09-03 Thread David Miller
From: Dan Murphy Date: Thu, 3 Sep 2020 14:51:12 -0500 > Fix spacing issues reported for misaligned switch..case and extra new > lines. > > Also updated the file header to comply with networking commet style. > > Reviewed-by: Florian Fainelli > Signed-off-by: Dan Murphy Applied, thank you.

Re: [PATCH net-next v1 0/7] udp_tunnel: convert Intel drivers with shared tables

2020-09-03 Thread Jakub Kicinski
On Thu, 23 Jul 2020 20:06:15 + Nguyen, Anthony L wrote: > On Wed, 2020-07-22 at 14:22 -0700, Tony Nguyen wrote: > > On Tue, 2020-07-21 at 18:27 -0700, Jakub Kicinski wrote: > > > This set converts Intel drivers which have the ability to spawn > > > multiple netdevs, but have only one UDP tunn

[PATCH net-next v2] net: tighten the definition of interface statistics

2020-09-03 Thread Jakub Kicinski
This patch is born out of an investigation into which IEEE statistics correspond to which struct rtnl_link_stats64 members. Turns out that there seems to be reasonable consensus on the matter, among many drivers. To save others the time (and it took more time than I'm comfortable admitting) I'm add

Re: [PATCH net-next] net: tighten the definition of interface statistics

2020-09-03 Thread Jakub Kicinski
On Thu, 3 Sep 2020 16:02:28 -0700 Jakub Kicinski wrote: > > > +This simple interface is convenient especially in constrained/embedded > > > +environments without access to tools. However, it's sightly inefficient > > > > > > > sightly seems like the wrong word. Did you mean 'highly inefficien

Re: [PATCH net-next] net: tighten the definition of interface statistics

2020-09-03 Thread Jakub Kicinski
On Thu, 3 Sep 2020 16:40:54 -0600 David Ahern wrote: > On 9/2/20 8:03 PM, Jakub Kicinski wrote: > > +sysfs > > +- > > + > > +Each device directory in sysfs contains a `statistics` directory (e.g. > > +`/sys/class/net/lo/statistics/`) with files corresponding to > > +members of :c:type:`struct r

Re: [net-next 06/10] net/mlx5e: Support multiple SKBs in a TX WQE

2020-09-03 Thread Jakub Kicinski
On Thu, 3 Sep 2020 14:00:18 -0700 Saeed Mahameed wrote: > +static inline void mlx5e_tx_wi_consume_fifo_skbs(struct mlx5e_txqsq *sq, > + struct mlx5e_tx_wqe_info *wi, > + struct mlx5_cqe64 *cqe, > +

Re: [PATCH] net: fec: Fix PHY init after phy_reset_after_clk_enable()

2020-09-03 Thread Marek Vasut
On 9/4/20 12:08 AM, Andrew Lunn wrote: >>> b4 am 20200903043947.3272453-1-f.faine...@gmail.com >> >> That might be a fix for the long run, but I doubt there's any chance to >> backport it all to stable, is there ? > > No. For stable we need something simpler. Like this patch ? > I think a be

Re: [PATCH net-next] net: tighten the definition of interface statistics

2020-09-03 Thread David Ahern
On 9/2/20 8:03 PM, Jakub Kicinski wrote: > diff --git a/Documentation/networking/statistics.rst > b/Documentation/networking/statistics.rst > new file mode 100644 > index ..487b17c166e8 > --- /dev/null > +++ b/Documentation/networking/statistics.rst ... > + > +sysfs > +- > + > +E

Re: [PATCH net-next] ip: expose inet sockopts through inet_diag

2020-09-03 Thread David Miller
From: Wei Wang Date: Tue, 1 Sep 2020 15:10:08 -0700 > Expose all exisiting inet sockopt bits through inet_diag for debug purpose. > Corresponding changes in iproute2 ss will be submitted to output all > these values. > > Signed-off-by: Wei Wang > Signed-off-by: Eric Dumazet > Signed-off-by: M

Re: [PATCH net-next 0/2] Allow more than 255 IPv4 multicast interfaces

2020-09-03 Thread David Miller
From: Paul Davey Date: Wed, 2 Sep 2020 15:22:20 +1200 > Currently it is not possible to use more than 255 multicast interfaces > for IPv4 due to the format of the igmpmsg header which only has 8 bits > available for the VIF ID. There is enough space for the full VIF ID in > the Netlink cache no

Re: [PATCH] net: fec: Fix PHY init after phy_reset_after_clk_enable()

2020-09-03 Thread Andrew Lunn
> > b4 am 20200903043947.3272453-1-f.faine...@gmail.com > > That might be a fix for the long run, but I doubt there's any chance to > backport it all to stable, is there ? No. For stable we need something simpler. > >>> I think a better fix for the original problem is for the SMSC PHY > >>> driv

Re: [PATCH net-next 0/3] net: dsa: bcm_sf2: Clock support

2020-09-03 Thread David Miller
From: Florian Fainelli Date: Tue, 1 Sep 2020 15:59:10 -0700 > This patch series adds support for controlling the SF2 switch core and > divider clock (where applicable). Series applied, thank you.

Re: [PATCH net-next 0/3] net: systemport: Clock support

2020-09-03 Thread David Miller
From: Florian Fainelli Date: Tue, 1 Sep 2020 14:43:45 -0700 > This patch series makes the SYSTEMPORT driver request and manage its > main and Wake-on-LAN clocks appropriately. Series applied, thanks.

Re: [PATCH] net: fec: Fix PHY init after phy_reset_after_clk_enable()

2020-09-03 Thread Marek Vasut
On 9/3/20 11:53 PM, Andrew Lunn wrote: > On Thu, Sep 03, 2020 at 11:36:39PM +0200, Marek Vasut wrote: >> On 9/3/20 11:00 PM, Andrew Lunn wrote: >>> On Thu, Sep 03, 2020 at 10:27:12PM +0200, Marek Vasut wrote: The phy_reset_after_clk_enable() does a PHY reset, which means the PHY loses its

Re: [PATCH net-next] net: dsa: bcm_sf2: Ensure that MDIO diversion is used

2020-09-03 Thread Andrew Lunn
> The firmware provides the Device Tree but here is the relevant section for > you pasted below. The problematic device is a particular revision of the > silicon (D0) which got later fixed (E0) however the Device Tree was created > after the fixed platform, not the problematic one. Both revisions o

Re: [PATCH net-next] ethtool: fix error handling in ethtool_phys_id

2020-09-03 Thread David Miller
From: Edward Cree Date: Tue, 1 Sep 2020 18:52:32 +0100 > If ops->set_phys_id() returned an error, previously we would only break > out of the inner loop, which neither stopped the outer loop nor returned > the error to the user (since 'rc' would be overwritten on the next pass > through the lo

Re: [PATCH] selftests/net: improve descriptions for XFAIL cases in psock_snd.sh

2020-09-03 Thread David Miller
From: Po-Hsu Lin Date: Tue, 1 Sep 2020 23:09:23 +0800 > Before changing this it's a bit confusing to read test output: > raw csum_off with bad offset (fails) > ./psock_snd: write: Invalid argument > > Change "fails" in the test case description to "expected to fail", so > that the test outp

Re: [PATCH] Revert "net: linkwatch: add check for netdevice being present to linkwatch_do_dev"

2020-09-03 Thread David Miller
From: Geert Uytterhoeven Date: Tue, 1 Sep 2020 17:02:37 +0200 > This reverts commit 124eee3f6955f7aa19b9e6ff5c9b6d37cb3d1e2c. Heiner, please review this. Thank you. > Inami-san reported that this commit breaks bridge support in a Xen > environment, and that reverting it fixes this. > > Durin

Re: [PATCH] chelsio/chtls: CHELSIO_INLINE_CRYPTO should depend on CHELSIO_T4

2020-09-03 Thread David Miller
From: Geert Uytterhoeven Date: Tue, 1 Sep 2020 16:58:41 +0200 > While CHELSIO_INLINE_CRYPTO is a guard symbol, and just enabling it does > not cause any additional code to be compiled in, all configuration > options protected by it depend on CONFIG_CHELSIO_T4. Hence it doesn't > make much sense

Re: [PATCH] net: fec: Fix PHY init after phy_reset_after_clk_enable()

2020-09-03 Thread Andrew Lunn
On Thu, Sep 03, 2020 at 11:36:39PM +0200, Marek Vasut wrote: > On 9/3/20 11:00 PM, Andrew Lunn wrote: > > On Thu, Sep 03, 2020 at 10:27:12PM +0200, Marek Vasut wrote: > >> The phy_reset_after_clk_enable() does a PHY reset, which means the PHY > >> loses its register settings. The fec_enet_mii_probe

Re: [PATCH net-next 0/6] Convert mvpp2 to split PCS support

2020-09-03 Thread David Miller
From: Russell King - ARM Linux admin Date: Tue, 1 Sep 2020 14:47:46 +0100 > This series converts the mvpp2 driver to use the split PCS support > that has been merged into phylink last time around. I've been running > this for some time here and, apart from the recent bug fix sent to > net-next, h

Re: [PATCH net-next 1/3] net: phy: Support enabling clocks prior to bus probe

2020-09-03 Thread Florian Fainelli
On 9/3/2020 2:42 PM, Andrew Lunn wrote: On Thu, Sep 03, 2020 at 03:28:22PM -0600, Rob Herring wrote: What if a device requires clocks enabled in a certain order or timing? It's not just clocks, you could have some GPIOs or a regulator that need enabling first. It's device specific, so really

Re: [PATCH net-next 2/2] ionic: add devlink firmware update

2020-09-03 Thread Shannon Nelson
On 9/3/20 2:45 PM, Jakub Kicinski wrote: On Thu, 3 Sep 2020 14:37:40 -0700 Shannon Nelson wrote: On 9/3/20 12:53 PM, Jakub Kicinski wrote: On Wed, 2 Sep 2020 12:57:17 -0700 Shannon Nelson wrote: Add support for firmware update through the devlink interface. This update copies the firmware obj

Re: [PATCH net-next 2/2] ionic: add devlink firmware update

2020-09-03 Thread Jakub Kicinski
On Thu, 3 Sep 2020 14:37:40 -0700 Shannon Nelson wrote: > On 9/3/20 12:53 PM, Jakub Kicinski wrote: > > On Wed, 2 Sep 2020 12:57:17 -0700 Shannon Nelson wrote: > >> Add support for firmware update through the devlink interface. > >> This update copies the firmware object into the device, asks >

Re: [PATCH net-next 1/3] net: phy: Support enabling clocks prior to bus probe

2020-09-03 Thread Florian Fainelli
On 9/3/2020 2:28 PM, Rob Herring wrote: On Wed, Sep 2, 2020 at 10:39 PM Florian Fainelli wrote: Some Ethernet PHYs may require that their clock, which typically drives their logic to respond to reads on the MDIO bus be enabled before issusing a MDIO bus scan. We have a chicken and egg prob

Re: [PATCH net-next 1/3] net: phy: Support enabling clocks prior to bus probe

2020-09-03 Thread Andrew Lunn
On Thu, Sep 03, 2020 at 03:28:22PM -0600, Rob Herring wrote: > What if a device requires clocks enabled in a certain order or timing? > It's not just clocks, you could have some GPIOs or a regulator that > need enabling first. It's device specific, so really needs a per > device solution. This is n

Re: [PATCH net-next 2/2] ionic: add devlink firmware update

2020-09-03 Thread Shannon Nelson
On 9/3/20 12:53 PM, Jakub Kicinski wrote: On Wed, 2 Sep 2020 12:57:17 -0700 Shannon Nelson wrote: Add support for firmware update through the devlink interface. This update copies the firmware object into the device, asks the current firmware to install it, then asks the firmware to set the dev

Re: [PATCH] net: fec: Fix PHY init after phy_reset_after_clk_enable()

2020-09-03 Thread Marek Vasut
On 9/3/20 11:00 PM, Andrew Lunn wrote: > On Thu, Sep 03, 2020 at 10:27:12PM +0200, Marek Vasut wrote: >> The phy_reset_after_clk_enable() does a PHY reset, which means the PHY >> loses its register settings. The fec_enet_mii_probe() starts the PHY >> and does the necessary calls to configure the PH

[PATCH v2 net-next 6/6] sfc: remove efx_tx_queue_partner

2020-09-03 Thread Edward Cree
All users of this function are now gone. Signed-off-by: Edward Cree --- drivers/net/ethernet/sfc/nic_common.h | 10 -- 1 file changed, 10 deletions(-) diff --git a/drivers/net/ethernet/sfc/nic_common.h b/drivers/net/ethernet/sfc/nic_common.h index 3f88c6444fa1..82271f0b8627 100644 ---

Re: [PATCH net-next 2/2] ionic: add devlink firmware update

2020-09-03 Thread Shannon Nelson
On 9/3/20 10:30 AM, Jiri Pirko wrote: Thu, Sep 03, 2020 at 05:58:42PM CEST, snel...@pensando.io wrote: True, they aren't "needed" for operational purposes, but they are rather useful when inspecting a system after getting a report of bad behavior, and I don't think it is nice to pollute dmesg

[PATCH v2 net-next 4/6] sfc: use efx_channel_tx_[old_]fill_level() in Siena/EF10 TX datapath

2020-09-03 Thread Edward Cree
Instead of open-coding the calculation with efx_tx_queue_partner(), use the functions that iterate over numbers of queues other than 2 with efx_for_each_channel_tx_queue(). Signed-off-by: Edward Cree --- drivers/net/ethernet/sfc/net_driver.h | 4 drivers/net/ethernet/sfc/tx.c | 1

[PATCH v2 net-next 5/6] sfc: rewrite efx_tx_may_pio

2020-09-03 Thread Edward Cree
Use efx_for_each_channel_tx_queue() rather than efx_tx_queue_partner(). Make some related simplifications of efx_nic_tx_is_empty() to remove entry points that aren't used. Signed-off-by: Edward Cree --- drivers/net/ethernet/sfc/nic_common.h | 30 ++- drivers/net/ethernet

[PATCH v2 net-next 1/6] sfc: add and use efx_tx_send_pending in tx.c

2020-09-03 Thread Edward Cree
Instead of using efx_tx_queue_partner(), which relies on the assumption that tx_queues_per_channel is 2, efx_tx_send_pending() iterates over txqs with efx_for_each_channel_tx_queue(). We unconditionally set tx_queue->xmit_pending (renamed from xmit_more_available), then condition on xmit_more fo

[PATCH v2 net-next 3/6] sfc: use tx_queue->old_read_count in EF100 TX path

2020-09-03 Thread Edward Cree
As in the Siena/EF10 case, it minimises cacheline ping-pong between the TX and completion paths. Signed-off-by: Edward Cree --- drivers/net/ethernet/sfc/ef100_tx.c | 8 ++-- drivers/net/ethernet/sfc/net_driver.h | 14 ++ 2 files changed, 20 insertions(+), 2 deletions(-) diff

[PATCH v2 net-next 2/6] sfc: make ef100 xmit_more handling look more like ef10's

2020-09-03 Thread Edward Cree
This should cause no functional change; merely make there only be one design of xmit_more handling to understand. As with the EF10/Siena version, we set tx_queue->xmit_pending when we queue up a TX, and clear it when we ring the doorbell (in ef100_notify_tx_desc). While we're at it, make ef100_

[PATCH v2 net-next 0/6] sfc: TXQ refactor

2020-09-03 Thread Edward Cree
Refactor and unify partner-TXQ handling in the EF100 and legacy drivers. The main thrust of this series is to remove from the legacy (Siena/EF10) driver the assumption that a netdev TX queue has precisely two hardware TXQs (checksummed and unchecksummed) associated with it, so that in future we

Re: [PATCH v2 net-next 7/9] bpf: helpers: add multibuffer support

2020-09-03 Thread Maciej Fijalkowski
On Thu, Sep 03, 2020 at 10:58:51PM +0200, Lorenzo Bianconi wrote: > From: Sameeh Jubran > > The implementation is based on this [0] draft by Jesper D. Brouer. > > Provided two new helpers: > > * bpf_xdp_get_frag_count() > * bpf_xdp_get_frags_total_size() > > [0] xdp mb design - > https://gith

Re: [PATCH net-next 1/3] net: phy: Support enabling clocks prior to bus probe

2020-09-03 Thread Rob Herring
On Wed, Sep 2, 2020 at 10:39 PM Florian Fainelli wrote: > > Some Ethernet PHYs may require that their clock, which typically drives > their logic to respond to reads on the MDIO bus be enabled before > issusing a MDIO bus scan. > > We have a chicken and egg problem though which is that we cannot e

Re: [PATCH net-next 1/3] net: phy: Support enabling clocks prior to bus probe

2020-09-03 Thread Andrew Lunn
On Wed, Sep 02, 2020 at 09:39:45PM -0700, Florian Fainelli wrote: > Some Ethernet PHYs may require that their clock, which typically drives > their logic to respond to reads on the MDIO bus be enabled before > issusing a MDIO bus scan. > > We have a chicken and egg problem though which is that we

Re: [PATCH net-next] net: tighten the definition of interface statistics

2020-09-03 Thread Jakub Kicinski
On Thu, 3 Sep 2020 13:48:39 -0700 Florian Fainelli wrote: > >>> + * @rx_bytes: Number of good incoming bytes, corresponding to > >>> @rx_packets. > >>> + * @tx_bytes: Number of good incoming bytes, corresponding to > >>> @tx_packets. > >> > >> Including or excluding FCS? > > > > Good point,

[net-next 06/10] net/mlx5e: Support multiple SKBs in a TX WQE

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy TX MPWQE support for SKBs is coming in one of the following patches, and a single MPWQE can send multiple SKBs. This commit prepares the TX path code to handle such cases: 1. An additional FIFO for SKBs is added, just like the FIFO for DMA chunks. 2. struct mlx5e_tx_wqe

[net-next 04/10] net/mlx5e: Unify constants for WQE_EMPTY_DS_COUNT

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy A constant for the number of DS in an empty WQE (i.e. a WQE without data segments) is needed in multiple places (normal TX data path, MPWQE in XDP), but currently we have a constant for XDP and an inline formula in normal TX. This patch introduces a common constant. Addi

[net-next 03/10] net/mlx5e: Small improvements for XDP TX MPWQE logic

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy Use MLX5E_XDP_MPW_MAX_WQEBBS to reserve space for a MPWQE, because it's actually the maximal size a MPWQE can take. Reorganize the logic that checks when to close the MPWQE session: 1. Put all checks into a single function. 2. When inline is on, make only one compariso

[net-next 05/10] net/mlx5e: Move the TLS resync check out of the function

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy Before this patch, mlx5e_ktls_tx_handle_resync_dump_comp checked for resync_dump_frag_page. It happened for all WQEs without an SKB, including padding WQEs, and required a function call. Normally, padding WQEs happen more often than TLS resyncs. Take this check out of the

[net-next 07/10] net/mlx5e: Generalize TX MPWQE checks for full session

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy As preparation for the upcoming TX MPWQE for SKBs, create a function (mlx5e_tx_mpwqe_is_full) to check whether an MPWQE session is full. This function will be shared by MPWQE code for XDP and for SKBs. Defines are renamed and moved to make them not XDP-specific. Signed-o

[net-next 10/10] net/mlx5e: Enhanced TX MPWQE for SKBs

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy This commit adds support for Enhanced TX MPWQE feature in the regular (SKB) data path. A MPWQE (multi-packet work queue element) can serve multiple packets, reducing the PCI bandwidth on control traffic. Two new stats (tx*_mpwqe_blks and tx*_mpwqe_pkts) are added. The fe

[net-next 08/10] net/mlx5e: Rename xmit-related structs to generalize them

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy As preparation for the upcoming TX MPWQE support for SKBs, rename struct mlx5e_xdp_mpwqe to mlx5e_tx_mpwqe and move it above struct mlx5e_txqsq. This structure will be reused in the regular SQ and in the regular TX data path. Also rename mlx5e_xdp_xmit_data to mlx5e_xmit_

[net-next 09/10] net/mlx5e: Move TX code into functions to be used by MPWQE

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy mlx5e_txwqe_complete performs some actions that can be taken to separate functions: 1. Update the flags needed for hardware timestamping. 2. Stop the TX queue if it's full. Take these actions into separate functions to be reused by the MPWQE code in the following commi

[pull request][net-next 00/10] mlx5 Multi packet tx descriptors for SKBs

2020-09-03 Thread Saeed Mahameed
Hi Dave & Jakub This series adds support for Multi packet tx descriptors for SKBs. For more information please see tag log below. One note that is worth mentioning here, is that Maxim had to do some manual function inlining in the tx c file to avoid performance drop due to refactoring and functio

[net-next 02/10] net/mlx5e: Refactor xmit functions

2020-09-03 Thread Saeed Mahameed
From: Maxim Mikityanskiy A huge function mlx5e_sq_xmit was split into several to achieve multiple goals: 1. Reuse the code in IPoIB. 2. Better intergrate with TLS, IPSEC, GENEVE and checksum offloads. Now it's possible to reserve space in the WQ before running eseg-based offloads, so: 2.1. It'

Re: [PATCH] net: fec: Fix PHY init after phy_reset_after_clk_enable()

2020-09-03 Thread Andrew Lunn
On Thu, Sep 03, 2020 at 10:27:12PM +0200, Marek Vasut wrote: > The phy_reset_after_clk_enable() does a PHY reset, which means the PHY > loses its register settings. The fec_enet_mii_probe() starts the PHY > and does the necessary calls to configure the PHY via PHY framework, > and loads the correct

  1   2   3   >