Re: [PATCH V6 00/20] net: ks8851: Unify KS8851 SPI and MLL drivers

2020-05-17 Thread Lukas Wunner
On Sat, May 16, 2020 at 07:02:25PM -0700, David Miller wrote: > > The KS8851SNL/SNLI and KS8851-16MLL/MLLI/MLLU are very much the same pieces > > of silicon, except the former has an SPI interface, while the later has a > > parallel bus interface. Thus far, Linux has two separate drivers for each >

RE: [Ocfs2-devel] [PATCH 27/33] sctp: export sctp_setsockopt_bindx

2020-05-17 Thread David Laight
From: Matthew Wilcox > Sent: 16 May 2020 16:37 ... > > Basically: > > > > This patch sequence (to be written) does the following: > > > > Patch 1: Change __sys_setsockopt() to allocate a kernel buffer, > > copy the data into it then call set_fs(KERNEL_DS). > > An on-stack buffer (

[RFC PATCH] drivers: net: mdio_bus: try indirect clause 45 regs access

2020-05-17 Thread Baruch Siach
When the MDIO bus does not support directly clause 45 access, fallback to indirect registers access method to read/write clause 45 registers using clause 22 registers. Signed-off-by: Baruch Siach --- Is that the right course? Currently, this does not really work on the my target machine, which

Re: [RFC PATCH] drivers: net: mdio_bus: try indirect clause 45 regs access

2020-05-17 Thread Russell King - ARM Linux admin
On Sun, May 17, 2020 at 01:20:56PM +0300, Baruch Siach wrote: > When the MDIO bus does not support directly clause 45 access, fallback > to indirect registers access method to read/write clause 45 registers > using clause 22 registers. > > Signed-off-by: Baruch Siach > --- > > Is that the right

Re: [next-queue RFC 0/4] ethtool: Add support for frame preemption

2020-05-17 Thread Vladimir Oltean
On Sun, 17 May 2020 at 01:19, David Miller wrote: > > From: Vladimir Oltean > Date: Sun, 17 May 2020 00:03:39 +0300 > > > As to why this doesn't go to tc but to ethtool: why would it go to tc? > > Maybe you can't %100 duplicate the on-the-wire special format and > whatever, but the queueing behav

[PATCH net] net: phy: propagate an error back to the callers of phy_sfp_probe

2020-05-17 Thread Leon Romanovsky
From: Leon Romanovsky The compilation warning below reveals that the errors returned from the sfp_bus_add_upstream() call are not propagated to the callers. Fix it by returning "ret". 14:37:51 drivers/net/phy/phy_device.c: In function 'phy_sfp_probe': 14:37:51 drivers/net/phy/phy_device.c:1236:6

Re: [PATCH V6 00/20] net: ks8851: Unify KS8851 SPI and MLL drivers

2020-05-17 Thread Marek Vasut
On 5/17/20 9:13 AM, Lukas Wunner wrote: > On Sat, May 16, 2020 at 07:02:25PM -0700, David Miller wrote: >>> The KS8851SNL/SNLI and KS8851-16MLL/MLLI/MLLU are very much the same pieces >>> of silicon, except the former has an SPI interface, while the later has a >>> parallel bus interface. Thus far,

[PATCH net 1/1] net sched: fix reporting the first-time use timestamp

2020-05-17 Thread Roman Mashak
When a new action is installed, firstuse field of 'tcf_t' is explicitly set to 0. Value of zero means "new action, not yet used"; as a packet hits the action, 'firstuse' is stamped with the current jiffies value. tcf_tm_dump() should return 0 for firstuse if action has not yet been hit. Fixes: 48

Re: [Patch net-next v2 1/2] net: partially revert dynamic lockdep key changes

2020-05-17 Thread Taehee Yoo
On Sun, 17 May 2020 at 01:53, Vladimir Oltean wrote: > Hi Vladimir, > Hi Taehee, > > On Sat, 16 May 2020 at 18:22, Taehee Yoo wrote: > > > > On Thu, 14 May 2020 at 00:56, Vladimir Oltean wrote: > > > > > > Hi Cong, Taehee, > > > > > > > Hi Vladimir! > > Sorry for the late reply. > > > > ... >

[PATCH iproute2-next 1/1] tc: report time an action was first used

2020-05-17 Thread Roman Mashak
Have print_tm() dump firstuse value along with install, lastuse and expires. Signed-off-by: Roman Mashak --- tc/tc_util.c | 5 + 1 file changed, 5 insertions(+) diff --git a/tc/tc_util.c b/tc/tc_util.c index 12f865cc71bf..f6aa2ed552a9 100644 --- a/tc/tc_util.c +++ b/tc/tc_util.c @@ -760,6 +

Re: [RFC PATCH] drivers: net: mdio_bus: try indirect clause 45 regs access

2020-05-17 Thread Baruch Siach
Hi Russell, On Sun, May 17 2020, Russell King - ARM Linux admin wrote: > On Sun, May 17, 2020 at 01:20:56PM +0300, Baruch Siach wrote: >> When the MDIO bus does not support directly clause 45 access, fallback >> to indirect registers access method to read/write clause 45 registers >> using clause

Re: [next-queue RFC 0/4] ethtool: Add support for frame preemption

2020-05-17 Thread Michael Walle
Am Fri, 15 May 2020 18:29:44 -0700 schrieb Vinicius Costa Gomes : > Hi, > > This series adds support for configuring frame preemption, as defined > by IEEE 802.1Q-2018 (previously IEEE 802.1Qbu) and IEEE 802.3br. > > Frame preemption allows a packet from a higher priority queue marked > as "expr

KASAN: slab-out-of-bounds Read in ath9k_hif_usb_rx_cb

2020-05-17 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:806d8acc USB: dummy-hcd: use configurable endpoint naming .. git tree: https://github.com/google/kasan.git usb-fuzzer console output: https://syzkaller.appspot.com/x/log.txt?x=1147bce610 kernel config: https://syzkaller.appspo

[PATCH net] net/tls(TLS_SW): Fix integrity issue with non-blocking sw KTLS request

2020-05-17 Thread Pooja Trivedi
In pure sw ktls(AES-NI), -EAGAIN from tcp layer (do_tcp_sendpages for encrypted record) gets treated as error, subtracts the offset, and returns to application. Because of this, application sends data from subtracted offset, which leads to data integrity issue. Since record is already encrypted, kt

[PATCH net] mlx4: Fix information leak on failure to read module EEPROM

2020-05-17 Thread Ben Hutchings
mlx4_en_get_module_eeprom() returns 0 even if it fails. This results in copying an uninitialised (or partly initialised) buffer back to user-space. Change it so that: * In the special case that the DOM turns out not to be readable, the remaining part of the buffer is cleared. This should avoi

[PATCH net] nexthop: Fix attribute checking for groups

2020-05-17 Thread David Ahern
From: David Ahern For nexthop groups, attributes after NHA_GROUP_TYPE are invalid, but nh_check_attr_group starts checking at NHA_GROUP. The group type defaults to multipath and the NHA_GROUP_TYPE is currently optional so this has slipped through so far. Fix the attribute checking to handle suppo

Re: [PATCH] netfilter/ipvs: expire no destination UDP connections when expire_nodest_conn=1

2020-05-17 Thread Andrew Kim
Hi Julian, Thanks for getting back to me, that makes sense. Would you be opposed to trying to expire all UDP connections matching a deleted destination only if expire_nodest_conn=1? Even today with `expire_nodest_conn=1`, many packets could be dropped if there are many requests from a single clie

[PATCH] netfilter/ipvs: immediately expire UDP connections matching unavailable destination if expire_nodest_conn=1

2020-05-17 Thread Andrew Sy Kim
If expire_nodest_conn=1 and a UDP destination is deleted, IPVS should also expire all matching connections immiediately instead of waiting for the next matching packet. This is particulary useful when there are a lot of packets coming from a few number of clients. Those clients are likely to match

Re: [PATCH] netfilter/ipvs: expire no destination UDP connections when expire_nodest_conn=1

2020-05-17 Thread Andrew Kim
I sent a new patch diff based on my ask above. Please take a look :) Thanks, Andrew Sy Kim On Sun, May 17, 2020 at 1:27 PM Andrew Kim wrote: > > Hi Julian, > > Thanks for getting back to me, that makes sense. > > Would you be opposed to trying to expire all UDP connections matching > a deleted

Re: [PATCH net] nexthop: Fix attribute checking for groups

2020-05-17 Thread David Miller
From: David Ahern Date: Sun, 17 May 2020 11:26:32 -0600 > From: David Ahern > > For nexthop groups, attributes after NHA_GROUP_TYPE are invalid, but > nh_check_attr_group starts checking at NHA_GROUP. The group type defaults > to multipath and the NHA_GROUP_TYPE is currently optional so this ha

Re: [RFC PATCH] drivers: net: mdio_bus: try indirect clause 45 regs access

2020-05-17 Thread Andrew Lunn
> > I don't think this should be done at mdiobus level; I think this is a > > layering violation. It needs to happen at the PHY level because the > > indirect C45 access via C22 registers is specific to PHYs. > > > > It also needs to check in the general case that the PHY does indeed > > support t

[PATCH net-next] selftests: Drop 'pref medium' in route checks

2020-05-17 Thread David Ahern
From: David Ahern The 'pref medium' attribute was moved in iproute2 to be near the prefix which is where it applies versus after the last nexthop. The nexthop tests were updated to drop the string from route checking, but it crept in again with the compat tests. Fixes: 4dddb5be136a ("selftests:

Re: [RFC PATCH] drivers: net: mdio_bus: try indirect clause 45 regs access

2020-05-17 Thread Baruch Siach
Hi Andrew, On Sun, May 17 2020, Andrew Lunn wrote: >> > I don't think this should be done at mdiobus level; I think this is a >> > layering violation. It needs to happen at the PHY level because the >> > indirect C45 access via C22 registers is specific to PHYs. >> > >> > It also needs to check i

Re: [PATCH] lan743x: Added fixed link support

2020-05-17 Thread Andrew Lunn
> @@ -946,6 +949,9 @@ static void lan743x_phy_link_status_change(struct > net_device *netdev) > { > struct lan743x_adapter *adapter = netdev_priv(netdev); > struct phy_device *phydev = netdev->phydev; > + struct device_node *phynode; > + phy_interface_t phyifc = PHY_INTERFACE_

Re: [Patch net-next v2 1/2] net: partially revert dynamic lockdep key changes

2020-05-17 Thread Cong Wang
On Sat, May 16, 2020 at 9:53 AM Vladimir Oltean wrote: > Thanks a lot for presenting the options. In general, xmit in DSA is > relatively simple and most of the time stateless. My stacked DSA setup > appears to work just fine with NETIF_F_LLTX, including the updating of > percpu counters. I'm not

Re: [next-queue RFC 0/4] ethtool: Add support for frame preemption

2020-05-17 Thread Andrew Lunn
On Sun, May 17, 2020 at 01:51:19PM +0300, Vladimir Oltean wrote: > On Sun, 17 May 2020 at 01:19, David Miller wrote: > > > > From: Vladimir Oltean > > Date: Sun, 17 May 2020 00:03:39 +0300 > > > > > As to why this doesn't go to tc but to ethtool: why would it go to tc? > > > > Maybe you can't %10

Re: [PATCH net 1/1] net sched: fix reporting the first-time use timestamp

2020-05-17 Thread Cong Wang
On Sun, May 17, 2020 at 5:47 AM Roman Mashak wrote: > > When a new action is installed, firstuse field of 'tcf_t' is explicitly set > to 0. Value of zero means "new action, not yet used"; as a packet hits the > action, 'firstuse' is stamped with the current jiffies value. > > tcf_tm_dump() should

Re: [next-queue RFC 0/4] ethtool: Add support for frame preemption

2020-05-17 Thread Vladimir Oltean
Hi Andrew, On Sun, 17 May 2020 at 21:45, Andrew Lunn wrote: > > On Sun, May 17, 2020 at 01:51:19PM +0300, Vladimir Oltean wrote: > > On Sun, 17 May 2020 at 01:19, David Miller wrote: > > > > > > From: Vladimir Oltean > > > Date: Sun, 17 May 2020 00:03:39 +0300 > > > > > > > As to why this doesn

Re: [PATCH net-next v2 0/4] Implement classifier-action terse dump mode

2020-05-17 Thread Cong Wang
On Fri, May 15, 2020 at 4:40 AM Vlad Buslov wrote: > > Output rate of current upstream kernel TC filter dump implementation if > relatively low (~100k rules/sec depending on configuration). This > constraint impacts performance of software switch implementation that > rely on TC for their datapath

Re: [PATCH V6 00/20] net: ks8851: Unify KS8851 SPI and MLL drivers

2020-05-17 Thread Andrew Lunn
> However in terms of performance there's a bigger problem: > > Previously ks8851.c (SPI driver) had 8-bit and 32-bit register accessors. > The present series drops them and performs a 32-bit access as two 16-bit > accesses and an 8-bit access as one 16-bit access because that's what > ks8851_mll.

Re: [PATCH V6 00/20] net: ks8851: Unify KS8851 SPI and MLL drivers

2020-05-17 Thread Andrew Lunn
> So I was already led into reworking the entire series to do this > inlining once, after V1. It then turned out it's a horrible mess to get > everything to compile as modules and built-in and then also only the > parallel/SPI as a module and then the other way around. Maybe consider some trade of

Re: [PATCH net-next] selftests: Drop 'pref medium' in route checks

2020-05-17 Thread David Miller
From: David Ahern Date: Sun, 17 May 2020 12:00:33 -0600 > From: David Ahern > > The 'pref medium' attribute was moved in iproute2 to be near the prefix > which is where it applies versus after the last nexthop. The nexthop > tests were updated to drop the string from route checking, but it crep

Re: [PATCH V6 00/20] net: ks8851: Unify KS8851 SPI and MLL drivers

2020-05-17 Thread David Miller
From: Andrew Lunn Date: Sun, 17 May 2020 21:16:35 +0200 >> Nevertheless I was going to repeat the performance measurements on a >> recent kernel but haven't gotten around to that yet because the >> measurements need to be performed with CONFIG_PREEMPT_RT_FULL to >> be reliable (a vanilla kernel i

Re: [PATCH net-next] net: dsa: sja1105: disable rxvlan offload for the DSA master

2020-05-17 Thread David Miller
I've asked Eric to look at this twice and no response, so I'm marking this deferred because I'm not applying this without someone knowledgable about the quoted VLAN change can take a look at this.

Re: [PATCH] dt-bindings: net: dsa: b53: Add missing size and address cells to example

2020-05-17 Thread David Miller
From: Kurt Kanzenbach Date: Wed, 13 May 2020 16:02:49 +0200 > Add the missing size and address cells to the b53 example. Otherwise, it may > not > compile or issue warnings if directly copied into a device tree. > > Signed-off-by: Kurt Kanzenbach Applied.

Re: [PATCH v2] net: revert "net: get rid of an signed integer overflow in ip_idents_reserve()"

2020-05-17 Thread David Miller
From: Shaokun Zhang Date: Sat, 16 May 2020 11:46:49 +0800 > From: Yuqi Jin > > Commit adb03115f459 ("net: get rid of an signed integer overflow in > ip_idents_reserve()") > used atomic_cmpxchg to replace "atomic_add_return" inside the function > "ip_idents_reserve". The reason was to avoid UBS

Re: iproute2: tc deletion freezes whole server

2020-05-17 Thread Cong Wang
On Fri, May 8, 2020 at 6:59 AM Václav Zindulka wrote: > > On Thu, May 7, 2020 at 8:52 PM Cong Wang wrote: > > > > On Tue, May 5, 2020 at 1:46 AM Václav Zindulka > > wrote: > > > > > > On Mon, May 4, 2020 at 7:46 PM Cong Wang wrote: > > > > > > > > Sorry for the delay. I lost connection to my de

Re: [Patch net-next v2 1/2] net: partially revert dynamic lockdep key changes

2020-05-17 Thread Florian Fainelli
On 5/17/2020 11:42 AM, Cong Wang wrote: On Sat, May 16, 2020 at 9:53 AM Vladimir Oltean wrote: Thanks a lot for presenting the options. In general, xmit in DSA is relatively simple and most of the time stateless. My stacked DSA setup appears to work just fine with NETIF_F_LLTX, including the

Re: [PATCH net-next 0/7] mptcp: do not block on subflow socket

2020-05-17 Thread David Miller
From: Florian Westphal Date: Sat, 16 May 2020 10:46:16 +0200 > This series reworks mptcp_sendmsg logic to avoid blocking on the subflow > socket. > > It does so by removing the wait loop from mptcp_sendmsg_frag helper. > > In order to do that, it moves prerequisites that are currently > handled

Re: [PATCH] rds: convert get_user_pages() --> pin_user_pages()

2020-05-17 Thread David Miller
From: John Hubbard Date: Sat, 16 May 2020 18:23:36 -0700 > This code was using get_user_pages_fast(), in a "Case 2" scenario > (DMA/RDMA), using the categorization from [1]. That means that it's > time to convert the get_user_pages_fast() + put_page() calls to > pin_user_pages_fast() + unpin_user

Re: [PATCH net] net: phy: propagate an error back to the callers of phy_sfp_probe

2020-05-17 Thread David Miller
From: Leon Romanovsky Date: Sun, 17 May 2020 14:53:40 +0300 > From: Leon Romanovsky > > The compilation warning below reveals that the errors returned from > the sfp_bus_add_upstream() call are not propagated to the callers. > Fix it by returning "ret". > > 14:37:51 drivers/net/phy/phy_device.

Re: [PATCH V6 09/20] net: ks8851: Use 16-bit read of RXFC register

2020-05-17 Thread Andrew Lunn
On Sun, May 17, 2020 at 02:33:43AM +0200, Marek Vasut wrote: > The RXFC register is the only one being read using 8-bit accessors. > To make it easier to support the 16-bit accesses used by the parallel > bus variant of KS8851, use 16-bit accessor to read RXFC register as > well as neighboring RXFC

[PATCH v2 bpf-next 4/7] libbpf: add BPF ring buffer support

2020-05-17 Thread Andrii Nakryiko
Declaring and instantiating BPF ring buffer doesn't require any changes to libbpf, as it's just another type of maps. So using existing BTF-defined maps syntax with __uint(type, BPF_MAP_TYPE_RINGBUF) and __uint(max_elements, ) is all that's necessary to create and use BPF ring buffer. This patch a

[PATCH v2 bpf-next 2/7] tools/memory-model: add BPF ringbuf MPSC litmus tests

2020-05-17 Thread Andrii Nakryiko
Add 4 litmus tests for BPF ringbuf implementation, divided into two different use cases. First, two unbounded case, one with 1 producer and another with 2 producers, single consumer. All reservations are supposed to succeed. Second, bounded case with only 1 record allowed in ring buffer at any gi

[PATCH v2 bpf-next 0/7] BPF ring buffer

2020-05-17 Thread Andrii Nakryiko
Implement a new BPF ring buffer, as presented at BPF virtual conference ([0]). It presents an alternative to perf buffer, following its semantics closely, but allowing sharing same instance of ring buffer across multiple CPUs efficiently. Most patches have extensive commentary explaining various a

[PATCH v2 bpf-next 3/7] bpf: track reference type in verifier

2020-05-17 Thread Andrii Nakryiko
This patch extends verifier's reference tracking logic with tracking a reference type and ensuring acquire()/release() functions accept only the right types of references. Currently, ambiguity between socket and ringbuf record references is resolved through use of different types of input arguments

[PATCH v2 bpf-next 5/7] selftests/bpf: add BPF ringbuf selftests

2020-05-17 Thread Andrii Nakryiko
Both singleton BPF ringbuf and BPF ringbuf with map-in-map use cases are tested. Also reserve+submit/discards and output variants of API are validated. Signed-off-by: Andrii Nakryiko --- .../selftests/bpf/prog_tests/ringbuf.c| 211 ++ .../selftests/bpf/prog_tests/ringbuf_

[PATCH v2 bpf-next 7/7] docs/bpf: add BPF ring buffer design notes

2020-05-17 Thread Andrii Nakryiko
Add commit description from patch #1 as a stand-alone documentation under Documentation/bpf, as it might be more convenient format, in long term perspective. Suggested-by: Stanislav Fomichev Signed-off-by: Andrii Nakryiko --- Documentation/bpf/ringbuf.txt | 191 +

[PATCH v2 bpf-next 1/7] bpf: implement BPF ring buffer and verifier support for it

2020-05-17 Thread Andrii Nakryiko
This commits adds a new MPSC ring buffer implementation into BPF ecosystem, which allows multiple CPUs to submit data to a single shared ring buffer. On the consumption side, only single consumer is assumed. Motivation -- There are two distinctive motivators for this work, which are not sa

[PATCH v2 bpf-next 6/7] bpf: add BPF ringbuf and perf buffer benchmarks

2020-05-17 Thread Andrii Nakryiko
Extend bench framework with ability to have benchmark-provided child argument parser for custom benchmark-specific parameters. This makes bench generic code modular and independent from any specific benchmark. Also implement a set of benchmarks for new BPF ring buffer and existing perf buffer. 4 b

[PATCH net-next 7/7] net: phy: marvell: Configure TDR pulse based on measurement length

2020-05-17 Thread Andrew Lunn
When performing a TDR measurement for a short distance, the pulse width should be low, to help differentiate between the outgoing pulse and any reflection. For longer distances, the pulse should be wider, to help with attenuation. Signed-off-by: Andrew Lunn --- drivers/net/phy/marvell.c | 25 +++

[PATCH net-next 5/7] net: ethtool: Allow PHY cable test TDR data to configured

2020-05-17 Thread Andrew Lunn
Allow the user to configure where on the cable the TDR data should be retrieved, in terms of first and last sample, and the step between samples. Also add the ability to ask for TDR data for just one pair. If this configuration is not provided, it defaults to 0-150m at 1m intervals for all pairs.

[PATCH net-next 0/7] Raw PHY TDR data

2020-05-17 Thread Andrew Lunn
Some ethernet PHYs allow access to raw TDR data in addition to summary diagnostics information. Add support for retrieving this data via netlink ethtool. The basic structure in the core is the same as for normal phy diagnostics, the PHY driver simply uses different helpers to fill the netlink messa

[PATCH net-next 6/7] net : phy: marvell: Speedup TDR data retrieval by only changing page once

2020-05-17 Thread Andrew Lunn
Getting the TDR data requires a large number of MDIO bus transactions. The number can however be reduced if the page is only changed once. Add the needed locking to allow this, and make use of unlocked read/write methods where needed. Signed-off-by: Andrew Lunn --- drivers/net/phy/marvell.c | 31

[PATCH net-next 2/7] net: ethtool: Add generic parts of cable test TDR

2020-05-17 Thread Andrew Lunn
Add the generic parts of the code used to trigger a cable test and return raw TDR data. Any PHY driver which support this must implement the new driver op. Signed-off-by: Andrew Lunn --- drivers/net/phy/phy.c | 65 - include/linux/ethtool_netlink.h | 4

[PATCH net-next 4/7] net: phy: marvell: Add support for amplitude graph

2020-05-17 Thread Andrew Lunn
The Marvell PHYs can measure the amplitude of the returned signal for a given distance. Implement this option of the cable test infrastructure. Signed-off-by: Andrew Lunn --- drivers/net/phy/marvell.c | 227 +- 1 file changed, 226 insertions(+), 1 deletion(-)

[PATCH net-next 1/7] net: ethtool: Add attributes for cable test TDR data

2020-05-17 Thread Andrew Lunn
Some Ethernet PHYs can return the raw time domain reflectromatry data. Add the attributes to allow this data to be requested and returned via netlink ethtool. Signed-off-by: Andrew Lunn --- Documentation/networking/ethtool-netlink.rst | 79 include/uapi/linux/ethtool_netlink

[PATCH net-next 3/7] net: ethtool: Add helpers for cable test TDR data

2020-05-17 Thread Andrew Lunn
Add helpers for returning raw TDR helpers in netlink messages. Signed-off-by: Andrew Lunn --- include/linux/ethtool_netlink.h | 21 + net/ethtool/cabletest.c | 79 - 2 files changed, 99 insertions(+), 1 deletion(-) diff --git a/include/linux/ethto

Re: [PATCH V6 00/20] net: ks8851: Unify KS8851 SPI and MLL drivers

2020-05-17 Thread Marek Vasut
On 5/17/20 9:26 PM, Andrew Lunn wrote: >> So I was already led into reworking the entire series to do this >> inlining once, after V1. It then turned out it's a horrible mess to get >> everything to compile as modules and built-in and then also only the >> parallel/SPI as a module and then the othe

Re: [PATCH V6 09/20] net: ks8851: Use 16-bit read of RXFC register

2020-05-17 Thread Marek Vasut
On 5/17/20 9:44 PM, Andrew Lunn wrote: > On Sun, May 17, 2020 at 02:33:43AM +0200, Marek Vasut wrote: >> The RXFC register is the only one being read using 8-bit accessors. >> To make it easier to support the 16-bit accesses used by the parallel >> bus variant of KS8851, use 16-bit accessor to read

Re: [PATCH net-next 4/7] net: phy: marvell: Add support for amplitude graph

2020-05-17 Thread Chris Healy
On Sun, May 17, 2020 at 12:59 PM Andrew Lunn wrote: > > The Marvell PHYs can measure the amplitude of the returned signal for > a given distance. Implement this option of the cable test > infrastructure. > > Signed-off-by: Andrew Lunn > --- > drivers/net/phy/marvell.c | 227 +

Re: [PATCH] lan743x: Added fixed link support

2020-05-17 Thread Roelof Berg
To Everyone: I need a test hardware recommendation for a lan7431/0 NIC in normal mode (not fixed-link mode). In prior patches this was not necessary, because I was able to ensure 100% backwards compatibility by careful coding alone. But I might soon come to a point where I need to test phy-conne

Re: [PATCH net-next 4/7] net: phy: marvell: Add support for amplitude graph

2020-05-17 Thread Andrew Lunn
> > +static int marvell_vct5_amplitude_distance(struct phy_device *phydev, > > + int meters) > > +{ > > + int mV_pair0, mV_pair1, mV_pair2, mV_pair3; > > + int distance; > > + u16 reg; > > + int err; > > + > > + distance = meter

Re: [PATCH 06/17] ARM: dts: r8a7742: Add SDHI nodes

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:46PM +0100, Lad Prabhakar wrote: > Add the SDHI devices nodes to the R8A7742 device tree. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signature

Re: [PATCH 07/17] ARM: dts: r8a7742: Add MMC0 node

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:47PM +0100, Lad Prabhakar wrote: > Describe MMC0 device node in the R8A7742 device tree. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signature

Re: [PATCH 08/17] dt-bindings: ata: renesas,rcar-sata: Add r8a7742 support

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:48PM +0100, Lad Prabhakar wrote: > Document SATA support for the RZ/G1H, which is compatible with > R-Car Gen2 SoC family. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signat

Re: [PATCH 09/17] ARM: dts: r8a7742: Add sata nodes

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:49PM +0100, Lad Prabhakar wrote: > Add the sata devices nodes to the R8A7742 device tree. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signature

Re: [PATCH 10/17] dt-bindings: net: renesas,ravb: Add support for r8a7742 SoC

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:50PM +0100, Lad Prabhakar wrote: > Document RZ/G1H (R8A7742) SoC bindings. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signature

Re: [PATCH 11/17] dt-bindings: net: renesas,ether: Document R8A7742 SoC

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:51PM +0100, Lad Prabhakar wrote: > Document RZ/G1H (R8A7742) SoC bindings. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signature

Re: [PATCH 12/17] ARM: dts: r8a7742: Add Ethernet AVB support

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:52PM +0100, Lad Prabhakar wrote: > Add Ethernet AVB support for R8A7742 SoC. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signature

Re: [PATCH 13/17] ARM: dts: r8a7742: Add Ether support

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:53PM +0100, Lad Prabhakar wrote: > Define the generic R8A7742 part of the Ether device node. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signature

Re: [PATCH 14/17] dt-bindings: power: renesas,apmu: Document r8a7742 support

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:54PM +0100, Lad Prabhakar wrote: > Document APMU and SMP enable method for RZ/G1H (also known as r8a7742) > SoC. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc Description: PGP signature

Re: [PATCH 15/17] ARM: dts: r8a7742: Add APMU nodes

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:55PM +0100, Lad Prabhakar wrote: > Add DT nodes for the Advanced Power Management Units (APMU), and use the > enable-method to point out that the APMU should be used for SMP support. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewe

Re: BUG: unable to handle kernel paging request in fl_dump_key

2020-05-17 Thread Cong Wang
On Fri, May 15, 2020 at 6:53 AM syzbot wrote: > > Hello, > > syzbot found the following crash on: > > HEAD commit:99addbe3 net: broadcom: Select BROADCOM_PHY for BCMGENET > git tree: net > console output: https://syzkaller.appspot.com/x/log.txt?x=173e568c10 > kernel config: https://

Re: [PATCH 16/17] dt-bindings: watchdog: renesas,wdt: Document r8a7742 support

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:56PM +0100, Lad Prabhakar wrote: > RZ/G1H (R8A7742) watchdog implementation is compatible with R-Car Gen2, > therefore add relevant documentation. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Wolfram Sang signature.asc

Re: [PATCH 17/17] ARM: dts: r8a7742: Add RWDT node

2020-05-17 Thread Wolfram Sang
On Fri, May 15, 2020 at 04:08:57PM +0100, Lad Prabhakar wrote: > Add a device node for the Watchdog Timer (RWDT) controller on the Renesas > RZ/G1H (r8a7742) SoC. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > The DTS change looks fine, I checked it against similar S

Re: [PATCH net-next] net: dsa: sja1105: disable rxvlan offload for the DSA master

2020-05-17 Thread Florian Fainelli
On 5/12/2020 4:49 PM, Vladimir Oltean wrote: From: Vladimir Oltean On sja1105 operating in best_effort_vlan_filtering mode (when the TPID of the DSA tags is 0x8100), it can be seen that __netif_receive_skb_core calls __vlan_hwaccel_clear_tag right before passing the skb to the DSA packet_typ

Re: [PATCH] lan743x: Added fixed link support

2020-05-17 Thread Andrew Lunn
> >> + /* Configure MAC to fixed link parameters */ > >> + data = lan743x_csr_read(adapter, MAC_CR); > >> + /* Disable auto negotiation */ > >> + data &= ~(MAC_CR_ADD_ | MAC_CR_ASD_); > > > > Why does the MAC care about autoneg? I

Re: [PATCH net-next 4/7] net: phy: marvell: Add support for amplitude graph

2020-05-17 Thread Chris Healy
On Sun, May 17, 2020 at 1:51 PM Andrew Lunn wrote: > > > > +static int marvell_vct5_amplitude_distance(struct phy_device *phydev, > > > + int meters) > > > +{ > > > + int mV_pair0, mV_pair1, mV_pair2, mV_pair3; > > > + int distance; > > > +

[PATCH] net: bmac: Fix stack corruption panic in bmac_probe()

2020-05-17 Thread Finn Thain
This fixes an old bug recently revealed by CONFIG_STACKPROTECTOR. [ 25.707616] scsi host0: MESH [ 28.488852] eth0: BMAC at 00:05:02:07:5a:a6 [ 28.488859] [ 28.505397] Kernel panic - not syncing: stack-protector: Kernel stack is corrupted in: bmac_probe+0x540/0x618 [ 28.535152] CPU: 0 PI

Re: [PATCH net-next] hinic: add support to set and get pause param

2020-05-17 Thread luobin (L)
Will fix. Thanks. On 2020/5/17 4:25, David Miller wrote: From: Luo bin Date: Sat, 16 May 2020 02:00:30 + add support to set pause param with ethtool -A and get pause param with ethtool -a. Also remove set_link_ksettings ops for VF. Signed-off-by: Luo bin Why are you using a semaphore a

Re: [PATCH] net: bmac: Fix stack corruption panic in bmac_probe()

2020-05-17 Thread Jeremy Kerr
Hi Finn, > This fixes an old bug recently revealed by CONFIG_STACKPROTECTOR. Good catch. I'm not sure about the fix though. That variable ('addr') should be a ethernet hardware address; I'm surprised we're accessing past the 6th byte. The culprit seems to be this, where 'ea' is the address buffer

Re: [PATCH net 1/1] net sched: fix reporting the first-time use timestamp

2020-05-17 Thread Roman Mashak
Cong Wang writes: > On Sun, May 17, 2020 at 5:47 AM Roman Mashak wrote: >> >> When a new action is installed, firstuse field of 'tcf_t' is explicitly set >> to 0. Value of zero means "new action, not yet used"; as a packet hits the >> action, 'firstuse' is stamped with the current jiffies value.

Re: [PATCH net-next] net: phy: realtek: add loopback support for RTL8211F

2020-05-17 Thread tanhuazhong
On 2020/5/13 21:12, Andrew Lunn wrote: On Wed, May 13, 2020 at 04:25:44PM +0800, Huazhong Tan wrote: From: Yufeng Mo PHY loopback is already supported by genphy driver. This patch adds the set_loopback interface to RTL8211F PHY driver, so the PHY selftest can run properly on it. Signed-off

linux-next: manual merge of the jc_docs tree with the vfs and net-next trees

2020-05-17 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the jc_docs tree got a conflict in: kernel/sysctl.c between commit: f461d2dcd511 ("sysctl: avoid forward declarations") from the vfs tree and commit: 2f4c33063ad7 ("docs: sysctl/kernel: document ngroups_max") from the jc_docs tree. I fixed it up (se

UBSAN: array-index-out-of-bounds in kernel/bpf/arraymap.c:177

2020-05-17 Thread Qian Cai
With Clang 9.0.1, return array->value + array->elem_size * (index & array->index_mask); but array->value is, char value[0] __aligned(8); [ 506.031548][ T4134] LTP: starting bpf_prog02 [ 506.125326][ T4352] [ 506

Re: [PATCH] vhost: missing __user tags

2020-05-17 Thread Jason Wang
On 2020/5/15 下午11:33, Michael S. Tsirkin wrote: sparse warns about converting void * to void __user *. This is not new but only got noticed now that vhost is built on more systems. This is just a question of __user tags missing in a couple of places, so fix it up. Fixes: f88949138058 ("vhost:

Re: [PATCH v5 bpf-next 00/11] net: Add support for XDP in egress path

2020-05-17 Thread David Ahern
I am trying to understand the resistance here. There are ingress/egress hooks for most of the layers - tc, netfilter, and even within bpf APIs. Clearly there is a need for this kind of symmetry across the APIs, so why the resistance or hesitation for XDP? Stacking programs on the Rx side into the

Re: [PATCH net-next 4/7] net: phy: marvell: Add support for amplitude graph

2020-05-17 Thread Michal Kubecek
On Sun, May 17, 2020 at 10:51:50PM +0200, Andrew Lunn wrote: > > > +static int marvell_vct5_amplitude_distance(struct phy_device *phydev, > > > + int meters) > > > +{ > > > + int mV_pair0, mV_pair1, mV_pair2, mV_pair3; > > > + int distance; > > >

Re: [PATCH] staging: qlge: unmap dma when lock failed

2020-05-17 Thread Benjamin Poirier
On 2020-05-17 13:46 +0800, Xiangyang Zhang wrote: > DMA not unmapped when lock failed, this patch fixed it. > Fixes: 4322c5bee85e ("qlge: Expand coverage of hw lock for config register.") > Signed-off-by: Xiangyang Zhang > --- > drivers/staging/qlge/qlge_main.c | 3 ++- > 1 file changed, 2 ins

Re: [PATCH bpf-next v2 0/5] samples: bpf: refactor kprobe tracing progs with libbpf

2020-05-17 Thread Yonghong Song
On 5/15/20 9:06 PM, Daniel T. Lee wrote: Currently, the kprobe BPF program attachment method for bpf_load is pretty outdated. The implementation of bpf_load "directly" controls and manages(create, delete) the kprobe events of DEBUGFS. On the other hand, using using the libbpf automatically man

Re: [bpf-next PATCH v2 2/5] bpf: extend bpf_base_func_proto helpers with probe_* and *current_task*

2020-05-17 Thread Yonghong Song
On 5/15/20 3:06 PM, John Fastabend wrote: Often it is useful when applying policy to know something about the task. If the administrator has CAP_SYS_ADMIN rights then they can use kprobe + networking hook and link the two programs together to accomplish this. However, this is a bit clunky and

Re: [bpf-next PATCH v2 3/5] bpf: sk_msg add get socket storage helpers

2020-05-17 Thread Yonghong Song
On 5/15/20 3:06 PM, John Fastabend wrote: Add helpers to use local socket storage. Signed-off-by: John Fastabend --- include/uapi/linux/bpf.h |2 ++ net/core/filter.c| 15 +++ 2 files changed, 17 insertions(+) Maybe put tools/include/uapi/linux/bpf.h change al

[PATCH] vlan: fix the bug that cannot create vlan4095

2020-05-17 Thread Huang Qijun
According to the 8021q standard, the VLAN id range is 1 to 4095. But in the register_vlan_device function, the range is 1 to 4094, because ">= VLAN_VID_MASK" is used to determine whether the id is illegal. This will prevent the creation of the vlan4095 interface: $ vconfig add sit0 4095 vco

[PATCH ipsec] esp4: improve xfrm4_beet_gso_segment() to be more readable

2020-05-17 Thread Xin Long
This patch is to improve the code to make xfrm4_beet_gso_segment() more readable, and keep consistent with xfrm6_beet_gso_segment(). Signed-off-by: Xin Long --- net/ipv4/esp4_offload.c | 19 +++ 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/net/ipv4/esp4_offload.

move the SIOCDELRT and SIOCADDRT compat_ioctl handlers v3

2020-05-17 Thread Christoph Hellwig
Hi Dave, this series moves the compat_ioctl handlers into the protocol handlers, avoiding the need to override the address space limited as in the current handler. Changes since v3: - moar variable reordering Changes since v1: - reorder a bunch of variable declarations

[PATCH 3/4] appletalk: factor out a atrtr_ioctl_addrt helper

2020-05-17 Thread Christoph Hellwig
Add a helper than can be shared with the upcoming compat ioctl handler. Signed-off-by: Christoph Hellwig --- net/appletalk/ddp.c | 33 - 1 file changed, 20 insertions(+), 13 deletions(-) diff --git a/net/appletalk/ddp.c b/net/appletalk/ddp.c index b41375d4d295d..

[PATCH 2/4] ipv6: move SIOCADDRT and SIOCDELRT handling into ->compat_ioctl

2020-05-17 Thread Christoph Hellwig
To prepare removing the global routing_ioctl hack start lifting the code into a newly added ipv6 ->compat_ioctl handler. Signed-off-by: Christoph Hellwig --- include/net/ipv6.h | 2 ++ net/dccp/ipv6.c | 1 + net/ipv6/af_inet6.c | 53 + net/ipv6/raw.c

[PATCH 4/4] ipv4,appletalk: move SIOCADDRT and SIOCDELRT handling into ->compat_ioctl

2020-05-17 Thread Christoph Hellwig
To prepare removing the global routing_ioctl hack start lifting the code into the ipv4 and appletalk ->compat_ioctl handlers. Unlike the existing handler we don't bother copying in the name - there are no compat issues for char arrays. Signed-off-by: Christoph Hellwig --- include/net/compat.h |

[PATCH 1/4] ipv6: lift copy_from_user out of ipv6_route_ioctl

2020-05-17 Thread Christoph Hellwig
Prepare for better compat ioctl handling by moving the user copy out of ipv6_route_ioctl. Signed-off-by: Christoph Hellwig --- include/net/ip6_route.h | 3 ++- net/ipv6/af_inet6.c | 16 +-- net/ipv6/route.c| 44 +++-- 3 files changed,

  1   2   >