Re: [PATCH net v4 1/2] net: sched: fix packet stuck problem for lockless qdisc

2021-04-20 Thread Michal Kubecek
On Tue, Apr 20, 2021 at 01:55:03AM +0200, Michal Kubecek wrote: > On Mon, Apr 19, 2021 at 05:29:46PM +0200, Michal Kubecek wrote: > > > > As pointed out in the discussion on v3, this patch may result in > > significantly higher CPU consumption with multiple threads competi

Re: [PATCH net v4 1/2] net: sched: fix packet stuck problem for lockless qdisc

2021-04-19 Thread Michal Kubecek
On Mon, Apr 19, 2021 at 05:29:46PM +0200, Michal Kubecek wrote: > > As pointed out in the discussion on v3, this patch may result in > significantly higher CPU consumption with multiple threads competing on > a saturated outgoing device. I missed this submission so that I haven't >

Re: [PATCH net v4 1/2] net: sched: fix packet stuck problem for lockless qdisc

2021-04-19 Thread Michal Kubecek
On Fri, Apr 16, 2021 at 09:16:48AM +0800, Yunsheng Lin wrote: > Lockless qdisc has below concurrent problem: > cpu0 cpu1 > . . > q->enqueue . > . . > qdisc_run_begin() . > . . >

Re: [Linuxarm] Re: [PATCH net v3] net: sched: fix packet stuck problem for lockless qdisc

2021-04-19 Thread Michal Kubecek
On Mon, Apr 19, 2021 at 08:21:38PM +0800, Yunsheng Lin wrote: > On 2021/4/19 10:04, Yunsheng Lin wrote: > > On 2021/4/19 6:59, Michal Kubecek wrote: > >> I tried this patch o top of 5.12-rc7 with real devices. I used two > >> machines with 10Gb/s Intel ixgbe NICs, sender

Re: [PATCH net v3] net: sched: fix packet stuck problem for lockless qdisc

2021-04-19 Thread Michal Kubecek
On Mon, Apr 19, 2021 at 10:04:27AM +0800, Yunsheng Lin wrote: > > > > I tried this patch o top of 5.12-rc7 with real devices. I used two > > machines with 10Gb/s Intel ixgbe NICs, sender has 16 CPUs (2 8-core CPUs > > with HT disabled) and 16 Rx/Tx queues, receiver has 48 CPUs (2 12-core > > CPUs

Re: [PATCH net v3] net: sched: fix packet stuck problem for lockless qdisc

2021-04-18 Thread Michal Kubecek
On Thu, Mar 25, 2021 at 11:13:11AM +0800, Yunsheng Lin wrote: > Lockless qdisc has below concurrent problem: > cpu0 cpu1 > . . > q->enqueue . > . . > qdisc_run_begin() . > . . >

Re: [PATCH 00/13] [RFC] Rust support

2021-04-16 Thread Michal Kubecek
On Thu, Apr 15, 2021 at 08:58:16PM +0200, Peter Zijlstra wrote: > > This; can we mercilessly break the .rs bits when refactoring? What > happens the moment we cannot boot x86_64 without Rust crap on? > > We can ignore this as a future problem, but I think it's only fair to > discuss now. I

Re: [PATCH net v1 1/1] ethtool: fix incorrect datatype in set_eee ops

2021-04-06 Thread Michal Kubecek
nabled, .tx_lpi_timer value is interpreted as a number, not a logical value (those two are also __u32). But I don't think it's necessary to resubmit. Reviewed-by: Michal Kubecek > Fixes: fd77be7bd43c ("ethtool: set EEE settings with EEE_SET request") > Cc: # 5.10.x > Cc: Michal Kubec

Re: Packet gets stuck in NOLOCK pfifo_fast qdisc

2021-04-06 Thread Michal Kubecek
On Tue, Apr 06, 2021 at 10:46:29AM +0800, Yunsheng Lin wrote: > On 2021/4/6 9:49, Cong Wang wrote: > > On Sat, Apr 3, 2021 at 5:23 AM Jiri Kosina wrote: > >> > >> I am still planning to have Yunsheng Lin's (CCing) fix [1] tested in the > >> coming days. If it works, then we can consider

Re: Packet gets stuck in NOLOCK pfifo_fast qdisc

2021-04-06 Thread Michal Kubecek
On Tue, Apr 06, 2021 at 08:55:41AM +0800, Yunsheng Lin wrote: > > Hi, Jiri > Do you have a reproducer that can be shared here? > With reproducer, I can debug and test it myself too. I'm afraid we are not aware of a simple reproducer. As mentioned in the original discussion, the race window is

[PATCH] dts: drop dangling c6x symlink

2021-02-23 Thread Michal Kubecek
With c6x architecture removal, scripts/dtc/include-prefixes/c6x symlink lost its target. Drop the dangling symlink which triggers some distribution check scripts. Fixes: a579fcfa8e49 ("c6x: remove architecture") Signed-off-by: Michal Kubecek --- scripts/dtc/include-prefixes/c6x | 1

regression in iwlwifi: page fault in iwl_dbg_tlv_alloc_region() (commit ba8f6f4ae254)

2020-12-28 Thread Michal Kubecek
FYI, there is a regression in iwlwifi driver caused by commit ba8f6f4ae254 ("iwlwifi: dbg: add dumping special device memory") reported at https://bugzilla.kernel.org/show_bug.cgi?id=210733 https://bugzilla.suse.com/show_bug.cgi?id=1180344 The problem seems to be an attempt to write

[PATCH net] ethtool: fix string set id check

2020-12-14 Thread Michal Kubecek
tring sets with STRSET_GET request") Reported-by: syzbot+96523fb438937cd01...@syzkaller.appspotmail.com Signed-off-by: Michal Kubecek --- net/ethtool/strset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/ethtool/strset.c b/net/ethtool/strset.c index 0baad0ce1832..c3

[PATCH net] ethtool: fix stack overflow in ethnl_parse_bitset()

2020-12-08 Thread Michal Kubecek
not recognize), we also need to cap change_bits to nbits so that we don't try to write past the prepared bitmaps. Fixes: 88db6d1e4f62 ("ethtool: add ethnl_parse_bitset() helper") Reported-by: syzbot+9d39fa49d4df294aa...@syzkaller.appspotmail.com Signed-off-by: Michal Kubecek --- net/ethtoo

Re: [PATCH] mm/filemap: add static for function __add_to_page_cache_locked

2020-12-07 Thread Michal Kubecek
On Mon, Dec 07, 2020 at 02:44:22PM -0800, Alexei Starovoitov wrote: > On Mon, Dec 7, 2020 at 10:36 AM Justin Forbes wrote: > > > > On Mon, Dec 7, 2020 at 2:16 AM Michal Kubecek wrote: > > > > > > On Thu, Nov 12, 2020 at 08:18:57AM +0800, Alex Shi wrote: > &g

Re: [PATCH] mm/filemap: add static for function __add_to_page_cache_locked

2020-12-07 Thread Michal Kubecek
On Thu, Nov 12, 2020 at 08:18:57AM +0800, Alex Shi wrote: > > > 在 2020/11/11 上午3:50, Andrew Morton 写道: > > On Tue, 10 Nov 2020 08:39:24 +0530 Souptick Joarder > > wrote: > > > >> On Fri, Nov 6, 2020 at 4:55 PM Alex Shi wrote: > >>> > >>> Otherwise it cause gcc warning: > >>>

Re: [PATCH v2] eventfd: convert to ->write_iter()

2020-11-21 Thread Michal Kubecek
On Thu, Nov 19, 2020 at 07:46:10PM +0100, Michal Kubecek wrote: > On Thu, Nov 19, 2020 at 06:03:15PM +, Christoph Hellwig wrote: > > On Thu, Nov 19, 2020 at 07:00:19PM +0100, Michal Kubecek wrote: > > > While eventfd ->read() callback was replaced by ->read_iter()

Re: [RFC net-next 1/2] ethtool: add support for controling the type of adaptive coalescing

2020-11-20 Thread Michal Kubecek
On Fri, Nov 20, 2020 at 02:39:38PM +0100, Andrew Lunn wrote: > On Fri, Nov 20, 2020 at 08:23:22AM +0100, Michal Kubecek wrote: > > On Fri, Nov 20, 2020 at 10:59:59AM +0800, tanhuazhong wrote: > > > On 2020/11/20 6:02, Michal Kubecek wrote: > > > > > > > >

Re: [RFC net-next 1/2] ethtool: add support for controling the type of adaptive coalescing

2020-11-19 Thread Michal Kubecek
On Fri, Nov 20, 2020 at 10:59:59AM +0800, tanhuazhong wrote: > On 2020/11/20 6:02, Michal Kubecek wrote: > > > > We could use a similar approach as struct ethtool_link_ksettings, e.g. > > > > struct kernel_ethtool_coalesce { > >

Re: [RFC net-next 1/2] ethtool: add support for controling the type of adaptive coalescing

2020-11-19 Thread Michal Kubecek
On Thu, Nov 19, 2020 at 04:56:42PM +0800, tanhuazhong wrote: > On 2020/11/19 12:15, Andrew Lunn wrote: > > > diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h > > > index 9ca87bc..afd8de2 100644 > > > --- a/include/uapi/linux/ethtool.h > > > +++

Re: [RFC net-next 1/2] ethtool: add support for controling the type of adaptive coalescing

2020-11-19 Thread Michal Kubecek
On Thu, Nov 19, 2020 at 05:15:57AM +0100, Andrew Lunn wrote: > > diff --git a/include/uapi/linux/ethtool_netlink.h > > b/include/uapi/linux/ethtool_netlink.h > > index e2bf36e..e3458d9 100644 > > --- a/include/uapi/linux/ethtool_netlink.h > > +++ b/include/uapi/linux/ethtool_netlink.h > > @@

Re: [PATCH v2] eventfd: convert to ->write_iter()

2020-11-19 Thread Michal Kubecek
On Thu, Nov 19, 2020 at 06:03:15PM +, Christoph Hellwig wrote: > On Thu, Nov 19, 2020 at 07:00:19PM +0100, Michal Kubecek wrote: > > While eventfd ->read() callback was replaced by ->read_iter() recently by > > commit 12aceb89b0bc ("eventfd: convert to f_

[PATCH v2] eventfd: convert to ->write_iter()

2020-11-19 Thread Michal Kubecek
ng writes from e.g. io_uring. Also reorganize the code and return value handling in a similar way as it was done in eventfd_read(). v2: different reasoning in commit message (no code change) Signed-off-by: Michal Kubecek --- fs/eventfd.c | 43 +-- 1 file c

Re: [PATCH] eventfd: convert to ->write_iter()

2020-11-18 Thread Michal Kubecek
On Wed, Nov 18, 2020 at 04:25:37PM -0700, Jens Axboe wrote: > On 11/18/20 4:18 PM, Michal Kubecek wrote: > > On Wed, Nov 18, 2020 at 02:27:08PM -0700, Jens Axboe wrote: > >> On 11/18/20 12:59 PM, Michal Kubecek wrote: > >>> On Wed, Nov 18, 2020 at 03:18:06PM

Re: [PATCH] eventfd: convert to ->write_iter()

2020-11-18 Thread Michal Kubecek
On Wed, Nov 18, 2020 at 02:27:08PM -0700, Jens Axboe wrote: > On 11/18/20 12:59 PM, Michal Kubecek wrote: > > On Wed, Nov 18, 2020 at 03:18:06PM +, Christoph Hellwig wrote: > >> On Wed, Nov 18, 2020 at 10:19:17AM +0100, Michal Kubecek wrote: > >>> While eventfd

Re: [PATCH] eventfd: convert to ->write_iter()

2020-11-18 Thread Michal Kubecek
On Wed, Nov 18, 2020 at 03:18:06PM +, Christoph Hellwig wrote: > On Wed, Nov 18, 2020 at 10:19:17AM +0100, Michal Kubecek wrote: > > While eventfd ->read() callback was replaced by ->read_iter() recently, > > it still provides ->write() for writes. Since commit 4d03

[PATCH] eventfd: convert to ->write_iter()

2020-11-18 Thread Michal Kubecek
refore convert eventfd_write() to ->write_iter() semantics. This patch also cleans up the code in a similar way as commit 12aceb89b0bc ("eventfd: convert to f_op->read_iter()") did in read_iter(). Signed-off-by: Michal Kubecek --- fs/eventfd.c | 43 +

Re: [PATCH v2 net] ethtool: netlink: add missing netdev_features_change() call

2020-11-09 Thread Michal Kubecek
ev features with FEATURES_SET request") > Signed-off-by: Alexander Lobakin Reviewed-by: Michal Kubecek > --- > net/ethtool/features.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/net/ethtool/features.c b/net/ethtool/features.c > index 8ee4cdb

Re: [PATCH 1/1] s390: correct __bootdata / __bootdata_preserved macros

2020-10-26 Thread Michal Kubecek
> Fixes: 33def8498fdd ("treewide: Convert macro and uses of __section(foo) to > __section("foo")") > Signed-off-by: Vasily Gorbik Tested-by: Michal Kubecek Thank you, Michal > --- > arch/s390/include/asm/sections.h | 4 ++-- > 1 file changed, 2 inser

[Regression] s390x build broken with 5.10-rc1 (bisected)

2020-10-26 Thread Michal Kubecek
Hello, 5.10-rc1 builds on s390x fail with make -f ./scripts/Makefile.build obj=arch/s390/boot arch/s390/boot/bzImage make -f ./scripts/Makefile.modpost make -f ./scripts/Makefile.modfinal make -f ./scripts/Makefile.build obj=arch/s390/boot/compressed arch/s390/boot/compressed/vmlinux

build failure (BTFIDS) with CONFIG_NET && !CONFIG_INET

2020-09-29 Thread Michal Kubecek
Hello, our builds of s390x for zfcpdump fail since 5.9-rc1 with BTFIDS vmlinux FAILED unresolved symbol tcp_timewait_sock make[1]: *** [/home/abuild/rpmbuild/BUILD/kernel-zfcpdump-5.9.rc7/linux-5.9-rc7/Makefile:1176: vmlinux] Error 255 I believe this is caused by commit fce557bcef11

Re: [PATCH net-next 2/5] bonding: rename slave to link where possible

2020-09-22 Thread Michal Kubecek
On Tue, Sep 22, 2020 at 09:37:28AM -0400, Jarod Wilson wrote: > Getting rid of as much usage of "slave" as we can here, without breaking > any user-facing API. > > Cc: Jay Vosburgh > Cc: Veaceslav Falico > Cc: Andy Gospodarek > Cc: "David S. Miller" > Cc: Jakub Kicinski > Cc: Thomas Davis >

Re: [PATCH net] ethtool: add and use message type for tunnel info reply

2020-09-17 Thread Michal Kubecek
On Thu, Sep 17, 2020 at 03:41:51AM +0200, Andrew Lunn wrote: > On Thu, Sep 17, 2020 at 01:04:10AM +0200, Michal Kubecek wrote: > > Tunnel offload info code uses ETHTOOL_MSG_TUNNEL_INFO_GET message type (cmd > > field in genetlink header) for replies to tunnel info netli

[PATCH net] ethtool: add and use message type for tunnel info reply

2020-09-16 Thread Michal Kubecek
breaking backward compatibility. Fixes: c7d759eb7b12 ("ethtool: add tunnel info interface") Signed-off-by: Michal Kubecek --- Documentation/networking/ethtool-netlink.rst | 3 +++ include/uapi/linux/ethtool_netlink.h | 1 + net/ethtool/tunnels.c| 4 ++-

Re: [PATCH v3] net: Use standardized (IANA) local port range

2020-08-29 Thread Michal Kubecek
On Fri, Aug 28, 2020 at 10:44:47PM +0200, Bart Groeneveld wrote: > This change will effectively halve the available ephemeral ports, > increasing the risk of port exhaustion. But: > ... > b) It is only an issue with more than 11848 *outgoing* connections. > I think that is a niche case (I

Re: [PATCH 5/7 net-next] vxlan: add VXLAN_NL2FLAG macro

2020-08-27 Thread Michal Kubecek
On Thu, Aug 27, 2020 at 08:50:19AM +0200, Fabian Frederick wrote: > Replace common flag assignment with a macro. > This could yet be simplified with changelink/supported but it would > remove clarity > > Signed-off-by: Fabian Frederick > --- [...] > diff --git a/include/net/vxlan.h

Re: [PATCH net] bonding: show saner speed for broadcast mode

2020-08-13 Thread Michal Kubecek
On Wed, Aug 12, 2020 at 10:29:56PM -0700, Jay Vosburgh wrote: > Did you notice this by inspection, or did it come up in use > somewhere? I can't recall ever hearing of anyone using broadcast mode, > so I'm curious if there is a use for it, but this change seems > reasonable enough

Re: [PATCH] [net/ethtool] ethnl_set_linkmodes: remove redundant null check

2020-07-31 Thread Michal Kubecek
t;). For the change itself: Reviewed-by: Michal Kubecek Michal > --- > net/ethtool/linkmodes.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/net/ethtool/linkmodes.c b/net/ethtool/linkmodes.c > index fd4f3e58c6f6..b595d87fa880 100644 > --

Re: [PATCH v7 net-next] net: hyperv: dump TX indirection table to ethtool regs

2020-07-23 Thread Michal Kubecek
On Thu, Jul 23, 2020 at 07:55:20PM +, Haiyang Zhang wrote: > > -Original Message- > > From: Michal Kubecek > > Sent: Thursday, July 23, 2020 3:36 PM > > To: Chi Song > > Cc: KY Srinivasan ; Haiyang Zhang > > ; Stephen Hemminger ; > > Wei

Re: [PATCH v7 net-next] net: hyperv: dump TX indirection table to ethtool regs

2020-07-23 Thread Michal Kubecek
On Wed, Jul 22, 2020 at 11:59:09PM -0700, Chi Song wrote: > An imbalanced TX indirection table causes netvsc to have low > performance. This table is created and managed during runtime. To help > better diagnose performance issues caused by imbalanced tables, it needs > make TX indirection tables

[PATCH net] ethtool: fix genlmsg_put() failure handling in ethnl_default_dumpit()

2020-07-09 Thread Michal Kubecek
ion will be in ethnl_default_dump_one() and only iteration logic will be left in ethnl_default_dumpit(). Fixes: 728480f12442 ("ethtool: default handlers for GET requests") Reported-by: Jakub Kicinski Signed-off-by: Michal Kubecek --- net/ethtool/netlink.c | 27 +-- 1 file changed, 13 inse

Re: [PATCH net-next v2 3/3] net: ethtool: Remove PHYLIB direct dependency

2020-07-07 Thread Michal Kubecek
On Mon, Jul 06, 2020 at 09:56:03PM +0200, Andrew Lunn wrote: > On Mon, Jul 06, 2020 at 11:40:00AM -0700, Jakub Kicinski wrote: > > On Sun, 5 Jul 2020 21:27:58 -0700 Florian Fainelli wrote: > > > + ops = ethtool_phy_ops; > > > + if (!ops || !ops->start_cable_test) { > > > > nit: don't think

Re: [PATCH entry v2 3/6] x86/entry/xen: Route #DB correctly on Xen PV

2020-07-06 Thread Michal Kubecek
On Mon, Jul 06, 2020 at 10:57:07AM +0200, Jürgen Groß wrote: > On 06.07.20 10:41, Michal Kubecek wrote: > > this patch - now in mainline as commit 13cbc0cd4a30 ("x86/entry/32: Fix > > #MC and #DB wiring on x86_32") - seems to break i586 builds with > > C

Re: [PATCH entry v2 3/6] x86/entry/xen: Route #DB correctly on Xen PV

2020-07-06 Thread Michal Kubecek
eference to `xenpv_exc_nmi' [ 1279s] ld: arch/x86/entry/entry_32.o: in function `asm_xenpv_exc_debug': [ 1279s] /home/abuild/rpmbuild/BUILD/kernel-pae-5.8.rc4/linux-5.8-rc4/linux-obj/../arch/x86/include/asm/idtentry.h:567: undefined reference to `xenpv_exc_debug' Michal Kubecek

Re: weird loadavg on idle machine post 5.7

2020-07-02 Thread Michal Kubecek
On Thu, Jul 02, 2020 at 10:36:27PM +0100, Mel Gorman wrote: > > It builds, not booted, it's for discussion but maybe Dave is feeling brave! > > diff --git a/kernel/sched/core.c b/kernel/sched/core.c > index ca5db40392d4..52c73598b18a 100644 > --- a/kernel/sched/core.c > +++ b/kernel/sched/core.c

Re: [PATCH net-next 0/4] net: ethtool: Untangle PHYLIB dependency

2020-07-02 Thread Michal Kubecek
On Wed, Jul 01, 2020 at 09:29:38PM -0700, Florian Fainelli wrote: > Hi all, > > This patch series untangles the ethtool netlink dependency with PHYLIB > which exists because the cable test feature calls directly into PHY > library functions. The approach taken here is to utilize a new set of >

Re: [PATCH] bpfilter: allow to build bpfilter_umh as a module without static library

2020-07-01 Thread Michal Kubecek
ricted > to 'm' or 'n'. > > In theory, CONFIG_CC_CAN_LINK is not required for CONFIG_BPFILTER_UMH=y, > but I did not come up with a good way to describe it. > > Fixes: 8a2cc0505cc4 ("bpfilter: use 'userprogs' syntax to build bpfilter_umh") > Reported-by: Michal K

Re: [PATCH 04/16] net: bpfilter: use 'userprogs' syntax to build bpfilter_umh

2020-06-30 Thread Michal Kubecek
On Tue, Jun 30, 2020 at 03:30:04PM +0900, Masahiro Yamada wrote: > On Mon, Jun 8, 2020 at 8:56 PM Michal Kubecek wrote: > > > > I just noticed that this patch (now in mainline as commit 8a2cc0505cc4) > > drops the test if CONFIG_BPFILTER_UMH is "y" so that -static

Re: [PATCH net 3/3] net: ethtool: sync netdev_features_strings order with enum netdev_features

2020-06-22 Thread Michal Kubecek
g to bit's position in enum > netdev_features, as this simplifies both reading and modification of the > source code and can help not to miss or forget anything. > > Signed-off-by: Alexander Lobakin Reviewed-by: Michal Kubecek This would also rather belong to net-next, IMHO. Mic

Re: [PATCH net 2/3] net: ethtool: fix indentation of netdev_features_strings

2020-06-22 Thread Michal Kubecek
; used style in Linux code. > > Signed-off-by: Alexander Lobakin Reviewed-by: Michal Kubecek But this is a pure cleanup so it should rather go to net-next. Michal > --- > net/ethtool/common.c | 120 +-- > 1 file changed, 60 insertions(+), 60 d

Re: [PATCH net 1/3] net: ethtool: add missing string for NETIF_F_GSO_TUNNEL_REMCSUM

2020-06-22 Thread Michal Kubecek
> Give it a name so it will be exposed to userspace and become available > for manual configuration. > > Fixes: e585f2363637 ("udp: Changes to udp_offload to support remote > checksum offload") > Signed-off-by: Alexander Lobakin Reviewed-by: Michal Kubecek > --- > net/

Re: [PATCH resend net] net: ethtool: add missing NETIF_F_GSO_FRAGLIST feature string

2020-06-17 Thread Michal Kubecek
On Wed, Jun 17, 2020 at 09:38:47PM +, Alexander Lobakin wrote: > Hi Michal, > > On Thursday, 18 June 2020, 0:18, Michal Kubecek wrote: > > > On Wed, Jun 17, 2020 at 08:42:47PM +, Alexander Lobakin wrote: > > > > > Commit 3b33583265ed ("net: Add f

Re: [PATCH resend net] net: ethtool: add missing NETIF_F_GSO_FRAGLIST feature string

2020-06-17 Thread Michal Kubecek
"tx-sctp-segmentation", > [NETIF_F_GSO_ESP_BIT] = "tx-esp-segmentation", > [NETIF_F_GSO_UDP_L4_BIT] = "tx-udp-segmentation", > + [NETIF_F_GSO_FRAGLIST_BIT] = "tx-gso-list", > > [NETIF_F_FCOE_CRC_BIT] =

Re: [PATCH v4 0/3] Add support for SQI and master-slave

2020-06-12 Thread Michal Kubecek
On Wed, Jun 10, 2020 at 10:37:41AM +0200, Oleksij Rempel wrote: > This patch set is extending ethtool to make it more usable on automotive > PHYs like NXP TJA11XX. > > They make use of new KAPI (currently in net-next, will go probably to the > kernel 5.8-rc1): > - PHY master-slave role

Re: [PATCH v4 0/3] Add support for SQI and master-slave

2020-06-10 Thread Michal Kubecek
On Wed, Jun 10, 2020 at 10:37:41AM +0200, Oleksij Rempel wrote: > This patch set is extending ethtool to make it more usable on automotive > PHYs like NXP TJA11XX. > > They make use of new KAPI (currently in net-next, will go probably to the > kernel 5.8-rc1): > - PHY master-slave role

Re: [PATCH ethtool v1] netlink: add master/slave configuration support

2020-06-09 Thread Michal Kubecek
On Tue, Jun 09, 2020 at 01:29:42PM -0700, Kees Cook wrote: > On Tue, Jun 09, 2020 at 01:05:17PM -0700, David Miller wrote: > > From: Kees Cook > > Date: Tue, 9 Jun 2020 12:49:48 -0700 > > > > > Okay, for now, how about: > > > > > > - If we're dealing with an existing spec, match the language. >

Re: [PATCH ethtool v1] netlink: add master/slave configuration support

2020-06-09 Thread Michal Kubecek
On Tue, Jun 09, 2020 at 10:19:35AM -0700, Stephen Hemminger wrote: > On Sun, 07 Jun 2020 16:45:32 -0700 (PDT) > David Miller wrote: > > > From: Stephen Hemminger > > Date: Sun, 7 Jun 2020 15:30:19 -0700 > > > > > Open source projects have been working hard to remove the terms master > > > and

Re: [PATCH v3 1/3] update UAPI header copies

2020-06-09 Thread Michal Kubecek
On Tue, Jun 09, 2020 at 10:47:16AM +0200, Oleksij Rempel wrote: > Update to net-dev: > dc0f3ed1973 ("net: phy: at803x: add cable diagnostics support for ATH9331 and > ATH8032") > > Signed-off-by: Oleksij Rempel > --- Please rebase this commit (and the whole series - but the other two patches

Re: [PATCH v3 2/3] netlink: add master/slave configuration support

2020-06-09 Thread Michal Kubecek
ferred-slave Prefer SLAVE role on autonegotiation > +forced-masterForce the PHY in MASTER role. Can be used without > autonegotiation > +forced-slave Force the PHY in SLAVE role. Can be used without > autonegotiation > +.TE > +.TP > .A3 mdix auto on off > Sele

Re: [PATCH 04/16] net: bpfilter: use 'userprogs' syntax to build bpfilter_umh

2020-06-08 Thread Michal Kubecek
not mentioned in the commit message and the comment still says "*builtin* bpfilter_umh should be linked with -static" so this change doesn't seem to be intentional. Did I miss something? Michal Kubecek

Re: [PATCH v2 2/3] netlink: add master/slave configuration support

2020-06-07 Thread Michal Kubecek
On Thu, May 28, 2020 at 01:54:13PM +0200, Oleksij Rempel wrote: > This UAPI is needed for BroadR-Reach 100BASE-T1 devices. Due to lack of > auto-negotiation support, we needed to be able to configure the > MASTER-SLAVE role of the port manually or from an application in user > space. > > The same

Re: [PATCH v2 3/3] netlink: add LINKSTATE SQI support

2020-06-07 Thread Michal Kubecek
: Florian Fainelli Reviewed-by: Michal Kubecek > --- > netlink/desc-ethtool.c | 2 ++ > netlink/settings.c | 16 > 2 files changed, 18 insertions(+) > > diff --git a/netlink/desc-ethtool.c b/netlink/desc-ethtool.c > index b0a793c..8f4c36b 100644 > --

Re: [PATCH net-next v4] hinic: add set_channels ethtool_ops support

2020-05-31 Thread Michal Kubecek
On Mon, Jun 01, 2020 at 09:42:06AM +, Luo bin wrote: > add support to change TX/RX queue number with ethtool -L ethx combined > > Signed-off-by: Luo bin > --- [...] The patch looks correct but I'm not sure how is this change > diff --git a/drivers/net/ethernet/huawei/hinic/hinic_tx.c >

Re: [PATCH v2 net-next 2/4] vmxnet3: add support to get/set rx flow hash

2020-05-28 Thread Michal Kubecek
On Thu, May 28, 2020 at 07:29:34PM +, Ronak Doshi wrote: > > On 5/28/20, 12:21 PM, "Michal Kubecek" wrote: > > >On Thu, May 28, 2020 at 11:36:13AM -0700, Ronak Doshi wrote: > >> With vmxnet3 version 4, the emulation supports multiqueue(RSS) for >

Re: [PATCH v2 net-next 2/4] vmxnet3: add support to get/set rx flow hash

2020-05-28 Thread Michal Kubecek
On Thu, May 28, 2020 at 11:36:13AM -0700, Ronak Doshi wrote: > With vmxnet3 version 4, the emulation supports multiqueue(RSS) for > UDP and ESP traffic. A guest can enable/disable RSS for UDP/ESP over > IPv4/IPv6 by issuing commands introduced in this patch. ESP ipv6 is > not yet supported in this

Re: [PATCH net-next 2/4] vmxnet3: add support to get/set rx flow hash

2020-05-27 Thread Michal Kubecek
On Wed, May 27, 2020 at 07:07:04PM -0700, Ronak Doshi wrote: > With vmxnet3 version 4, the emulation supports multiqueue(RSS) for > UDP and ESP traffic. A guest can enable/disable RSS for UDP/ESP over > IPv4/IPv6 by issuing commands introduced in this patch. ESP ipv6 is > not yet supported in this

Re: [PATCH ethtool v1] netlink: add master/slave configuration support

2020-05-26 Thread Michal Kubecek
On Tue, May 26, 2020 at 11:10:25AM +0200, Oleksij Rempel wrote: > This UAPI is needed for BroadR-Reach 100BASE-T1 devices. Due to lack of > auto-negotiation support, we needed to be able to configure the > MASTER-SLAVE role of the port manually or from an application in user > space. > > The same

Re: MRP netlink interface

2020-05-25 Thread Michal Kubecek
On Mon, May 25, 2020 at 01:14:35PM +, Horatiu Vultur wrote: > The 05/25/2020 13:26, Nikolay Aleksandrov wrote: > > EXTERNAL EMAIL: Do not click links or open attachments unless you know the > > content is safe > > > > On 25/05/2020 13:03, Michal Kubecek wrote:

Re: MRP netlink interface

2020-05-25 Thread Michal Kubecek
On Mon, May 25, 2020 at 11:28:27AM +, Horatiu Vultur wrote: [...] > My first approach was to extend the 'struct br_mrp_instance' with a field that > contains the priority of the node. But this breaks the backwards > compatibility, > and then every time when I need to change something, I will

Re: [PATCH 2/2] e1000e: Make WOL info in ethtool consistent with device wake up ability

2020-05-24 Thread Michal Kubecek
On Sat, May 23, 2020 at 05:09:50PM +0800, Chen Yu wrote: > Hi Michal, > Thanks for reviewing, > and sorry for late reply. > On Thu, May 21, 2020 at 09:23:42PM +0200, Michal Kubecek wrote: > > On Fri, May 22, 2020 at 01:59:13AM +0800, Chen Yu wrote: > > > Currently the

Re: [PATCH 2/2] e1000e: Make WOL info in ethtool consistent with device wake up ability

2020-05-21 Thread Michal Kubecek
On Fri, May 22, 2020 at 01:59:13AM +0800, Chen Yu wrote: > Currently the ethtool shows that WOL(Wake On Lan) is enabled > even if the device wakeup ability has been disabled via sysfs: > cat /sys/devices/pci:00/:00:1f.6/power/wakeup >disabled > > ethtool eno1 > ... > Wake-on:

Re: [PATCH net-next v3 1/2] ethtool: provide UAPI for PHY Signal Quality Index (SQI)

2020-05-20 Thread Michal Kubecek
On Wed, May 20, 2020 at 05:07:11PM +0200, Oleksij Rempel wrote: > On Wed, May 20, 2020 at 04:45:44PM +0200, Michal Kubecek wrote: > > On Wed, May 20, 2020 at 08:29:14AM +0200, Oleksij Rempel wrote: > > > Signal Quality Index is a mandatory value required by "

Re: [PATCH net-next v3 1/2] ethtool: provide UAPI for PHY Signal Quality Index (SQI)

2020-05-20 Thread Michal Kubecek
y instance of the structure, not only those implementing them), doing two calls, running the same checks twice, locking twice, checking the result twice. Also, passing a structure pointer would mean less code changed if we decide to add more related state values later. What do you think? If you do

Re: [PATCH net-next v1 1/2] ethtool: provide UAPI for PHY Signal Quality Index (SQI)

2020-05-19 Thread Michal Kubecek
On Tue, May 19, 2020 at 12:58:55PM +0200, Oleksij Rempel wrote: > On Tue, May 19, 2020 at 10:55:20AM +0200, Michal Kubecek wrote: > > I'm also a bit worried about hardcoding the 0-7 value range. While I > > understand that it's defined by standard for 100base-T1, we my want

Re: [PATCH net-next v1 1/2] ethtool: provide UAPI for PHY Signal Quality Index (SQI)

2020-05-19 Thread Michal Kubecek
On Tue, May 19, 2020 at 09:51:59AM +0200, Oleksij Rempel wrote: > Signal Quality Index is a mandatory value required by "OPEN Alliance > SIG" for the 100Base-T1 PHYs [1]. This indicator can be used for cable > integrity diagnostic and investigating other noise sources and > implement by at least

Re: [PATCH net-next] hinic: add set_channels ethtool_ops support

2020-05-15 Thread Michal Kubecek
On Fri, May 15, 2020 at 08:13:30PM +0200, Michal Kubecek wrote: [...] > > +int hinic_set_channels(struct net_device *netdev, > > + struct ethtool_channels *channels) > > +{ > > + struct hinic_dev *nic_dev = netdev_priv(netdev); > > +

Re: [PATCH net-next] hinic: add set_channels ethtool_ops support

2020-05-15 Thread Michal Kubecek
On Fri, May 15, 2020 at 12:35:47AM +, Luo bin wrote: > add support to change TX/RX queue number with ethtool -L > > Signed-off-by: Luo bin > --- > .../net/ethernet/huawei/hinic/hinic_ethtool.c | 67 +-- > .../net/ethernet/huawei/hinic/hinic_hw_dev.c | 7 ++ >

Re: [PATCH net-next 1/4] net: ethernet: validate pause autoneg setting

2020-05-13 Thread Michal Kubecek
On Wed, May 13, 2020 at 03:49:25PM +0200, Andrew Lunn wrote: > > So, I think consistency of implementation is more important than fixing > > this; the current behaviour has been established for many years now. > > With netlink ethtool we have the possibility of adding a new API to > control this.

Re: [PATCH net-next 1/4] net: ethernet: validate pause autoneg setting

2020-05-12 Thread Michal Kubecek
On Tue, May 12, 2020 at 11:31:39AM -0700, Doug Berger wrote: > On 5/11/2020 5:47 PM, Andrew Lunn wrote: > > On Mon, May 11, 2020 at 05:24:07PM -0700, Doug Berger wrote: > >> A comment in uapi/linux/ethtool.h states "Drivers should reject a > >> non-zero setting of @autoneg when autoneogotiation is

Re: signal quality and cable diagnostic

2020-05-11 Thread Michal Kubecek
On Mon, May 11, 2020 at 04:13:10PM +0200, Oleksij Rempel wrote: > > I continue to work on TJA11xx PHY and need to export some additional > cable diagnostic/link stability information: Signal Quality Index (SQI). > The PHY data sheet describes it as following [1]: >

Re: [PATCH net-next v6 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-05 Thread Michal Kubecek
On Tue, May 05, 2020 at 08:35:05AM +0200, Oleksij Rempel wrote: > This UAPI is needed for BroadR-Reach 100BASE-T1 devices. Due to lack of > auto-negotiation support, we needed to be able to configure the > MASTER-SLAVE role of the port manually or from an application in user > space. > > The same

Re: [PATCH v5 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-04 Thread Michal Kubecek
On Mon, May 04, 2020 at 10:55:56AM +0200, Oleksij Rempel wrote: > On Mon, May 04, 2020 at 10:37:34AM +0200, Michal Kubecek wrote: > > On Mon, May 04, 2020 at 10:04:17AM +0200, Oleksij Rempel wrote: > > > @Michal, > > > > > > i noticed that linkmodes_fi

Re: [PATCH v5 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-04 Thread Michal Kubecek
On Mon, May 04, 2020 at 12:10:29PM +0200, Oleksij Rempel wrote: > > > diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c > > > index ac2784192472f..42dda9d2082ee 100644 > > > --- a/drivers/net/phy/phy_device.c > > > +++ b/drivers/net/phy/phy_device.c > > > @@ -1768,6 +1768,90

Re: [PATCH v5 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-04 Thread Michal Kubecek
On Mon, May 04, 2020 at 09:12:13AM +0200, Oleksij Rempel wrote: > This UAPI is needed for BroadR-Reach 100BASE-T1 devices. Due to lack of > auto-negotiation support, we needed to be able to configure the > MASTER-SLAVE role of the port manually or from an application in user > space. > > The same

Re: [PATCH v5 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-04 Thread Michal Kubecek
On Mon, May 04, 2020 at 10:04:17AM +0200, Oleksij Rempel wrote: > @Michal, > > i noticed that linkmodes_fill_reply() some times get not enough > tailroom. > if data->peer_empty == 0 > linkmodes_reply_size() size: 476 > linkmodes_fill_reply() skb tailroom: 724 > > > if data->peer_empty == 1 >

Re: [PATCH net-next v4 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-01 Thread Michal Kubecek
On Fri, May 01, 2020 at 05:52:10PM +0200, Michal Kubecek wrote: > On Fri, May 01, 2020 at 09:46:32AM +0200, Oleksij Rempel wrote: > [...] > > static int ethnl_update_linkmodes(struct genl_info *info, struct nlattr > > **tb, > > struc

Re: [PATCH net-next v4 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-01 Thread Michal Kubecek
On Fri, May 01, 2020 at 09:46:32AM +0200, Oleksij Rempel wrote: > This UAPI is needed for BroadR-Reach 100BASE-T1 devices. Due to lack of > auto-negotiation support, we needed to be able to configure the > MASTER-SLAVE role of the port manually or from an application in user > space. > > The same

Re: [PATCH net-next v3 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-04-30 Thread Michal Kubecek
On Thu, Apr 30, 2020 at 02:09:45PM +0200, Oleksij Rempel wrote: > > > > > @@ -119,7 +123,12 @@ static int linkmodes_fill_reply(struct sk_buff > > > > > *skb, > > > > > } > > > > > > > > > > if (nla_put_u32(skb, ETHTOOL_A_LINKMODES_SPEED, > > > > > lsettings->speed) || > > > > > -

Re: [PATCH net-next v3 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-04-30 Thread Michal Kubecek
On Thu, Apr 30, 2020 at 07:00:58AM +0200, Oleksij Rempel wrote: > > > diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h > > > index 92f737f101178..eb680e3d6bda5 100644 > > > --- a/include/uapi/linux/ethtool.h > > > +++ b/include/uapi/linux/ethtool.h > > > @@ -1666,6 +1666,31

Re: [PATCH net-next v3 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-04-29 Thread Michal Kubecek
On Tue, Apr 28, 2020 at 09:53:07AM +0200, Oleksij Rempel wrote: > This UAPI is needed for BroadR-Reach 100BASE-T1 devices. Due to lack of > auto-negotiation support, we needed to be able to configure the > MASTER-SLAVE role of the port manually or from an application in user > space. > > The same

Re: [PATCH net-next v7 06/17] ethtool: netlink bitset handling

2019-10-21 Thread Michal Kubecek
On Mon, Oct 14, 2019 at 03:02:05PM +0200, Jiri Pirko wrote: > Mon, Oct 14, 2019 at 01:18:47PM CEST, mkube...@suse.cz wrote: > >On Fri, Oct 11, 2019 at 03:34:29PM +0200, Jiri Pirko wrote: > >> Wed, Oct 09, 2019 at 10:59:18PM CEST, mkube...@suse.cz wrote: > >> >+Bit sets > >> >+ > >> >+ > >>

Re: [PATCH net-next v7 06/17] ethtool: netlink bitset handling

2019-10-14 Thread Michal Kubecek
On Fri, Oct 11, 2019 at 03:34:29PM +0200, Jiri Pirko wrote: > Wed, Oct 09, 2019 at 10:59:18PM CEST, mkube...@suse.cz wrote: > >+Bit sets > >+ > >+ > >+For short bitmaps of (reasonably) fixed length, standard ``NLA_BITFIELD32`` > >+type is used. For arbitrary length bitmaps, ethtool netlink

Re: [PATCH net-next v7 14/17] ethtool: set link settings with LINKINFO_SET request

2019-10-14 Thread Michal Kubecek
On Sat, Oct 12, 2019 at 06:33:09PM +0200, Jiri Pirko wrote: > Wed, Oct 09, 2019 at 10:59:43PM CEST, mkube...@suse.cz wrote: > > [...] > > >+static const struct nla_policy linkinfo_hdr_policy[ETHTOOL_A_HEADER_MAX + > >1] = { > >+[ETHTOOL_A_HEADER_UNSPEC] = { .type = NLA_REJECT

[PATCH net-next v3] genetlink: do not parse attributes for families with zero maxattr

2019-10-11 Thread Michal Kubecek
have to handle it in each caller. v3: put the check inside genl_family_rcv_msg_attrs_parse() v2: adjust also argument of genl_family_rcv_msg_attrs_free() Fixes: c10e6cf85e7d ("net: genetlink: push attrbuf allocation and parsing to a separate function") Signed-off-by: Michal Kubece

Re: [PATCH net-next v7 13/17] ethtool: add standard notification handler

2019-10-10 Thread Michal Kubecek
On Friday, 11 October 2019 7:56 Jiri Pirko wrote: > Thu, Oct 10, 2019 at 08:17:43PM CEST, mkube...@suse.cz wrote: > >On Thu, Oct 10, 2019 at 05:25:59PM +0200, Jiri Pirko wrote: > >> Wed, Oct 09, 2019 at 10:59:40PM CEST, mkube...@suse.cz wrote: > [...] > > >> >+ > >> >+/* generic notification

Re: [PATCH net-next v2] genetlink: do not parse attributes for families with zero maxattr

2019-10-10 Thread Michal Kubecek
On Thu, Oct 10, 2019 at 10:21:02AM -0700, Jakub Kicinski wrote: > On Thu, 10 Oct 2019 12:34:02 +0200 (CEST), Michal Kubecek wrote: > > Commit c10e6cf85e7d ("net: genetlink: push attrbuf allocation and parsing > > to a separate function") moved attribute buffer allocation

Re: [PATCH net-next v7 12/17] ethtool: provide link settings with LINKINFO_GET request

2019-10-10 Thread Michal Kubecek
On Thu, Oct 10, 2019 at 05:59:55PM +0200, Jiri Pirko wrote: > Wed, Oct 09, 2019 at 10:59:37PM CEST, mkube...@suse.cz wrote: > > [...] > > >+/* prepare_data() handler */ > > Not sure how valuable are comments like this... I'll drop them. > >+static int linkinfo_prepare(const struct

Re: [PATCH net-next v7 09/17] ethtool: generic handlers for GET requests

2019-10-10 Thread Michal Kubecek
On Thu, Oct 10, 2019 at 08:18:05PM +0200, Johannes Berg wrote: > On Thu, 2019-10-10 at 20:04 +0200, Michal Kubecek wrote: > > > > The only thing I don't like about the genetlink infrastructure is the > > design decision that policy and corresponding maxattr is an attrib

Re: [PATCH net-next v7 14/17] ethtool: set link settings with LINKINFO_SET request

2019-10-10 Thread Michal Kubecek
On Thu, Oct 10, 2019 at 05:37:54PM +0200, Jiri Pirko wrote: > Wed, Oct 09, 2019 at 10:59:43PM CEST, mkube...@suse.cz wrote: > >Implement LINKINFO_SET netlink request to set link settings queried by > >LINKINFO_GET message. > > > >Only physical port, phy MDIO address and MDI(-X) control can be set,

Re: [PATCH net-next v7 13/17] ethtool: add standard notification handler

2019-10-10 Thread Michal Kubecek
On Thu, Oct 10, 2019 at 05:25:59PM +0200, Jiri Pirko wrote: > Wed, Oct 09, 2019 at 10:59:40PM CEST, mkube...@suse.cz wrote: > >+static void *ethnl_bcastmsg_put(struct sk_buff *skb, u8 cmd) > >+{ > >+return genlmsg_put(skb, 0, ++ethnl_bcast_seq, _genl_family, 0, > >+ cmd);

  1   2   3   4   5   6   >