[PATCH] iavf: fix MAC address setting for VFs when filter is rejected

2019-09-04 Thread Stefan Assmann
Currently iavf unconditionally applies MAC address change requests. This brings the VF in a state where it is no longer able to pass traffic if the PF rejects a MAC filter change for the VF. A typical scenario for a rejected MAC filter is for an untrusted VF to request to change the MAC address whe

Re: pull request: bluetooth 2019-09-05

2019-09-04 Thread David Miller
From: Johan Hedberg Date: Thu, 5 Sep 2019 09:14:44 +0300 > Here are a few more Bluetooth fixes for 5.3. I hope they can still make > it. There's one USB ID addition for btusb, two reverts due to discovered > regressions, and two other important fixes. > > Please let me know if there any issues p

Re: [PATCH v2 2/2] net: phy: adin: implement Energy Detect Powerdown mode via phy-tunable

2019-09-04 Thread Ardelean, Alexandru
On Wed, 2019-09-04 at 22:03 +0200, Andrew Lunn wrote: > [External] > > On Wed, Sep 04, 2019 at 07:23:22PM +0300, Alexandru Ardelean wrote: > > This driver becomes the first user of the kernel's `ETHTOOL_PHY_EDPD` > > phy-tunable feature. > > EDPD is also enabled by default on PHY config_init, but

pull request: bluetooth 2019-09-05

2019-09-04 Thread Johan Hedberg
Hi Dave, Here are a few more Bluetooth fixes for 5.3. I hope they can still make it. There's one USB ID addition for btusb, two reverts due to discovered regressions, and two other important fixes. Please let me know if there any issues pulling. Thanks. Johan --- The following changes since com

Re: [PATCHv2 1/1] forcedeth: use per cpu to collect xmit/recv statistics

2019-09-04 Thread David Miller
From: Zhu Yanjun Date: Thu, 5 Sep 2019 10:48:01 +0800 > > On 2019/9/5 6:22, David Miller wrote: >> From: Zhu Yanjun >> Date: Sun, 1 Sep 2019 03:26:13 -0400 >> >>> +static inline void nv_get_stats(int cpu, struct fe_priv *np, >>> + struct rtnl_link_stats64 *storage) >>

Re: [PATCH REPOST 1/2] can: flexcan: fix deadlock when using self wakeup

2019-09-04 Thread Sean Nyekjaer
On 29/08/2019 09.30, Joakim Zhang wrote: Hi Sean, I'm sorry that I can't get the debug log as the site can't be reached. And I connect two boards to do test at my side, this issue can't be reproduced. Best Regards, Joakim Zhang Hi Joakim, What commit and branch are you doing your tests w

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

2019-09-04 Thread Stephen Rothwell
Hi all, Today's linux-next merge of the net-next tree got a conflict in: drivers/net/ethernet/nuvoton/w90p910_ether.c between commit: 00d2fbf73d55 ("net: remove w90p910-ether driver") from the arm-soc tree and commit: d1a55841ab24 ("net: Remove dev_err() usage after platform_get_irq()")

Re: [PATCHv2 net-next] ipmr: remove cache_resolve_queue_len

2019-09-04 Thread Hangbin Liu
On Wed, Sep 04, 2019 at 09:50:15AM +0200, Eric Dumazet wrote: > > +static int queue_count(struct mr_table *mrt) > > +{ > > + struct list_head *pos; > > + int count = 0; > > + > > + spin_lock_bh(&mfc_unres_lock); > > + list_for_each(pos, &mrt->mfc_unres_queue) > > + count++; > > +

Re: [PATCH v3 bpf-next 2/3] bpf: implement CAP_BPF

2019-09-04 Thread Alexei Starovoitov
On Thu, Sep 05, 2019 at 02:51:51AM +, Song Liu wrote: > > > > On Sep 4, 2019, at 6:32 PM, Alexei Starovoitov > > wrote: > > > > On Thu, Sep 05, 2019 at 12:34:36AM +, Song Liu wrote: > >> > >> > >>> On Sep 4, 2019, at 11:43 AM, Alexei Starovoitov wrote: > >>> > >>> Implement permiss

Re: [PATCH v3] tun: fix use-after-free when register netdev failed

2019-09-04 Thread Jason Wang
On 2019/9/5 上午10:03, Yang Yingliang wrote: > > > On 2019/9/3 18:50, Jason Wang wrote: >> >> - Original Message - >>> >>> On 2019/9/3 14:06, Jason Wang wrote: On 2019/9/3 下午1:42, Yang Yingliang wrote: > > On 2019/9/3 11:03, Jason Wang wrote: >> On 2019/9/3 上午9:45, Yang Ying

Re: [PATCH v3 bpf-next 2/3] bpf: implement CAP_BPF

2019-09-04 Thread Song Liu
> On Sep 4, 2019, at 6:32 PM, Alexei Starovoitov > wrote: > > On Thu, Sep 05, 2019 at 12:34:36AM +, Song Liu wrote: >> >> >>> On Sep 4, 2019, at 11:43 AM, Alexei Starovoitov wrote: >>> >>> Implement permissions as stated in uapi/linux/capability.h >>> >>> Signed-off-by: Alexei Starov

[PATCH net-next v2] r8152: adjust the settings of ups flags

2019-09-04 Thread Hayes Wang
The UPS feature only works for runtime suspend, so UPS flags only need to be set before enabling runtime suspend. Therefore, I create a struct to record relative information, and use it before runtime suspend. All chips could record such information, even though not all of them support the feature

Re: [PATCHv2 1/1] forcedeth: use per cpu to collect xmit/recv statistics

2019-09-04 Thread Zhu Yanjun
On 2019/9/5 6:22, David Miller wrote: From: Zhu Yanjun Date: Sun, 1 Sep 2019 03:26:13 -0400 +static inline void nv_get_stats(int cpu, struct fe_priv *np, + struct rtnl_link_stats64 *storage) ... +static inline void rx_missing_handler(u32 flags, struct fe_pr

Re: WARNING in hso_free_net_device

2019-09-04 Thread Hui Peng
Can you guys have  a look at the attached patch? On 9/4/19 6:41 PM, Stephen Hemminger wrote: > On Wed, 4 Sep 2019 16:27:50 -0400 > Hui Peng wrote: > >> Hi, all: >> >> I looked at the bug a little. >> >> The issue is that in the error handling code, hso_free_net_device >> unregisters >> >> the net

[PATCH] net/mlx5: Fix addr's type in mlx5dr_icm_dm

2019-09-04 Thread Nathan Chancellor
clang errors when CONFIG_PHYS_ADDR_T_64BIT is not set: drivers/net/ethernet/mellanox/mlx5/core/steering/dr_icm_pool.c:121:8: error: incompatible pointer types passing 'u64 *' (aka 'unsigned long long *') to parameter of type 'phys_addr_t *' (aka 'unsigned int *') [-Werror,-Wincompatible-pointer-ty

Re: [PATCH v3] tun: fix use-after-free when register netdev failed

2019-09-04 Thread Yang Yingliang
On 2019/9/3 18:50, Jason Wang wrote: - Original Message - On 2019/9/3 14:06, Jason Wang wrote: On 2019/9/3 下午1:42, Yang Yingliang wrote: On 2019/9/3 11:03, Jason Wang wrote: On 2019/9/3 上午9:45, Yang Yingliang wrote: On 2019/9/2 13:32, Jason Wang wrote: On 2019/8/23 下午5:36, Ya

[PATCH] net/mlx5: Fix rt's type in dr_action_create_reformat_action

2019-09-04 Thread Nathan Chancellor
clang warns: drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c:1080:9: warning: implicit conversion from enumeration type 'enum mlx5_reformat_ctx_type' to different enumeration type 'enum mlx5dr_action_type' [-Wenum-conversion] rt = MLX5_REFORMAT_TYPE_L2_TO_L2_TU

[PATCH v2 net] net: sonic: return NETDEV_TX_OK if failed to map buffer

2019-09-04 Thread Mao Wenan
NETDEV_TX_BUSY really should only be used by drivers that call netif_tx_stop_queue() at the wrong moment. If dma_map_single() is failed to map tx DMA buffer, it might trigger an infinite loop. This patch use NETDEV_TX_OK instead of NETDEV_TX_BUSY, and change printk to pr_err_ratelimited. Fixes: d9

Re: [PATCH v3 bpf-next 2/3] bpf: implement CAP_BPF

2019-09-04 Thread Alexei Starovoitov
On Thu, Sep 05, 2019 at 12:34:36AM +, Song Liu wrote: > > > > On Sep 4, 2019, at 11:43 AM, Alexei Starovoitov wrote: > > > > Implement permissions as stated in uapi/linux/capability.h > > > > Signed-off-by: Alexei Starovoitov > > > > [...] > > > @@ -1648,11 +1648,11 @@ static int bpf_p

RE: [PATCH v2 net-next] net: stmmac: Add support for MDIO interrupts

2019-09-04 Thread Voon, Weifeng
> On Wed, Sep 04, 2019 at 10:02:54PM +0800, Voon Weifeng wrote: > > From: "Chuah, Kim Tatt" > > > > DW EQoS v5.xx controllers added capability for interrupt generation > > when MDIO interface is done (GMII Busy bit is cleared). > > This patch adds support for this interrupt on supported HW to avoi

[PATCH v2 4/4] spi: spi-fsl-dspi: Always use the TCFQ devices in poll mode

2019-09-04 Thread Vladimir Oltean
With this patch, the "interrupts" property from the device tree bindings is ignored, even if present, if the driver runs in TCFQ mode. Switching to using the DSPI in poll mode has several distinct benefits: - With interrupts, the DSPI driver in TCFQ mode raises an IRQ after each transmitted wor

[PATCH v2 3/4] spi: spi-fsl-dspi: Implement the PTP system timestamping for TCFQ mode

2019-09-04 Thread Vladimir Oltean
In this mode, the DSPI controller uses PIO to transfer word by word. In comparison, in EOQ mode the 4-word deep FIFO is being used, hence the current logic will need some adaptation for which I do not have the hardware (Coldfire) to test. It is not clear what is the timing of DMA transfers and whet

[PATCH v2 2/4] spi: Add a PTP system timestamp to the transfer structure

2019-09-04 Thread Vladimir Oltean
SPI is one of the interfaces used to access devices which have a POSIX clock driver (real time clocks, 1588 timers etc). The fact that the SPI bus is slow is not what the main problem is, but rather the fact that drivers don't take a constant amount of time in transferring data over SPI. When there

[PATCH v2 1/4] spi: Use an abbreviated pointer to ctlr->cur_msg in __spi_pump_messages

2019-09-04 Thread Vladimir Oltean
This helps a bit with line fitting now (the list_first_entry call) as well as during the next patch which needs to iterate through all transfers of ctlr->cur_msg so it timestamps them. Signed-off-by: Vladimir Oltean --- Changes in v2: - Renamed mesg to msg. drivers/spi/spi.c | 23 --

[PATCH v2 0/4] Deterministic SPI latency with NXP DSPI driver

2019-09-04 Thread Vladimir Oltean
Since v1, I noticed that under CPU load, the pre-to-post delay gets reduced to half (i.e. the code runs twice as fast). After a bit of debugging, turns out this is the effect of the 'ondemand' governor. Disabling dynamic frequency scaling (either by switching to the 'performance' governor or by mak

Re: [PATCH net] net: sonic: remove dev_kfree_skb before return NETDEV_TX_BUSY

2019-09-04 Thread maowenan
On 2019/9/4 18:19, Eric Dumazet wrote: > > > On 9/4/19 11:42 AM, Mao Wenan wrote: >> When dma_map_single is failed to map buffer, skb can't be freed >> before sonic driver return to stack with NETDEV_TX_BUSY, because >> this skb may be requeued to qdisc, it might trigger use-after-free. >> >>

Re: [PATCH v3 bpf-next 2/3] bpf: implement CAP_BPF

2019-09-04 Thread Song Liu
> On Sep 4, 2019, at 11:43 AM, Alexei Starovoitov wrote: > > Implement permissions as stated in uapi/linux/capability.h > > Signed-off-by: Alexei Starovoitov > [...] > @@ -1648,11 +1648,11 @@ static int bpf_prog_load(union bpf_attr *attr, union > bpf_attr __user *uattr) > is_gpl =

Re: [PATCH][next] net/mlx5: fix spelling mistake "offlaods" -> "offloads"

2019-09-04 Thread Saeed Mahameed
On Wed, 2019-09-04 at 20:38 +0100, Colin King wrote: > From: Colin Ian King > > There is a spelling mistake in a NL_SET_ERR_MSG_MOD error message. > Fix it. > > Signed-off-by: Colin Ian King > Applied to net-next-mlx5. Thanks, Saeed.

Re: [PATCH][next] net/mlx5: fix missing assignment of variable err

2019-09-04 Thread Saeed Mahameed
On Wed, 2019-09-04 at 20:29 +0100, Colin King wrote: > From: Colin Ian King > > The error return from a call to mlx5_flow_namespace_set_peer is not > being assigned to variable err and hence the error check following > the call is currently not working. Fix this by assigning ret as > intended. >

Re: [PATCH] net/mlx5: Use PTR_ERR_OR_ZERO rather than its implementation

2019-09-04 Thread Saeed Mahameed
On Tue, 2019-09-03 at 20:08 +, Saeed Mahameed wrote: > On Tue, 2019-09-03 at 14:56 +0800, zhong jiang wrote: > > PTR_ERR_OR_ZERO contains if(IS_ERR(...)) + PTR_ERR. It is better > > to use it directly. hence just replace it. > > > > Signed-off-by: zhong jiang > > --- > > drivers/net/ethernet

Re: rtnl_lock() question

2019-09-04 Thread Saeed Mahameed
On Wed, 2019-09-04 at 09:38 -0700, Jonathan Lemon wrote: > On 4 Sep 2019, at 0:39, Eric Dumazet wrote: > > > On 9/3/19 11:55 PM, Jonathan Lemon wrote: > > > How appropriate is it to hold the rtnl_lock() across a sleepable > > > memory allocation? On one hand it's just a mutex, but it would > > >

Re: [PATCH bpf-next 0/6] selftests/bpf: move sockopt tests under test_progs

2019-09-04 Thread Alexei Starovoitov
On Wed, Sep 04, 2019 at 09:25:03AM -0700, Stanislav Fomichev wrote: > Now that test_progs is shaping into more generic test framework, > let's convert sockopt tests to it. This requires adding > a helper to create and join a cgroup first (test__join_cgroup). > Since we already hijack stdout/stderr

Re: WARNING in hso_free_net_device

2019-09-04 Thread Stephen Hemminger
On Wed, 4 Sep 2019 16:27:50 -0400 Hui Peng wrote: > Hi, all: > > I looked at the bug a little. > > The issue is that in the error handling code, hso_free_net_device > unregisters > > the net_device (hso_net->net)  by calling unregister_netdev. In the > error handling code path, > > hso_net->n

HOW IS YOUR DAY,

2019-09-04 Thread Mrs. Gaddafi
Dear Friend, I came across your e-mail contact prior a private search whilst in need of your partnership for investment assistance in your country. I am opportune to use this medium to exhibit my legal intentions towards investing to your country under your management. I am fully convinced t

Re: [PATCH net-next] r8152: modify rtl8152_set_speed function

2019-09-04 Thread David Miller
From: Hayes Wang Date: Mon, 2 Sep 2019 19:52:28 +0800 > First, for AUTONEG_DISABLE, we only need to modify MII_BMCR. > > Second, add advertising parameter for rtl8152_set_speed(). Add > RTL_ADVERTISED_xxx for advertising parameter of rtl8152_set_speed(). > Then, the advertising settings from eth

Re: [PATCH net-next v3 0/3] net: dsa: mt7530: Convert to PHYLINK and add support for port 5

2019-09-04 Thread David Miller
From: René van Dorst Date: Mon, 2 Sep 2019 15:02:23 +0200 > 1. net: dsa: mt7530: Convert to PHYLINK API >This patch converts mt7530 to PHYLINK API. > 2. dt-bindings: net: dsa: mt7530: Add support for port 5 > 3. net: dsa: mt7530: Add support for port 5 >These 2 patches adding support for

Re: [PATCH v2] net-ipv6: fix excessive RTF_ADDRCONF flag on ::1/128 local route (and others)

2019-09-04 Thread David Miller
From: Maciej Żenczykowski Date: Mon, 2 Sep 2019 09:23:36 -0700 > From: Maciej Żenczykowski > > There is a subtle change in behaviour introduced by: > commit c7a1ce397adacaf5d4bb2eab0a738b5f80dc3e43 > 'ipv6: Change addrconf_f6i_alloc to use ip6_route_info_create' > > Before that patch /pro

Re: [PATCH net-next v2 0/3] dpaa2-eth: Add new statistics counters

2019-09-04 Thread David Miller
From: Ioana Radulescu Date: Mon, 2 Sep 2019 13:23:16 +0300 > Recent firmware versions offer access to more DPNI statistics > counters. Add the relevant ones to ethtool interface stats. > > Also we can now make use of a new counter for in flight egress frames > to avoid sleeping an arbitrary amo

Re: [PATCH net] rxrpc: Fix misplaced traceline

2019-09-04 Thread David Miller
From: David Howells Date: Mon, 02 Sep 2019 11:34:08 +0100 > There's a misplaced traceline in rxrpc_input_packet() which is looking at a > packet that just got released rather than the replacement packet. > > Fix this by moving the traceline after the assignment that moves the new > packet pointe

Re: [PATCH net] sctp: use transport pf_retrans in sctp_do_8_2_transport_strike

2019-09-04 Thread David Miller
From: Xin Long Date: Mon, 2 Sep 2019 23:24:21 +0800 > Transport should use its own pf_retrans to do the error_count > check, instead of asoc's. Otherwise, it's meaningless to make > pf_retrans per transport. > > Fixes: 5aa93bcf66f4 ("sctp: Implement quick failover draft from tsvwg") > Signed-of

RE: [PATCH v2 net-next 2/2] i40e: Implement debug macro hw_dbg using dev_dbg

2019-09-04 Thread Bowers, AndrewX
> -Original Message- > From: Mauro S. M. Rodrigues [mailto:maur...@linux.vnet.ibm.com] > Sent: Tuesday, September 3, 2019 12:20 PM > To: Kirsher, Jeffrey T > Cc: intel-wired-...@lists.osuosl.org; netdev@vger.kernel.org; > da...@davemloft.net; Bowers, AndrewX ; > Jakub Kicinski ; > maur...@

Re: [PATCH iproute2-next] bpf: fix snprintf truncation warning

2019-09-04 Thread David Ahern
On 9/4/19 9:50 AM, Andrea Claudi wrote: > gcc v9.2.1 produces the following warning compiling iproute2: > > bpf.c: In function ‘bpf_get_work_dir’: > bpf.c:784:49: warning: ‘snprintf’ output may be truncated before the last > format character [-Wformat-truncation=] > 784 | snprintf(bpf_wrk_dir,

Re: [PATCH 0/5] Netfilter fixes for net

2019-09-04 Thread David Miller
From: Pablo Neira Ayuso Date: Wed, 4 Sep 2019 21:36:41 +0200 > The following patchset contains Netfilter fixes for net: > > 1) br_netfilter drops IPv6 packets if ipv6 is disabled, from Leonardo Bras. > > 2) nft_socket hits BUG() due to illegal skb->sk caching, patch from >Fernando Fernande

RE: [PATCH v2 net-next 1/2] i40e: fix hw_dbg usage in i40e_hmc_get_object_va

2019-09-04 Thread Bowers, AndrewX
> -Original Message- > From: Mauro S. M. Rodrigues [mailto:maur...@linux.vnet.ibm.com] > Sent: Tuesday, September 3, 2019 12:20 PM > To: Kirsher, Jeffrey T > Cc: intel-wired-...@lists.osuosl.org; netdev@vger.kernel.org; > da...@davemloft.net; Bowers, AndrewX ; > Jakub Kicinski ; > maur...@

Re: [PATCHv2 1/1] forcedeth: use per cpu to collect xmit/recv statistics

2019-09-04 Thread David Miller
From: Zhu Yanjun Date: Sun, 1 Sep 2019 03:26:13 -0400 > +static inline void nv_get_stats(int cpu, struct fe_priv *np, > + struct rtnl_link_stats64 *storage) ... > +static inline void rx_missing_handler(u32 flags, struct fe_priv *np) > +{ Never use the inline keyword

[PATCH 1/5] netfilter: bridge: Drops IPv6 packets if IPv6 module is not loaded

2019-09-04 Thread Pablo Neira Ayuso
From: Leonardo Bras A kernel panic can happen if a host has disabled IPv6 on boot and have to process guest packets (coming from a bridge) using it's ip6tables. IPv6 packets need to be dropped if the IPv6 module is not loaded, and the host ip6tables will be used. Signed-off-by: Leonardo Bras A

[PATCH 5/5] netfilter: nf_flow_table: set default timeout after successful insertion

2019-09-04 Thread Pablo Neira Ayuso
Set up the default timeout for this new entry otherwise the garbage collector might quickly remove it right after the flowtable insertion. Fixes: ac2a5e23 ("netfilter: add generic flow table infrastructure") Signed-off-by: Pablo Neira Ayuso --- net/netfilter/nf_flow_table_core.c | 2 +- 1 fi

[PATCH 2/5] netfilter: nft_socket: fix erroneous socket assignment

2019-09-04 Thread Pablo Neira Ayuso
From: Fernando Fernandez Mancera The socket assignment is wrong, see skb_orphan(): When skb->destructor callback is not set, but skb->sk is set, this hits BUG(). Link: https://bugzilla.redhat.com/show_bug.cgi?id=1651813 Fixes: 554ced0a6e29 ("netfilter: nf_tables: add support for native socket m

[PATCH 4/5] netfilter: ctnetlink: honor IPS_OFFLOAD flag

2019-09-04 Thread Pablo Neira Ayuso
If this flag is set, timeout and state are irrelevant to userspace. Fixes: 90964016e5d3 ("netfilter: nf_conntrack: add IPS_OFFLOAD status bit") Signed-off-by: Pablo Neira Ayuso --- net/netfilter/nf_conntrack_netlink.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/net

[PATCH 3/5] netfilter: nft_fib_netdev: Terminate rule eval if protocol=IPv6 and ipv6 module is disabled

2019-09-04 Thread Pablo Neira Ayuso
From: Leonardo Bras If IPv6 is disabled on boot (ipv6.disable=1), but nft_fib_inet ends up dealing with a IPv6 packet, it causes a kernel panic in fib6_node_lookup_1(), crashing in bad_page_fault. The panic is caused by trying to deference a very low address (0x38 in ppc64le), due to ipv6.fib6_m

[PATCH 0/5] Netfilter fixes for net

2019-09-04 Thread Pablo Neira Ayuso
Hi, The following patchset contains Netfilter fixes for net: 1) br_netfilter drops IPv6 packets if ipv6 is disabled, from Leonardo Bras. 2) nft_socket hits BUG() due to illegal skb->sk caching, patch from Fernando Fernandez Mancera. 3) nft_fib_netdev could be called with ipv6 disabled, leadi

Re: Is bug 200755 in anyone's queue??

2019-09-04 Thread Eric Dumazet
On 9/4/19 5:46 PM, Willem de Bruijn wrote: > On Wed, Sep 4, 2019 at 10:51 AM Steve Zabele wrote: >> >> I think a dual table approach makes a lot of sense here, especially if we >> look at the different use cases. For the DNS server example, almost >> certainly there will not be any connected

Re: [PATCH net 03/11] bonding: split IFF_BONDING into IFF_BONDING and IFF_BONDING_SLAVE

2019-09-04 Thread Jay Vosburgh
Taehee Yoo wrote: >The IFF_BONDING means bonding master or bonding slave device. > >->ndo_add_slave() sets IFF_BONDING flag and ->ndo_del_slave() removes >IFF_BONDING flag. >This routine makes a problem in the nesting bonding structure. > >bond1<--bond2 > >Both bond0 and bond1 are bonding device

Re: [PATCH iproute2] nexthop: Add space after blackhole

2019-09-04 Thread Stephen Hemminger
On Wed, 4 Sep 2019 08:09:52 -0700 David Ahern wrote: > From: David Ahern > > Add a space after 'blackhole' is missing to properly separate the > protocol when it is given. > > Signed-off-by: David Ahern Applied with Fixes tag

Re: [PATCH iproute2] devlink: fix segfault on health command

2019-09-04 Thread Stephen Hemminger
On Wed, 4 Sep 2019 19:26:14 +0200 Andrea Claudi wrote: > devlink segfaults when using grace_period without reporter > > $ devlink health set pci/:00:09.0 grace_period 3500 > Segmentation fault > > devlink is instead supposed to gracefully fail printing a warning > message > > $ devlink he

Re: [PATCH net 00/11] net: fix nested device bugs

2019-09-04 Thread Stephen Hemminger
On Thu, 5 Sep 2019 03:38:28 +0900 Taehee Yoo wrote: > This patchset fixes several bugs that are related to nesting > device infrastructure. > Current nesting infrastructure code doesn't limit the depth level of > devices. nested devices could be handled recursively. at that moment, > it needs hu

Re: [PATCH net] dev: Delay the free of the percpu refcount

2019-09-04 Thread Subash Abhinov Kasiviswanathan
On 2019-08-30 15:03, Subash Abhinov Kasiviswanathan wrote: This looks bogus. Whatever layer tries to access dev refcnt after free_netdev() has been called is buggy. I would rather trap early and fix the root cause. Untested patch : diff --git a/include/linux/netdevice.h b/include/linux/netdev

[PATCH v3 bpf-next 2/3] bpf: implement CAP_BPF

2019-09-04 Thread Alexei Starovoitov
Implement permissions as stated in uapi/linux/capability.h Signed-off-by: Alexei Starovoitov --- kernel/bpf/arraymap.c | 2 +- kernel/bpf/cgroup.c | 2 +- kernel/bpf/core.c | 4 +- kernel/bpf/hashtab.c

[PATCH v3 bpf-next 3/3] perf: implement CAP_TRACING

2019-09-04 Thread Alexei Starovoitov
Implement permissions as stated in uapi/linux/capability.h Signed-off-by: Alexei Starovoitov --- arch/powerpc/perf/core-book3s.c | 4 ++-- arch/x86/events/intel/bts.c | 2 +- arch/x86/events/intel/core.c| 2 +- arch/x86/events/intel/p4.c | 2 +- kernel/events/core.c|

[PATCH v3 bpf-next 1/3] capability: introduce CAP_BPF and CAP_TRACING

2019-09-04 Thread Alexei Starovoitov
Split BPF and perf/tracing operations that are allowed under CAP_SYS_ADMIN into corresponding CAP_BPF and CAP_TRACING. For backward compatibility include them in CAP_SYS_ADMIN as well. The end result provides simple safety model for applications that use BPF: - for tracing program types BPF_PROG

[PATCH net 09/11] net: core: add ignore flag to netdev_adjacent structure

2019-09-04 Thread Taehee Yoo
In order to link an adjacent node, netdev_upper_dev_link() is used and in order to unlink an adjacent node, netdev_upper_dev_unlink() is used. unlink operation does not fail, but link operation can fail. In order to exchange adjacent nodes, we should unlink an old adjacent node first. then, link a

[PATCH net 11/11] net: remove unnecessary variables and callback

2019-09-04 Thread Taehee Yoo
This patch removes variables and callback these are related to the nested device structure. devices that can be nested have their own nest_level variable that represents the depth of nested devices. In the previous patch, new {lower/upper}_level variables are added and they replace old private nest

[PATCH net 10/11] vxlan: add adjacent link to limit depth level

2019-09-04 Thread Taehee Yoo
Current vxlan code doesn't limit the number of nested devices. Nested devices would be handled recursively and this routine needs huge stack memory. So, unlimited nested devices could make stack overflow. In order to fix this issue, this patch adds adjacent links. The adjacent link APIs internally

[PATCH net 07/11] macvlan: use dynamic lockdep key instead of subclass

2019-09-04 Thread Taehee Yoo
All macvlan device has same lockdep key and subclass is initialized with nest_level. But actual nest_level value can be changed when a lower device is attached. And at this moment, the subclass should be updated but it seems to be unsafe. So this patch makes macvlan use dynamic lockdep key instead

[PATCH net 08/11] macsec: fix refcnt leak in module exit routine

2019-09-04 Thread Taehee Yoo
When a macsec interface is created, it increases a refcnt to a lower device(real device). when macsec interface is deleted, the refcnt is decreased in macsec_free_netdev(), which is ->priv_destructor() of macsec interface. The problem scenario is this. When nested macsec interfaces are exiting, th

[PATCH net 05/11] team: use dynamic lockdep key instead of static key

2019-09-04 Thread Taehee Yoo
In the current code, all team devices have same static lockdep key and team devices could be nested so that it makes unnecessary lockdep warning. Test commands: ip link add team0 type team for i in {1..7} do let A=$i-1 ip link add team$i type team ip

[PATCH net 06/11] macsec: use dynamic lockdep key instead of subclass

2019-09-04 Thread Taehee Yoo
All macsec device has same lockdep key and subclass is initialized with nest_level. But actual nest_level value can be changed when a lower device is attached. And at this moment, the subclass should be updated but it seems to be unsafe. So this patch makes macsec use dynamic lockdep key instead of

[PATCH net 02/11] vlan: use dynamic lockdep key instead of subclass

2019-09-04 Thread Taehee Yoo
All VLAN device has same lockdep key and subclass is initialized with nest_level. But actual nest_level value can be changed when a lower device is attached. And at this moment, the subclass should be updated but it seems to be unsafe. So this patch makes VLAN use dynamic lockdep key instead of the

[PATCH net 04/11] bonding: use dynamic lockdep key instead of subclass

2019-09-04 Thread Taehee Yoo
All bonding device has same lockdep key and subclass is initialized with nest_level. But actual nest_level value can be changed when a lower device is attached. And at this moment, the subclass should be updated but it seems to be unsafe. So this patch makes bonding use dynamic lockdep key instead

[PATCH net 03/11] bonding: split IFF_BONDING into IFF_BONDING and IFF_BONDING_SLAVE

2019-09-04 Thread Taehee Yoo
The IFF_BONDING means bonding master or bonding slave device. ->ndo_add_slave() sets IFF_BONDING flag and ->ndo_del_slave() removes IFF_BONDING flag. This routine makes a problem in the nesting bonding structure. bond1<--bond2 Both bond0 and bond1 are bonding device and these should keep having

[PATCH net 01/11] net: core: limit nested device depth

2019-09-04 Thread Taehee Yoo
Current code doesn't limit the number of nested devices. Nested devices would be handled recursively and this needs huge stack memory. So, unlimited nested devices could make stack overflow. This patch adds upper_level and lower_leve, they are common variables and represent maximum lower/upper dep

[PATCH net 00/11] net: fix nested device bugs

2019-09-04 Thread Taehee Yoo
This patchset fixes several bugs that are related to nesting device infrastructure. Current nesting infrastructure code doesn't limit the depth level of devices. nested devices could be handled recursively. at that moment, it needs huge memory and stack overflow could occur. Below devices type have

[PATCH v1] pppoatm: use %*ph to print small buffer

2019-09-04 Thread Andy Shevchenko
Use %*ph format to print small buffer as hex string. Signed-off-by: Andy Shevchenko --- net/atm/pppoatm.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/net/atm/pppoatm.c b/net/atm/pppoatm.c index bd3da9af5ef6..45d8e1d5d033 100644 --- a/net/atm/pppoatm.c +++ b/net/atm/ppp

[PATCH iproute2] devlink: fix segfault on health command

2019-09-04 Thread Andrea Claudi
devlink segfaults when using grace_period without reporter $ devlink health set pci/:00:09.0 grace_period 3500 Segmentation fault devlink is instead supposed to gracefully fail printing a warning message $ devlink health set pci/:00:09.0 grace_period 3500 Reporter's name is expected. Th

Re: [PATCH bpf-next v3 3/4] xsk: use state member for socket synchronization

2019-09-04 Thread Jonathan Lemon
On 4 Sep 2019, at 4:49, Björn Töpel wrote: From: Björn Töpel Prior the state variable was introduced by Ilya, the dev member was used to determine whether the socket was bound or not. However, when dev was read, proper SMP barriers and READ_ONCE were missing. In order to address the missing

Re: rtnl_lock() question

2019-09-04 Thread Jonathan Lemon
On 4 Sep 2019, at 0:39, Eric Dumazet wrote: On 9/3/19 11:55 PM, Jonathan Lemon wrote: How appropriate is it to hold the rtnl_lock() across a sleepable memory allocation? On one hand it's just a mutex, but it would seem like it could block quite a few things. Sure, all GFP_KERNEL allocations

Re: [PATCH iproute2-next] bpf: fix snprintf truncation warning

2019-09-04 Thread Andrea Claudi
On Wed, Sep 4, 2019 at 5:50 PM Andrea Claudi wrote: > > gcc v9.2.1 produces the following warning compiling iproute2: > > bpf.c: In function ‘bpf_get_work_dir’: > bpf.c:784:49: warning: ‘snprintf’ output may be truncated before the last > format character [-Wformat-truncation=] > 784 | snprint

[PATCH bpf-next 3/6] selftests/bpf: test_progs: convert test_sockopt_sk

2019-09-04 Thread Stanislav Fomichev
Move the files, adjust includes, remove entry from Makefile & .gitignore Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/bpf/.gitignore| 1 - tools/testing/selftests/bpf/Makefile | 3 +- .../sockopt_sk.c} | 60 --- tool

[PATCH bpf-next 2/6] selftests/bpf: test_progs: convert test_sockopt

2019-09-04 Thread Stanislav Fomichev
Move the files, adjust includes, remove entry from Makefile & .gitignore Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/bpf/.gitignore| 1 - tools/testing/selftests/bpf/Makefile | 3 +- .../{test_sockopt.c => prog_tests/sockopt.c} | 50 +++ 3 fi

[PATCH bpf-next 5/6] selftests/bpf: test_progs: convert test_sockopt_inherit

2019-09-04 Thread Stanislav Fomichev
Move the files, adjust includes, remove entry from Makefile & .gitignore I also added pthread_cond_wait for the server thread startup. We don't want to connect to the server that's not yet up (for some reason this existing race is now more prominent with test_progs). Signed-off-by: Stanislav Fomi

[PATCH bpf-next 4/6] selftests/bpf: test_progs: convert test_sockopt_multi

2019-09-04 Thread Stanislav Fomichev
Move the files, adjust includes, remove entry from Makefile & .gitignore Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/bpf/.gitignore| 1 - tools/testing/selftests/bpf/Makefile | 3 +- .../sockopt_multi.c} | 62 +++ 3 fi

[PATCH bpf-next 6/6] selftests/bpf: test_progs: convert test_tcp_rtt

2019-09-04 Thread Stanislav Fomichev
Move the files, adjust includes, remove entry from Makefile & .gitignore Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/bpf/.gitignore| 1 - tools/testing/selftests/bpf/Makefile | 3 +- .../{test_tcp_rtt.c => prog_tests/tcp_rtt.c} | 83 ++- 3 fi

[PATCH bpf-next 1/6] selftests/bpf: test_progs: add test__join_cgroup helper

2019-09-04 Thread Stanislav Fomichev
test__join_cgroup() combines the following operations that usually go hand in hand and returns cgroup fd: * setup cgroup environment (make sure cgroupfs is mounted) * mkdir cgroup * join cgroup It also marks a test as a "cgroup cleanup needed" and removes cgroup state after the test is done

[PATCH bpf-next 0/6] selftests/bpf: move sockopt tests under test_progs

2019-09-04 Thread Stanislav Fomichev
Now that test_progs is shaping into more generic test framework, let's convert sockopt tests to it. This requires adding a helper to create and join a cgroup first (test__join_cgroup). Since we already hijack stdout/stderr that shouldn't be a problem (cgroup helpers log to stderr). The rest of the

[PATCH iproute2-next] bpf: fix snprintf truncation warning

2019-09-04 Thread Andrea Claudi
gcc v9.2.1 produces the following warning compiling iproute2: bpf.c: In function ‘bpf_get_work_dir’: bpf.c:784:49: warning: ‘snprintf’ output may be truncated before the last format character [-Wformat-truncation=] 784 | snprintf(bpf_wrk_dir, sizeof(bpf_wrk_dir), "%s/", mnt); |

Re: Is bug 200755 in anyone's queue??

2019-09-04 Thread Willem de Bruijn
On Wed, Sep 4, 2019 at 10:51 AM Steve Zabele wrote: > > I think a dual table approach makes a lot of sense here, especially if we > look at the different use cases. For the DNS server example, almost certainly > there will not be any connected sockets using the server port, so a test of > wheth

Re: KSZ8863 ethernet PHY support question

2019-09-04 Thread Andrew Lunn
On Tue, Sep 03, 2019 at 01:59:18PM +, HOLTZ Matthieu wrote: > Hello, > > I’d like to use a switch phy KSZ8863 with an NXP i.mx8mm MPU (new motherboard > dev) and a kernel 4.14.x but I am a bit lost regarding the driver support. > > Is the Phy supported by the driver under linux/drivers/net/p

Re: [PATCH v2 bpf-next 2/3] bpf: implement CAP_BPF

2019-09-04 Thread Alexei Starovoitov
On 9/4/19 8:16 AM, Daniel Borkmann wrote: > opening/creating BPF maps" error="Unable to create map > /run/cilium/bpffs/tc/globals/cilium_lxc: operation not permitted" > subsys=daemon > 2019-09-04T14:11:47.28178666Z level=fatal msg="Error while creating > daemon" error="Unable to create map > /r

Re: [PATCH v2 bpf-next 2/3] bpf: implement CAP_BPF

2019-09-04 Thread Daniel Borkmann
On 9/4/19 3:39 AM, Alexei Starovoitov wrote: On 8/30/19 8:19 AM, Nicolas Dichtel wrote: Le 29/08/2019 à 19:30, Alexei Starovoitov a écrit : [snip] These are the links that showing that k8 can delegates caps. Are you saying that you know of folks who specifically delegate cap_sys_admin and cap_n

REPLY

2019-09-04 Thread Ms.Ella Golan
I am Ms.Ella Golan, I am the Executive Vice President Banking Division with FIRST INTERNATIONAL BANK OF ISRAEL LTD (FIBI). I am getting in touch with you regarding an extremely important and urgent matter. If you would oblige me the opportunity, I shall provide you with details upon your respons

[PATCH iproute2] nexthop: Add space after blackhole

2019-09-04 Thread David Ahern
From: David Ahern Add a space after 'blackhole' is missing to properly separate the protocol when it is given. Signed-off-by: David Ahern --- ip/ipnexthop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ip/ipnexthop.c b/ip/ipnexthop.c index f35aab52b775..8356aca296de 1006

Re: [PATCH v3 net] net: Properly update v4 routes with v6 nexthop

2019-09-04 Thread David Ahern
On 9/4/19 8:11 AM, Donald Sharp wrote: > When creating a v4 route that uses a v6 nexthop from a nexthop group. > Allow the kernel to properly send the nexthop as v6 via the RTA_VIA > attribute. > ... > > Fixes: dcb1ecb50edf (“ipv4: Prepare for fib6_nh from a nexthop object”) > Signed-off-by: Do

Re: [PATCH 2/2] ip nexthop: Allow flush|list operations to specify a specific protocol

2019-09-04 Thread David Ahern
On 8/9/19 6:18 PM, Donald Sharp wrote: > In the case where we have a large number of nexthops from a specific > protocol, allow the flush and list operations to take a protocol > to limit the commands scopes. > > Signed-off-by: Donald Sharp > --- > ip/ipnexthop.c | 16 +++- > 1 file

Re: Is bug 200755 in anyone's queue??

2019-09-04 Thread Steve Zabele
I think a dual table approach makes a lot of sense here, especially if we look at the different use cases. For the DNS server example, almost certainly there will not be any connected sockets using the server port, so a test of whether the connected table is empty (maybe a boolean stored with th

Re: Is bug 200755 in anyone's queue??

2019-09-04 Thread Willem de Bruijn
On Wed, Sep 4, 2019 at 8:23 AM Eric Dumazet wrote: > > > > On 9/4/19 2:00 PM, Mark KEATON wrote: > > Hi Willem, > > > > I am the person who commented on the original bug report in bugzilla. > > > > In communicating with Steve just now about possible solutions that maintain > > the efficiency that

Dear friend, i am contacting you independently of my investigation in my bank and no one is informed of this communication. I need your urgent assistance in transferring the sum of $11.6million dollar

2019-09-04 Thread Edward Willie

[PATCH v3 net] net: Properly update v4 routes with v6 nexthop

2019-09-04 Thread Donald Sharp
When creating a v4 route that uses a v6 nexthop from a nexthop group. Allow the kernel to properly send the nexthop as v6 via the RTA_VIA attribute. Broken behavior: $ ip nexthop add via fe80::9 dev eth0 $ ip nexthop show id 1 via fe80::9 dev eth0 scope link $ ip route add 4.5.6.7/32 nhid 1 $ ip

[PATCH 4/4] gianfar: use DT more consistently when selecting PHY connection type

2019-09-04 Thread Arseny Solokha
Historically, gianfar only used phy-connection-type DT property when connected to PHY in the rgmii-id mode. It ignored the property otherwise, relying on the connection type auto-detection carried out by MAC and providing that reconstructed mode to of_phy_connect(). It also did not consider alterna

Re: [RFC PATCH 1/2] gianfar: convert to phylink

2019-09-04 Thread Arseny Solokha
> Hi Arseny. > > On Tue, 30 Jul 2019 at 17:40, Arseny Solokha wrote: >> >> > Hi Arseny, >> > >> > Nice project! >> >> Vladimir, Russell, thanks for your review. I'm on vacation now, so won't >> fully >> address your comments in a few weeks: while I can build the code, I won't >> have >> access t

[PATCH 1/4] gianfar: remove forward declarations

2019-09-04 Thread Arseny Solokha
Remove forward declarations of various static functions located in two driver implementation files and rearrange the corresponding definitions accordingly. This patch only introduces mechanical changes, namely it removes forward declarations and moves function definitions around; it does not chang

  1   2   >