1. 23 Jul, 2020 6 commits
    • Paolo Abeni's avatar
      mptcp: zero token hash at creation time. · 6ab301c9
      Paolo Abeni authored
      Otherwise the 'chain_len' filed will carry random values,
      some token creation calls will fail due to excessive chain
      length, causing unexpected fallback to TCP.
      
      Fixes: 2c5ebd00 ("mptcp: refactor token container")
      Reviewed-by: default avatarMat Martineau <mathew.j.martineau@linux.intel.com>
      Tested-by: default avatarChristoph Paasch <cpaasch@apple.com>
      Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6ab301c9
    • Colin Ian King's avatar
      lan743x: remove redundant initialization of variable current_head_index · bb809a04
      Colin Ian King authored
      The variable current_head_index is being initialized with a value that
      is never read and it is being updated later with a new value.  Replace
      the initialization of -1 with the latter assignment.
      
      Addresses-Coverity: ("Unused value")
      Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      bb809a04
    • Claudiu Manoil's avatar
      enetc: Remove the imdio bus on PF probe bailout · c6dd6488
      Claudiu Manoil authored
      enetc_imdio_remove() is missing from the enetc_pf_probe()
      bailout path. Not surprisingly because enetc_setup_serdes()
      is registering the imdio bus for internal purposes, and it's
      not obvious that enetc_imdio_remove() currently performs the
      teardown of enetc_setup_serdes().
      To fix this, define enetc_teardown_serdes() to wrap
      enetc_imdio_remove() (improve code maintenance) and call it
      on bailout and remove paths.
      
      Fixes: 975d183e ("net: enetc: Initialize SerDes for SGMII and USXGMII protocols")
      Signed-off-by: default avatarClaudiu Manoil <claudiu.manoil@nxp.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c6dd6488
    • Wang Hai's avatar
      net: qed: Remove unneeded cast from memory allocation · 7979a7d2
      Wang Hai authored
      Remove casting the values returned by memory allocation function.
      
      Coccinelle emits WARNING: casting value returned by memory allocation
      unction to (struct roce_destroy_qp_req_output_params *) is useless.
      
      This issue was detected by using the Coccinelle software.
      Signed-off-by: default avatarWang Hai <wanghai38@huawei.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      7979a7d2
    • Vladimir Oltean's avatar
      net: phy: fix check in get_phy_c45_ids · fb16d465
      Vladimir Oltean authored
      After the patch below, the iteration through the available MMDs is
      completely short-circuited, and devs_in_pkg remains set to the initial
      value of zero.
      
      Due to devs_in_pkg being zero, the rest of get_phy_c45_ids() is
      short-circuited too: the following loop never reaches below this point
      either (it executes "continue" for every device in package, failing to
      retrieve PHY ID for any of them):
      
      	/* Now probe Device Identifiers for each device present. */
      	for (i = 1; i < num_ids; i++) {
      		if (!(devs_in_pkg & (1 << i)))
      			continue;
      
      So c45_ids->device_ids remains populated with zeroes. This causes an
      Aquantia AQR412 PHY (same as any C45 PHY would, in fact) to be probed by
      the Generic PHY driver.
      
      The issue seems to be a case of submitting partially committed work (and
      therefore testing something other than was submitted).
      
      The intention of the patch was to delay exiting the loop until one more
      condition is reached (the devs_in_pkg read from hardware is either 0, OR
      mostly f's). So fix the patch to reflect that.
      
      Tested with traffic on a LS1028A-QDS, the PHY is now probed correctly
      using the Aquantia driver. The devs_in_pkg bit field is set to
      0xe000009a, and the MMDs that are present have the following IDs:
      
      [    5.600772] libphy: get_phy_c45_ids: device_ids[1]=0x3a1b662
      [    5.618781] libphy: get_phy_c45_ids: device_ids[3]=0x3a1b662
      [    5.630797] libphy: get_phy_c45_ids: device_ids[4]=0x3a1b662
      [    5.654535] libphy: get_phy_c45_ids: device_ids[7]=0x3a1b662
      [    5.791723] libphy: get_phy_c45_ids: device_ids[29]=0x3a1b662
      [    5.804050] libphy: get_phy_c45_ids: device_ids[30]=0x3a1b662
      [    5.816375] libphy: get_phy_c45_ids: device_ids[31]=0x0
      
      [    7.690237] mscc_felix 0000:00:00.5: PHY [0.5:00] driver [Aquantia AQR412] (irq=POLL)
      [    7.704739] mscc_felix 0000:00:00.5: PHY [0.5:01] driver [Aquantia AQR412] (irq=POLL)
      [    7.718918] mscc_felix 0000:00:00.5: PHY [0.5:02] driver [Aquantia AQR412] (irq=POLL)
      [    7.733044] mscc_felix 0000:00:00.5: PHY [0.5:03] driver [Aquantia AQR412] (irq=POLL)
      
      Fixes: bba238ed ("net: phy: continue searching for C45 MMDs even if first returned ffff:ffff")
      Reported-by: default avatarColin King <colin.king@canonical.com>
      Reported-by: default avatarIoana Ciornei <ioana.ciornei@nxp.com>
      Signed-off-by: default avatarVladimir Oltean <vladimir.oltean@nxp.com>
      Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      fb16d465
    • Richard Sailer's avatar
      net: dccp: Add SIOCOUTQ IOCTL support (send buffer fill) · 749c08f8
      Richard Sailer authored
      This adds support for the SIOCOUTQ IOCTL to get the send buffer fill
      of a DCCP socket, like UDP and TCP sockets already have.
      
      Regarding the used data field: DCCP uses per packet sequence numbers,
      not per byte, so sequence numbers can't be used like in TCP. sk_wmem_queued
      is not used by DCCP and always 0, even in test on highly congested paths.
      Therefore this uses sk_wmem_alloc like in UDP.
      Signed-off-by: default avatarRichard Sailer <richard_siegfried@systemli.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      749c08f8
  2. 22 Jul, 2020 15 commits
  3. 21 Jul, 2020 19 commits