Re: [PATCH NET v3 1/2] net: phy: Add phy loopback support in net phy framework

2017-06-23 Thread Yunsheng Lin
On 2017/6/24 11:40, Yunsheng Lin wrote: > Hi, Andrew > > On 2017/6/24 11:12, Andrew Lunn wrote: >>> +int phy_loopback(struct phy_device *phydev, bool enable) >>> +{ >>> + struct phy_driver *phydrv = to_phy_driver(phydev->mdio.dev.driver); >>> + int ret = 0; >>> + >>> + if (enable && phydev

Re: [PATCH NET v3 1/2] net: phy: Add phy loopback support in net phy framework

2017-06-23 Thread Yunsheng Lin
Hi, Andrew On 2017/6/24 11:12, Andrew Lunn wrote: >> +int phy_loopback(struct phy_device *phydev, bool enable) >> +{ >> +struct phy_driver *phydrv = to_phy_driver(phydev->mdio.dev.driver); >> +int ret = 0; >> + >> +if (enable && phydev->loopback_enabled) >> +return -EBUSY;

Re: [PATCH net-next] net: dsa: mv88e6xxx: fix error code in mv88e6390_serdes_power()

2017-06-23 Thread Andrew Lunn
On Fri, Jun 23, 2017 at 06:17:04PM +0300, Dan Carpenter wrote: > We're accidentally returning the wrong variable. "cmode" is > uninitialized at this point so it causes a static checker warning. > > Fixes: 6335e9f2446b ("net: dsa: mv88e6xxx: mv88e6390X SERDES support") > Signed-off-by: Dan Carpent

Re: [PATCH NET v3 2/2] net: hns: Use phy_driver to setup Phy loopback

2017-06-23 Thread Andrew Lunn
> static int hns_nic_config_phy_loopback(struct phy_device *phy_dev, u8 en) > { > -#define COPPER_CONTROL_REG 0 > -#define PHY_POWER_DOWN BIT(11) > -#define PHY_LOOP_BACK BIT(14) > - u16 val = 0; > + int err; > > if (phy_dev->is_c45) /* c45 branch adding for XGE PHY */ >

Re: [PATCH NET v3 1/2] net: phy: Add phy loopback support in net phy framework

2017-06-23 Thread Andrew Lunn
> +int phy_loopback(struct phy_device *phydev, bool enable) > +{ > + struct phy_driver *phydrv = to_phy_driver(phydev->mdio.dev.driver); > + int ret = 0; > + > + if (enable && phydev->loopback_enabled) > + return -EBUSY; > + > + if (!enable && !phydev->loopback_enabled)

Re: [PATCH 05/11] net: stmmac: dwmac-rk: Add internal phy support

2017-06-23 Thread Andrew Lunn
On Fri, Jun 23, 2017 at 12:59:07PM +0800, David Wu wrote: > To make internal phy worked, need to configure the phy_clock, > phy cru_reset and related registers. > > Change-Id: I6971c0a769754b824b1b908b56080cbaf7867d13 > Signed-off-by: David Wu > --- > .../devicetree/bindings/net/rockchip-dwmac.t

Re: [PATCH 04/11] net: stmmac: dwmac-rk: Remove unwanted code for rk3328_set_to_rmii()

2017-06-23 Thread Andrew Lunn
On Fri, Jun 23, 2017 at 12:42:02PM +0800, David Wu wrote: > This is wrong setting for rk3328_set_to_rmii(), so remove it. > > Change-Id: I9953784ea44335d90710e5473960c95b3d68a5fd Hi David This is not a reconsigned tag for a patch. Andrew

Re: [PATCH 01/11] net: phy: Add rockchip phy driver support

2017-06-23 Thread Andrew Lunn
On Fri, Jun 23, 2017 at 12:41:59PM +0800, David Wu wrote: > Support internal ephy currently. > > Signed-off-by: David Wu > --- > drivers/net/phy/Kconfig| 4 ++ > drivers/net/phy/Makefile | 1 + > drivers/net/phy/rockchip.c | 94 > ++ > 3 files

[PATCH] net/icmp: restore source address if packet is NATed

2017-06-23 Thread Jason A. Donenfeld
The ICMP routines use the source address for two reasons: 1. Rate-limiting ICMP transmissions based on source address, so that one source address cannot provoke a flood of replies. If the source address is wrong, the rate limiting will be incorrectly applied. 2. Choos

Re: [PATCH 01/11] net: phy: Add rockchip phy driver support

2017-06-23 Thread Andrew Lunn
> + > +static int internal_config_init(struct phy_device *phydev) > +{ internal_ is a bit generic. The Marvell Ethernet switches have internal phy, etc. rockchip_ would be a better prefix. Andrew

[PATCH net-next 4/4] sctp: adjust ssthresh when transport is idle

2017-06-23 Thread Marcelo Ricardo Leitner
RFC 4960 Errata 3.27 identifies that ssthresh should be adjusted to cwnd because otherwise it could cause the transport to lock into congestion avoidance phase specially if ssthresh was previously reduced by some packet drop, leading to poor performance. The Errata says to adjust ssthresh to cwnd

[PATCH net-next 3/4] sctp: adjust cwnd increase in Congestion Avoidance phase

2017-06-23 Thread Marcelo Ricardo Leitner
RFC4960 Errata 3.26 identified that at the same time RFC4960 states that cwnd should never grow more than 1*MTU per RTT, Section 7.2.2 was underspecified and as described could allow increasing cwnd more than that. This patch updates it so partial_bytes_acked is maxed to cwnd if flight_size doesn'

[PATCH net-next 2/4] sctp: allow increasing cwnd regardless of ctsn moving or not

2017-06-23 Thread Marcelo Ricardo Leitner
As per RFC4960 Errata 3.22, this condition is not needed anymore as it could cause the partial_bytes_acked to not consider the TSNs acked in the Gap Ack Blocks although they were received by the peer successfully. This patch thus drops the check for new Cumulative TSN Ack Point, leaving just the f

[PATCH net-next 0/4] RFC 4960 Errata fixes

2017-06-23 Thread Marcelo Ricardo Leitner
This patchset contains fixes for 4 Errata topics from https://tools.ietf.org/html/draft-ietf-tsvwg-rfc4960-errata-01 Namely, sections: 3.12. Order of Adjustments of partial_bytes_acked and cwnd 3.22. Increase of partial_bytes_acked in Congestion Avoidance 3.26. CWND Increase in Congestion Avoida

[PATCH net-next 1/4] sctp: update order of adjustments of partial_bytes_acked and cwnd

2017-06-23 Thread Marcelo Ricardo Leitner
RFC4960 Errata 3.12 says RFC4960 is unclear about the order of adjustments applied to partial_bytes_acked and cwnd in the congestion avoidance phase, and that the actual order should be: partial_bytes_acked is reset to (partial_bytes_acked - cwnd). Next, cwnd is increased by MTU. We were first inc

Re

2017-06-23 Thread Tom Crist
Ich habe eine Lotterie gewonnen, die ich beschlossen habe, einen Teil davon herauszugeben, Sie haben eine Spende von 4,8 Millionen Euro, ich gewann die Amerika-Lotterie im Wert von 40 Millionen Euro in Amerika und beschloss, einen Teil davon an fünf Glückspersonen und Wohltätigkeitshäuser zu s

Re: [PATCH v2] arm: eBPF JIT compiler

2017-06-23 Thread Shubham Bansal
Hi Russell,Daniel and Kees, I am attaching the latest patch with this mail. It included support for BPF_CALL | BPF_JMP tested with and without constant blinding on ARMv7 machine. Due to the limitation on my machine I can't test the tail call. It would be a great help if any of you could help me wi

Re: BUG: KASAN: use-after-free in free_old_xmit_skbs

2017-06-23 Thread Cong Wang
On Fri, Jun 23, 2017 at 1:43 AM, Jason Wang wrote: > > > On 2017年06月23日 02:53, Michael S. Tsirkin wrote: >> >> On Thu, Jun 22, 2017 at 08:15:58AM +0200, jean-philippe menil wrote: >>> >>> Hi Michael, >>> >>> from what i see, the race appear when we hit virtnet_reset in >>> virtnet_xdp_set. >>> vir

[PATCH v3 net] net: ipv6: reset daddr and dport in sk if connect() fails

2017-06-23 Thread Wei Wang
From: Wei Wang In __ip6_datagram_connect(), reset sk->sk_v6_daddr and inet->dport if error occurs. In udp_v6_early_demux(), check for sk_state to make sure it is in TCP_ESTABLISHED state. Together, it makes sure unconnected UDP socket won't be considered as a valid candidate for early demux. Fix

Re: unregister_netdevice: waiting for lo to become free. Usage count = 1

2017-06-23 Thread Andrei Vagin
On Fri, Jun 23, 2017 at 02:49:58PM -0700, Andrei Vagin wrote: > Hello Everyone, > > Today I've met a problem, when any attempts to create a new network > namespace hang up. > I see that one of previous namespaces can't be destroyed, because a > usage count for one > of its devices isn't zero. To r

Re: [PATCH 2/6] wl1251: Use request_firmware_prefer_user() for loading NVS calibration data

2017-06-23 Thread Luis R. Rodriguez
On Tue, May 16, 2017 at 10:41:08AM +0200, Arend Van Spriel wrote: > On 16-5-2017 1:13, Luis R. Rodriguez wrote: > > Since no upstream delta is needed for firmwared I'd like to first encourage > > evaluating the above. While distributions don't carry it yet that may be > > seen as > > an issue but

unregister_netdevice: waiting for lo to become free. Usage count = 1

2017-06-23 Thread Andrei Vagin
Hello Everyone, Today I've met a problem, when any attempts to create a new network namespace hang up. I see that one of previous namespaces can't be destroyed, because a usage count for one of its devices isn't zero. To reproduce the problem, you need to executed an attached program in a separate

Re: [PATCH net-next v3 01/15] bpf: BPF support for sock_ops

2017-06-23 Thread Daniel Borkmann
On 06/23/2017 01:57 AM, Lawrence Brakmo wrote: On 6/22/17, 4:19 PM, "netdev-ow...@vger.kernel.org on behalf of Daniel Borkmann" wrote: On 06/23/2017 12:58 AM, Lawrence Brakmo wrote: [...] > Daniel, I see value for having a global program, so I would like to keep that. When

Re: [PATCH v2] net/sctp/ulpevent.c: Deinline sctp_ulpevent_set_owner, save 1616 bytes

2017-06-23 Thread Marcelo Ricardo Leitner
On Wed, Jun 21, 2017 at 07:03:27PM +0200, Denys Vlasenko wrote: > This function compiles to 147 bytes of machine code. 13 callsites. > > I'm no expert on SCTP events, but quick reading of SCTP docs tells me that > SCTP events are not happening on every packet. > They are ASSOC_CHANGE, PEER_ADDR_CH

Re: [PATCH v3 07/11] tty: improve tty_insert_flip_char() fast path

2017-06-23 Thread Greg Kroah-Hartman
On Thu, Jun 22, 2017 at 07:13:51PM +0200, Arnd Bergmann wrote: > kernelci.org reports a crazy stack usage for the VT code when CONFIG_KASAN > is enabled: > > drivers/tty/vt/keyboard.c: In function 'kbd_keycode': > drivers/tty/vt/keyboard.c:1452:1: error: the frame size of 2240 bytes is > larger t

Re: [PATCH net-next 1/2] ipmr: restrict mroute "queue full" warning to related error values

2017-06-23 Thread Julien Gomes
On 06/23/2017 11:47 AM, David Miller wrote: > From: Julien Gomes > Date: Fri, 23 Jun 2017 10:52:26 -0700 > >> On 06/23/2017 10:39 AM, David Miller wrote: >> >>> From: Julien Gomes >>> Date: Wed, 21 Jun 2017 10:58:10 -0700 >>> When sending a cache report on mroute_sk, mroute will emit a

[PATCH net-next v3 08/12] nfp: provide nfp_port to of nfp_net_get_mac_addr()

2017-06-23 Thread Simon Horman
Provide port rather than vNIC as parameter of nfp_net_get_mac_addr. This is to allow this function to be used by representor netdevs where a vNIC may have more than one physical port none of which are associated with the vNIC. Signed-off-by: Simon Horman Reviewed-by: Jakub Kicinski --- drivers/

[PATCH net-next v3 09/12] nfp: add support for tx/rx with metadata portid

2017-06-23 Thread Simon Horman
Allow tx/rx with metadata port id. This will be used for tx/rx of representor netdevs acting as upper-devices while a pf netdev acts as a lower-device. Signed-off-by: Simon Horman Reviewed-by: Jakub Kicinski --- drivers/net/ethernet/netronome/nfp/nfp_net.h | 1 + .../net/ethernet/netrono

[PATCH net-next v3 11/12] nfp: add flower app

2017-06-23 Thread Simon Horman
Add app for flower offload. At this point the PF netdev and phys port representor netdevs are initialised. Follow-up work will add support for VF and PF representors and beyond that offloading the flower classifier. Based in part on work by Benjamin LaHaise and Bert van Leeuwen. Signed-off-by: Si

[PATCH net-next v3 12/12] nfp: add VF and PF representors to flower app

2017-06-23 Thread Simon Horman
Initialise VF and PF representors in flower app. Based in part on work by Benjamin LaHaise, Bert van Leeuwen and Jakub Kicinski. Signed-off-by: Simon Horman Reviewed-by: Jakub Kicinski --- v3 * Do not associate VF representors with PF using SET_NETDEV_DEV * Use random MAC address for VF represe

[PATCH net-next v3 05/12] nfp: general representor implementation

2017-06-23 Thread Simon Horman
Provide infrastructure to create and destroy representors of a given type. Parts based on work by Bert van Leeuwen, Benjamin LaHaise, and Jakub Kicinski. Signed-off-by: Simon Horman Reviewed-by: Jakub Kicinski --- drivers/net/ethernet/netronome/nfp/Makefile | 1 + drivers/net/ethernet/

[PATCH net-next v3 06/12] nfp: add stats and xmit helpers for representors

2017-06-23 Thread Simon Horman
Provide helpers for stats and xmit on representor netdevs. Parts based on work by Bert van Leeuwen, Benjamin LaHaise and Jakub Kicinski. Signed-off-by: Simon Horman Reviewed-by: Jakub Kicinski --- drivers/net/ethernet/netronome/nfp/nfp_net_repr.c | 199 +- drivers/net/ether

[PATCH net-next v3 10/12] nfp: add support for control messages for flower app

2017-06-23 Thread Simon Horman
In preparation for adding a new flower app - targeted at offloading the flower classifier - provide support for control message that it will use to communicate with the NFP. Based in part on work by Bert van Leeuwen. Signed-off-by: Simon Horman Reviewed-by: Jakub Kicinski --- v3 * Provide carri

[PATCH net-next v3 02/12] nfp: devlink add support for getting eswitch mode

2017-06-23 Thread Simon Horman
From: Jakub Kicinski Add app callback for reporting eswitch mode. Non-SRIOV apps should not implement this callback, nfp_app code will then respond with -EOPNOTSUPP. Signed-off-by: Jakub Kicinski Signed-off-by: Simon Horman --- drivers/net/ethernet/netronome/nfp/nfp_app.h | 15 ++

[PATCH net-next v3 04/12] nfp: map mac_stats and vf_cfg BARs

2017-06-23 Thread Simon Horman
If present map mac_stats and vf_cfg BARs. These will be used by representor netdevs to read statistics for phys port and vf representors. Also provide defines describing the layout of the mac_stats area. Similar defines are already present for the cf_cfg area. Based in part on work by Jakub Kicin

[PATCH net-next v3 03/12] nfp: move physical port init into a helper

2017-06-23 Thread Simon Horman
From: Jakub Kicinski Move MAC/PHY port init into a helper to make it easier to reuse it in the representor code. Signed-off-by: Jakub Kicinski Signed-off-by: Simon Horman --- drivers/net/ethernet/netronome/nfp/nfp_app_nic.c | 23 ++ drivers/net/ethernet/netronome/nfp/nfp_p

[PATCH net-next v3 07/12] nfp: app callbacks for SRIOV

2017-06-23 Thread Simon Horman
Add app-callbacks for app-specific initialisation of SRIOV. Disabling SRIOV is brought forward in nfp_pci_remove() so that nfp_app_sriov_disable is called while the app still exists. This is intended to be used to implement representor netdevs for virtual ports. Signed-off-by: Simon Horman Revi

[PATCH net-next v3 01/12] net: store port/representator id in metadata_dst

2017-06-23 Thread Simon Horman
From: Jakub Kicinski Switches and modern SR-IOV enabled NICs may multiplex traffic from Port representators and control messages over single set of hardware queues. Control messages and muxed traffic may need ordered delivery. Those requirements make it hard to comfortably use TC infrastructure

[PATCH net-next v3 00/12] nfp: add flower app with representors

2017-06-23 Thread Simon Horman
Hi, this series adds a flower app to the NFP driver. It initialises four types of netdevs: * PF netdev - lower-device for communication of packets to device * PF representor netdev * VF representor netdevs * Phys port representor netdevs The PF netdev acts as a lower-device which sends and recei

Faster TCP keepalive

2017-06-23 Thread Stephen Suryaputra Lin
Greetings, I'm writing this to probe if there has been thoughts or efforts in allowing sub-second TCP keep alive interval? One application is for TCP connections between IP hosts connected by an internal backplane where a faster detection is a necessity and the increased traffic can be accommodate

[PATCH 3/3] net: qcom/emac: add support for emulation systems

2017-06-23 Thread Timur Tabi
On emulation systems, the EMAC's internal PHY ("SGMII") is not present, but is not needed for network functionality. So just display a warning message and ignore the SGMII. Tested-by: Philip Elcan Tested-by: Adam Wallis Signed-off-by: Timur Tabi --- drivers/net/ethernet/qualcomm/emac/emac-sgm

[PATCH 1/3] net: qcom/emac: add shutdown function

2017-06-23 Thread Timur Tabi
The shutdown function halts all DMA and interrupts, so that all operations are discontinued when the system shuts down, e.g. via kexec or a forced reboot. Tested-by: Tyler Baicar Signed-off-by: Timur Tabi --- drivers/net/ethernet/qualcomm/emac/emac.c | 14 ++ 1 file changed, 14 inse

[PATCH 2/3][v2] net: qcom/emac: do not reset the EMAC during initialization

2017-06-23 Thread Timur Tabi
On ACPI systems, the driver depends on firmware pre-initializing the EMAC because we don't have access to the clocks, and the EMAC has specific clock programming requirements. Therefore, we don't want to reset the EMAC while we are completing the initialization. Tested-by: Richard Ruigrok Signed

[PATCH 0/3][v2] net: qcom/emac: various minor improvements

2017-06-23 Thread Timur Tabi
A collection of minor fixes and features to the Qualcomm Technologies EMAC network driver. Timur Tabi (3): net: qcom/emac: add shutdown function [v2] net: qcom/emac: do not reset the EMAC during initialization net: qcom/emac: add support for emulation systems drivers/net/ethernet/qualcomm/

Re: [PATCH net-next 0/4] net: phy: Support "internal" PHY interface

2017-06-23 Thread David Miller
From: Florian Fainelli Date: Fri, 23 Jun 2017 10:33:12 -0700 > This makes the "internal" phy-mode property generally available and > documented and this allows us to remove some custom parsing code > we had for bcmgenet and bcm_sf2 which both used that specific value. Nice cleanup. Series appli

Re: [PATCH 2/3] net: qcom/emac: do not reset the EMAC during initialization

2017-06-23 Thread David Miller
From: Timur Tabi Date: Fri, 23 Jun 2017 13:37:58 -0500 > On 06/23/2017 01:00 PM, David Miller wrote: >> What if the boot loader or something else left the chip in >> a weird state? > > We depend on the boot loader leaving the NIC in a very specific state > already, otherwise the driver can't ini

Re: [PATCH net-next 2/2] af_iucv: Move sockaddr length checks to before accessing sa_family in bind and connect handlers

2017-06-23 Thread David Miller
From: Oliver Hartkopp Date: Fri, 23 Jun 2017 19:36:12 +0200 > > > On 06/23/2017 07:32 PM, Julian Wiedmann wrote: >> From: Mateusz Jurczyk >> >> Verify that the caller-provided sockaddr structure is large enough to >> contain the sa_family field, before accessing it in bind() and connect() >>

Re: [PATCH net 0/2] bnxt_en: Error handling and netpoll fixes.

2017-06-23 Thread David Miller
From: Michael Chan Date: Fri, 23 Jun 2017 14:00:59 -0400 > Add missing error handling and fix netpoll handling. The current code > handles RX and TX events in netpoll mode and is causing lots of warnings > and errors in the RX code path in netpoll mode. The fix is to only handle > TX events in

Re: [PATCH net-next 1/2] ipmr: restrict mroute "queue full" warning to related error values

2017-06-23 Thread David Miller
From: Julien Gomes Date: Fri, 23 Jun 2017 10:52:26 -0700 > On 06/23/2017 10:39 AM, David Miller wrote: > >> From: Julien Gomes >> Date: Wed, 21 Jun 2017 10:58:10 -0700 >> >>> When sending a cache report on mroute_sk, mroute will emit a >>> "pending queue full" warning for every error value retu

Re: [PATCH net] net: dp83640: Avoid NULL pointer dereference.

2017-06-23 Thread David Miller
From: Richard Cochran Date: Fri, 23 Jun 2017 17:51:31 +0200 > The function, skb_complete_tx_timestamp(), used to allow passing in a > NULL pointer for the time stamps, but that was changed in commit > 62bccb8cdb69051b95a55ab0c489e3cab261c8ef ("net-timestamp: Make the > clone operation stand-alone

Re: [PATCH 2/3] net: qcom/emac: do not reset the EMAC during initialization

2017-06-23 Thread Timur Tabi
On 06/23/2017 01:00 PM, David Miller wrote: What if the boot loader or something else left the chip in a weird state? We depend on the boot loader leaving the NIC in a very specific state already, otherwise the driver can't initialize the hardware. The firmware has to pre-initialize the EMAC

Re: [pull request][net-next 00/15] Mellanox, mlx5 updates 2017-06-23

2017-06-23 Thread David Miller
From: Saeed Mahameed Date: Fri, 23 Jun 2017 17:26:07 +0300 > This series mainly from Tariq and Or includes updates to mlx5 core and > netdevice dirvers. > > From Tariq, RX path improvments. > From Or, header re-write updates and FW flash support. > For more detalis please see tag log below. > >

Re: [PATCH net-next 2/2] cxgb4: Use Firmware params to get buffer-group map

2017-06-23 Thread David Miller
From: Ganesh Goudar Date: Fri, 23 Jun 2017 19:14:37 +0530 > From: Arjun Vynipadath > > Buffer group mappings can be obtained using FW_PARAMs cmd for newer FW. > > Since some of the bg_maps are obtained in atomic context, created another > t4_query_params_ns(), that wont sleep when awaiting mbo

Re: [PATCH net-next 1/2] cxgb4: Update T6 Buffer Group and Channel Mappings

2017-06-23 Thread David Miller
From: Ganesh Goudar Date: Fri, 23 Jun 2017 19:14:36 +0530 > From: Arjun Vynipadath > > We were using t4_get_mps_bg_map() for both t4_get_port_stats() > to determine which MPS Buffer Groups to report statistics on for a given > Port, and also for t4_sge_alloc_rxq() to provide a TP Ingress Channe

Re: [PATCH -net] tls: return -EFAULT if copy_to_user() fails

2017-06-23 Thread David Miller
From: Dan Carpenter Date: Fri, 23 Jun 2017 13:15:44 +0300 > The copy_to_user() function returns the number of bytes remaining but we > want to return -EFAULT here. > > Fixes: 3c4d7559159b ("tls: kernel TLS support") > Signed-off-by: Dan Carpenter Dan, I happened to realize that tls is only in

Re: pull request (net-next): ipsec-next 2017-06-23

2017-06-23 Thread David Miller
From: Steffen Klassert Date: Fri, 23 Jun 2017 10:38:24 +0200 > 1) Use memdup_user to spmlify xfrm_user_policy. >From Geliang Tang. > > 2) Make xfrm_dev_register static to silence a sparse warning. >From Wei Yongjun. > > 3) Use crypto_memneq to check the ICV in the AH protocol. >From

Re: [PATCH V2 net-next 00/11] update ena ethernet driver to version 1.2.0

2017-06-23 Thread David Miller
From: Date: Fri, 23 Jun 2017 11:21:49 +0300 > From: Netanel Belgazal > > This patchset contains some new features/improvements that were added > to the ENA driver to increase its robustness and are based on > experience of wide ENA deployment. > > Change log: > > V2: > * Remove patch that add

Re: pull request (net): ipsec 2017-06-23

2017-06-23 Thread David Miller
From: Steffen Klassert Date: Fri, 23 Jun 2017 09:06:28 +0200 > 1) Fix xfrm garbage collecting when unregistering a netdevice. >From Hangbin Liu. > > 2) Fix NULL pointer derefernce when exiting a network namespace. >From Hangbin Liu. > > 3) Fix some error codes in pfkey to prevent a NULL

Re: [PATCH net-next] tcp: fix out-of-bounds access in ULP sysctl

2017-06-23 Thread David Miller
From: Jakub Kicinski Date: Thu, 22 Jun 2017 18:57:55 -0700 > KASAN reports out-of-bound access in proc_dostring() coming from > proc_tcp_available_ulp() because in case TCP ULP list is empty > the buffer allocated for the response will not have anything > printed into it. Set the first byte to z

Re: [Patch net] sit: use __GFP_NOWARN for user controlled allocation

2017-06-23 Thread David Miller
From: Cong Wang Date: Thu, 22 Jun 2017 15:29:33 -0700 > The memory allocation size is controlled by user-space, > if it is too large just fail silently and return NULL, > not to mention there is a fallback allocation later. > > Reported-by: Andrey Konovalov > Cc: Andrey Konovalov > Signed-off-

Re: [PATCH net-next] bpf: possibly avoid extra masking for narrower load in verifier

2017-06-23 Thread David Miller
From: Yonghong Song Date: Thu, 22 Jun 2017 15:07:39 -0700 > Commit 31fd85816dbe ("bpf: permits narrower load from bpf program > context fields") permits narrower load for certain ctx fields. > The commit however will already generate a masking even if > the prog-specific ctx conversion produces t

Re: [PATCH v2 net] udpv6: reset daddr and dport in sk if connect() fails

2017-06-23 Thread David Miller
From: Wei Wang Date: Thu, 22 Jun 2017 12:03:41 -0700 > From: Wei Wang > > In __ip6_datagram_connect(), reset sk->sk_v6_daddr and inet->dport if > error occurs so that udp_v6_early_demux() won't consider this socket > as a valid candidate for early demux. > > v2: fix compilation error > > Sign

[PATCH net 2/2] bnxt_en: Fix netpoll handling.

2017-06-23 Thread Michael Chan
To handle netpoll properly, the driver must only handle TX packets during NAPI. Handling RX events cause warnings and errors in netpoll mode. The ndo_poll_controller() method should call napi_schedule() directly so that a NAPI weight of zero will be used during netpoll mode. The bnxt_en driver su

[PATCH net 1/2] bnxt_en: Add missing logic to handle TPA end error conditions.

2017-06-23 Thread Michael Chan
When we get a TPA_END completion to handle a completed LRO packet, it is possible that hardware would indicate errors. The current code is not checking for the error condition. Define the proper error bits and the macro to check for this error and abort properly. Signed-off-by: Michael Chan ---

[PATCH net 0/2] bnxt_en: Error handling and netpoll fixes.

2017-06-23 Thread Michael Chan
Add missing error handling and fix netpoll handling. The current code handles RX and TX events in netpoll mode and is causing lots of warnings and errors in the RX code path in netpoll mode. The fix is to only handle TX events in netpoll mode. Michael Chan (2): bnxt_en: Add missing logic to ha

Re: [PATCH 2/3] net: qcom/emac: do not reset the EMAC during initialization

2017-06-23 Thread David Miller
From: Timur Tabi Date: Thu, 22 Jun 2017 13:05:31 -0500 > It doesn't make sense to reset the EMAC in the middle of initializing > it during the probe. > > Tested-by: Richard Ruigrok > Signed-off-by: Timur Tabi Why not? What if the boot loader or something else left the chip in a weird state?

RE: Bluetooth: might sleep error in hidp_session_thread

2017-06-23 Thread Rohit Vaswani
I don't have a way to reply back to the older message; but you can use by tested-by for the below patch and re-send: For patch: [v4,3/3] Bluetooth: hidp: fix possible might sleep error in hidp_session_thread Tested-by: Rohit Vaswani -Rohit -Original Message- From: jeffy [mailto:jeffy

Re: [PATCH] net: stmmac: make some functions static

2017-06-23 Thread David Miller
From: Colin King Date: Thu, 22 Jun 2017 17:17:29 +0100 > From: Colin Ian King > > The functions dwmac4_dma_init_rx_chan, dwmac4_dma_init_tx_chan and > dwmac4_dma_init_channel do not need to be in global scope, so them > static. > > Cleans up sparse warnings: > "symbol 'dwmac4_dma_init_rx_chan'

Re: [GIT PULL] arcnet: fixes and features

2017-06-23 Thread David Miller
From: Michael Grzeschik Date: Thu, 22 Jun 2017 17:31:02 +0200 > are available in the git repository at: > > pub...@git.pengutronix.de:/mgr/linux.git tags/arcnet-for-mainline I'm not pulling from that address, either setup a properl kernel.org GIT account or we work with just plain patches. N

Re: [PATCH net-next 1/2] ipmr: restrict mroute "queue full" warning to related error values

2017-06-23 Thread Julien Gomes
On 06/23/2017 10:39 AM, David Miller wrote: > From: Julien Gomes > Date: Wed, 21 Jun 2017 10:58:10 -0700 > >> When sending a cache report on mroute_sk, mroute will emit a >> "pending queue full" warning for every error value returned by >> sock_queue_rcv_skb(). >> This warning can be misleading,

Re: [PATCH net-next 0/8] xdp: offload mode

2017-06-23 Thread David Miller
From: Jakub Kicinski Date: Wed, 21 Jun 2017 18:25:02 -0700 > While we discuss the representors.. :) > > This set adds XDP flag for forcing offload and a attachment mode > for reporting to user space that program has been offloaded. The > nfp driver is modified to make use of the new flags, but

Re: [PATCH net-next 1/2] ipmr: restrict mroute "queue full" warning to related error values

2017-06-23 Thread David Miller
From: Julien Gomes Date: Wed, 21 Jun 2017 10:58:10 -0700 > When sending a cache report on mroute_sk, mroute will emit a > "pending queue full" warning for every error value returned by > sock_queue_rcv_skb(). > This warning can be misleading, for example on the EPERM error value > that sk_filter(

Re: [PATCH net-next 2/2] af_iucv: Move sockaddr length checks to before accessing sa_family in bind and connect handlers

2017-06-23 Thread Oliver Hartkopp
On 06/23/2017 07:32 PM, Julian Wiedmann wrote: > From: Mateusz Jurczyk > > Verify that the caller-provided sockaddr structure is large enough to > contain the sa_family field, before accessing it in bind() and connect() > handlers of the AF_IUCV socket. Since neither syscall enforces a minimum

[PATCH 2/4] net: phy: Support "internal" PHY interface

2017-06-23 Thread Florian Fainelli
Now that the Device Tree binding has been updated, update the PHY library phy_interface_t and phy_modes to support the "internal" PHY interface type. Signed-off-by: Florian Fainelli --- include/linux/phy.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/linux/phy.h b/include/linux

[PATCH 1/4] dt-bindings: Add "internal" as a valid 'phy-mode' property

2017-06-23 Thread Florian Fainelli
A number of Ethernet MACs have internal Ethernet PHYs and the internal wiring makes it so that this knowledge needs to be available using the standard 'phy-mode' property. Signed-off-by: Florian Fainelli --- Documentation/devicetree/bindings/net/ethernet.txt | 1 + 1 file changed, 1 insertion(+)

[PATCH net-next 4/4] net: dsa: bcm_sf2: Remove special handling of "internal" phy-mode

2017-06-23 Thread Florian Fainelli
The PHY library now supports an "internal" phy-mode, thus making our custom parsing code now unnecessary. Signed-off-by: Florian Fainelli --- drivers/net/dsa/bcm_sf2.c | 16 +--- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/drivers/net/dsa/bcm_sf2.c b/drivers/net/ds

[PATCH net-next 0/4] net: phy: Support "internal" PHY interface

2017-06-23 Thread Florian Fainelli
Hi all, This makes the "internal" phy-mode property generally available and documented and this allows us to remove some custom parsing code we had for bcmgenet and bcm_sf2 which both used that specific value. Florian Fainelli (4): dt-bindings: Add "internal" as a valid 'phy-mode' property ne

[PATCH net-next 1/4] dt-bindings: Add "internal" as a valid 'phy-mode' property

2017-06-23 Thread Florian Fainelli
A number of Ethernet MACs have internal Ethernet PHYs and the internal wiring makes it so that this knowledge needs to be available using the standard 'phy-mode' property. Signed-off-by: Florian Fainelli --- Documentation/devicetree/bindings/net/ethernet.txt | 1 + 1 file changed, 1 insertion(+)

Re: [PATCH net-next 0/4] net: phy: Support "internal" PHY interface

2017-06-23 Thread Florian Fainelli
On 06/23/2017 10:33 AM, Florian Fainelli wrote: > Hi all, > > This makes the "internal" phy-mode property generally available and > documented and this allows us to remove some custom parsing code > we had for bcmgenet and bcm_sf2 which both used that specific value. Sorry for the resend, this is

[PATCH net-next 3/4] net: bcmgenet: Remove special handling of "internal" phy-mode

2017-06-23 Thread Florian Fainelli
The PHY library now supports an "internal" phy-mode, thus making our custom parsing code now unnecessary. Signed-off-by: Florian Fainelli --- drivers/net/ethernet/broadcom/genet/bcmmii.c | 24 1 file changed, 8 insertions(+), 16 deletions(-) diff --git a/drivers/net/eth

Re: [PATCH] PATCH v3 Convert multiple netdev_info messages to netdev_dbg

2017-06-23 Thread David Miller
From: Michael J Dilmore Date: Wed, 21 Jun 2017 03:08:54 +0100 > The bond_options.c file contains multiple netdev_info messages that > clutter kernel output. This patches replaces these with netdev_dbg messages > and adds a netdev_dbg for packets for slave. > > Signed-off-by: Michael J Dilmore >

[PATCH net-next 2/4] net: phy: Support "internal" PHY interface

2017-06-23 Thread Florian Fainelli
Now that the Device Tree binding has been updated, update the PHY library phy_interface_t and phy_modes to support the "internal" PHY interface type. Signed-off-by: Florian Fainelli --- include/linux/phy.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/linux/phy.h b/include/linux

[PATCH net-next 0/2] af_iucv updates

2017-06-23 Thread Julian Wiedmann
Hi Dave, please apply two af_iucv patches for net-next. Thanks, Julian Hans Wippel (1): net/iucv: improve endianness handling Mateusz Jurczyk (1): af_iucv: Move sockaddr length checks to before accessing sa_family in bind and connect handlers net/iucv/af_iucv.c | 10 -- 1 file

[PATCH 3/4] net: bcmgenet: Remove special handling of "internal" phy-mode

2017-06-23 Thread Florian Fainelli
The PHY library now supports an "internal" phy-mode, thus making our custom parsing code now unnecessary. Signed-off-by: Florian Fainelli --- drivers/net/ethernet/broadcom/genet/bcmmii.c | 24 1 file changed, 8 insertions(+), 16 deletions(-) diff --git a/drivers/net/eth

[PATCH net-next 2/2] af_iucv: Move sockaddr length checks to before accessing sa_family in bind and connect handlers

2017-06-23 Thread Julian Wiedmann
From: Mateusz Jurczyk Verify that the caller-provided sockaddr structure is large enough to contain the sa_family field, before accessing it in bind() and connect() handlers of the AF_IUCV socket. Since neither syscall enforces a minimum size of the corresponding memory region, very short sockadd

[PATCH 4/4] net: dsa: bcm_sf2: Remove special handling of "internal" phy-mode

2017-06-23 Thread Florian Fainelli
The PHY library now supports an "internal" phy-mode, thus making our custom parsing code now unnecessary. Signed-off-by: Florian Fainelli --- drivers/net/dsa/bcm_sf2.c | 16 +--- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/drivers/net/dsa/bcm_sf2.c b/drivers/net/ds

[PATCH 0/4] net: phy: Support "internal" PHY interface

2017-06-23 Thread Florian Fainelli
Hi all, This makes the "internal" phy-mode property generally available and documented and this allows us to remove some custom parsing code we had for bcmgenet and bcm_sf2 which both used that specific value. Florian Fainelli (4): dt-bindings: Add "internal" as a valid 'phy-mode' property ne

[PATCH net-next 1/2] net/iucv: improve endianness handling

2017-06-23 Thread Julian Wiedmann
From: Hans Wippel Use proper endianness conversion for an skb protocol assignment. Given that IUCV is only available on big endian systems (s390), this simply avoids an endianness warning reported by sparse. Signed-off-by: Hans Wippel Reviewed-by: Julian Wiedmann Reviewed-by: Ursula Braun Sig

Re: [PATCH net] net: account for current skb length when deciding about UFO

2017-06-23 Thread David Miller
From: Michal Kubecek Date: Mon, 19 Jun 2017 13:03:43 +0200 (CEST) > Our customer encountered stuck NFS writes for blocks starting at specific > offsets w.r.t. page boundary caused by networking stack sending packets via > UFO enabled device with wrong checksum. The problem can be reproduced by >

Re: [PATCH 05/11] net: stmmac: dwmac-rk: Add internal phy support

2017-06-23 Thread Heiko Stuebner
Hi David, Am Freitag, 23. Juni 2017, 12:59:07 CEST schrieb David Wu: > To make internal phy worked, need to configure the phy_clock, > phy cru_reset and related registers. > > Change-Id: I6971c0a769754b824b1b908b56080cbaf7867d13 please remove all Change-Ids from patches before sending upstream.

RE: RXFH manual configuration

2017-06-23 Thread Keller, Jacob E
> -Original Message- > From: Tariq Toukan [mailto:tar...@mellanox.com] > Sent: Sunday, June 18, 2017 1:32 AM > To: Keller, Jacob E > Cc: Linux Kernel Network Developers ; Saeed > Mahameed ; Eran Ben Elisha > > Subject: RXFH manual configuration > > Hi Jacob, > > I am looking at your p

RE: RXFH manual configuration

2017-06-23 Thread Keller, Jacob E
> -Original Message- > From: Tariq Toukan [mailto:tar...@mellanox.com] > Sent: Sunday, June 18, 2017 1:32 AM > To: Keller, Jacob E > Cc: Linux Kernel Network Developers ; Saeed > Mahameed ; Eran Ben Elisha > > Subject: RXFH manual configuration > > Hi Jacob, > > I am looking at your pat

Motorcycle Owners List

2017-06-23 Thread Mary Andrews
Hi, Hope all's well, Would you be interested in acquiring an email list of “ Motorcycle Owners List ” from USA? Each record in the list contains Contact Name (First, Middle and Last Name), Mailing Address, List type and Opt-in email address. All the contacts are opt-in verified, 100% permis

Re: fs, net: deadlock between bind/splice on af_unix

2017-06-23 Thread Cong Wang
Hi, On Thu, Jun 22, 2017 at 10:49 AM, wrote: > I was getting below crash while running mp4. Are you sure your 3.14 kernel has my patch in this thread? commit 0fb44559ffd67de8517098 is merged in 4.10. Also, your crash is on unix_dgram_sendmsg() path, not unix_bind().

Re: [PATCH 05/11] net: stmmac: dwmac-rk: Add internal phy support

2017-06-23 Thread Florian Fainelli
On 06/22/2017 09:59 PM, David Wu wrote: > To make internal phy worked, need to configure the phy_clock, > phy cru_reset and related registers. > > Change-Id: I6971c0a769754b824b1b908b56080cbaf7867d13 > Signed-off-by: David Wu > --- > .../devicetree/bindings/net/rockchip-dwmac.txt | 3 + > d

Re: [PATCH 01/11] net: phy: Add rockchip phy driver support

2017-06-23 Thread Florian Fainelli
On 06/22/2017 09:41 PM, David Wu wrote: > Support internal ephy currently. > > Signed-off-by: David Wu > --- > drivers/net/phy/Kconfig| 4 ++ > drivers/net/phy/Makefile | 1 + > drivers/net/phy/rockchip.c | 94 > ++ > 3 files changed, 99 inser

Re: [PATCH -net] tls: return -EFAULT if copy_to_user() fails

2017-06-23 Thread Dave Watson
On 06/23/17 01:15 PM, Dan Carpenter wrote: > The copy_to_user() function returns the number of bytes remaining but we > want to return -EFAULT here. > > Fixes: 3c4d7559159b ("tls: kernel TLS support") > Signed-off-by: Dan Carpenter Acked-by: Dave Watson Yes, -EFAULT seems like the correct choi

[PATCH net] net: dp83640: Avoid NULL pointer dereference.

2017-06-23 Thread Richard Cochran
The function, skb_complete_tx_timestamp(), used to allow passing in a NULL pointer for the time stamps, but that was changed in commit 62bccb8cdb69051b95a55ab0c489e3cab261c8ef ("net-timestamp: Make the clone operation stand-alone from phy timestamping"), and the existing call sites, all of which ar

Re: [PATCH net-next] udp: fix poll()

2017-06-23 Thread David Miller
From: Paolo Abeni Date: Fri, 23 Jun 2017 14:19:51 +0200 > Michael reported an UDP breakage caused by the commit b65ac44674dd > ("udp: try to avoid 2 cache miss on dequeue"). > The function __first_packet_length() can update the checksum bits > of the pending skb, making the scratched area out-of-

[PATCH net-next] net: dsa: mv88e6xxx: fix error code in mv88e6390_serdes_power()

2017-06-23 Thread Dan Carpenter
We're accidentally returning the wrong variable. "cmode" is uninitialized at this point so it causes a static checker warning. Fixes: 6335e9f2446b ("net: dsa: mv88e6xxx: mv88e6390X SERDES support") Signed-off-by: Dan Carpenter diff --git a/drivers/net/dsa/mv88e6xxx/serdes.c b/drivers/net/dsa/m

  1   2   >