1. 06 Aug, 2019 13 commits
    • Dave Taht's avatar
      Increase fq_codel count in the bulk dropper · ae697f3b
      Dave Taht authored
      In the field fq_codel is often used with a smaller memory or
      packet limit than the default, and when the bulk dropper is hit,
      the drop pattern bifircates into one that more slowly increases
      the codel drop rate and hits the bulk dropper more than it should.
      
      The scan through the 1024 queues happens more often than it needs to.
      
      This patch increases the codel count in the bulk dropper, but
      does not change the drop rate there, relying on the next codel round
      to deliver the next packet at the original drop rate
      (after that burst of loss), then escalate to a higher signaling rate.
      Signed-off-by: default avatarDave Taht <dave.taht@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ae697f3b
    • Nathan Chancellor's avatar
      net: mdio-octeon: Fix Kconfig warnings and build errors · b8fb6406
      Nathan Chancellor authored
      After commit 171a9bae ("staging/octeon: Allow test build on
      !MIPS"), the following combination of configs cause a few Kconfig
      warnings and build errors (distilled from arm allyesconfig and Randy's
      randconfig builds):
      
          CONFIG_NETDEVICES=y
          CONFIG_STAGING=y
          CONFIG_COMPILE_TEST=y
      
      and CONFIG_OCTEON_ETHERNET as either a module or built-in.
      
      WARNING: unmet direct dependencies detected for MDIO_OCTEON
        Depends on [n]: NETDEVICES [=y] && MDIO_DEVICE [=y] && MDIO_BUS [=y]
      && 64BIT [=n] && HAS_IOMEM [=y] && OF_MDIO [=n]
        Selected by [y]:
        - OCTEON_ETHERNET [=y] && STAGING [=y] && (CAVIUM_OCTEON_SOC ||
      COMPILE_TEST [=y]) && NETDEVICES [=y]
      
      In file included from ../drivers/net/phy/mdio-octeon.c:14:
      ../drivers/net/phy/mdio-cavium.h:111:36: error: implicit declaration of
      function ‘writeq’; did you mean ‘writel’?
      [-Werror=implicit-function-declaration]
        111 | #define oct_mdio_writeq(val, addr) writeq(val, (void *)addr)
            |                                    ^~~~~~
      
      CONFIG_64BIT is not strictly necessary if the proper readq/writeq
      definitions are included from io-64-nonatomic-lo-hi.h.
      
      CONFIG_OF_MDIO is not needed when CONFIG_COMPILE_TEST is enabled because
      of commit f9dc9ac5 ("of/mdio: Add dummy functions in of_mdio.h.").
      
      Fixes: 171a9bae ("staging/octeon: Allow test build on !MIPS")
      Reported-by: default avatarkbuild test robot <lkp@intel.com>
      Reported-by: default avatarMark Brown <broonie@kernel.org>
      Reported-by: default avatarRandy Dunlap <rdunlap@infradead.org>
      Signed-off-by: default avatarNathan Chancellor <natechancellor@gmail.com>
      Acked-by: Randy Dunlap <rdunlap@infradead.org> # build-tested
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b8fb6406
    • Vivien Didelot's avatar
      net: dsa: dump CPU port regs through master · 48e23311
      Vivien Didelot authored
      Merge the CPU port registers dump into the master interface registers
      dump through ethtool, by nesting the ethtool_drvinfo and ethtool_regs
      structures of the CPU port into the dump.
      
      drvinfo->regdump_len will contain the full data length, while regs->len
      will contain only the master interface registers dump length.
      
      This allows for example to dump the CPU port registers on a ZII Dev
      C board like this:
      
          # ethtool -d eth1
          0x004:                                              0x00000000
          0x008:                                              0x0a8000aa
          0x010:                                              0x01000000
          0x014:                                              0x00000000
          0x024:                                              0xf0000102
          0x040:                                              0x6d82c800
          0x044:                                              0x00000020
          0x064:                                              0x40000000
          0x084: RCR (Receive Control Register)               0x47c00104
              MAX_FL (Maximum frame length)                   1984
              FCE (Flow control enable)                       0
              BC_REJ (Broadcast frame reject)                 0
              PROM (Promiscuous mode)                         0
              DRT (Disable receive on transmit)               0
              LOOP (Internal loopback)                        0
          0x0c4: TCR (Transmit Control Register)              0x00000004
              RFC_PAUSE (Receive frame control pause)         0
              TFC_PAUSE (Transmit frame control pause)        0
              FDEN (Full duplex enable)                       1
              HBC (Heartbeat control)                         0
              GTS (Graceful transmit stop)                    0
          0x0e4:                                              0x76735d6d
          0x0e8:                                              0x7e9e8808
          0x0ec:                                              0x00010000
          .
          .
          .
          88E6352  Switch Port Registers
          ------------------------------
          00: Port Status                            0x4d04
                Pause Enabled                        0
                My Pause                             1
                802.3 PHY Detected                   0
                Link Status                          Up
                Duplex                               Full
                Speed                                100 or 200 Mbps
                EEE Enabled                          0
                Transmitter Paused                   0
                Flow Control                         0
                Config Mode                          0x4
          01: Physical Control                       0x003d
                RGMII Receive Timing Control         Default
                RGMII Transmit Timing Control        Default
                200 BASE Mode                        100
                Flow Control's Forced value          0
                Force Flow Control                   0
                Link's Forced value                  Up
                Force Link                           1
                Duplex's Forced value                Full
                Force Duplex                         1
                Force Speed                          100 or 200 Mbps
          .
          .
          .
      Signed-off-by: default avatarVivien Didelot <vivien.didelot@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      48e23311
    • David S. Miller's avatar
      Merge branch 'drop_monitor-Various-improvements-and-cleanups' · c4ed5253
      David S. Miller authored
      Ido Schimmel says:
      
      ====================
      drop_monitor: Various improvements and cleanups
      
      This patchset performs various improvements and cleanups in drop monitor
      with no functional changes intended. There are no changes in these
      patches relative to the RFC I sent two weeks ago [1].
      
      A followup patchset will extend drop monitor with a packet alert mode in
      which the dropped packet is notified to user space instead of just a
      summary of recent drops. Subsequent patchsets will add the ability to
      monitor hardware originated drops via drop monitor.
      
      [1] https://patchwork.ozlabs.org/cover/1135226/
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c4ed5253
    • Ido Schimmel's avatar
      drop_monitor: Use pre_doit / post_doit hooks · b19d9550
      Ido Schimmel authored
      Each operation from user space should be protected by the global drop
      monitor mutex. Use the pre_doit / post_doit hooks to take / release the
      lock instead of doing it explicitly in each function.
      Signed-off-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      b19d9550
    • Ido Schimmel's avatar
      drop_monitor: Add extack support · 96510096
      Ido Schimmel authored
      Add various extack messages to make drop_monitor more user friendly.
      Signed-off-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      96510096
    • Ido Schimmel's avatar
      drop_monitor: Avoid multiple blank lines · ff3818ca
      Ido Schimmel authored
      Remove multiple blank lines which are visually annoying and useless.
      
      This suppresses the "Please don't use multiple blank lines" checkpatch
      messages.
      Signed-off-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ff3818ca
    • Ido Schimmel's avatar
      drop_monitor: Document scope of spinlock · 01921d53
      Ido Schimmel authored
      While 'per_cpu_dm_data' is a per-CPU variable, its 'skb' and
      'send_timer' fields can be accessed concurrently by the CPU sending the
      netlink notification to user space from the workqueue and the CPU
      tracing kfree_skb(). This spinlock is meant to protect against that.
      
      Document its scope and suppress the checkpatch message "spinlock_t
      definition without comment".
      Signed-off-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      01921d53
    • Ido Schimmel's avatar
      drop_monitor: Rename and document scope of mutex · dbf896b7
      Ido Schimmel authored
      The 'trace_state_mutex' does not only protect the global 'trace_state'
      variable, but also the global 'hw_stats_list'.
      
      Subsequent patches are going add more operations from user space to
      drop_monitor and these all need to be mutually exclusive.
      
      Rename 'trace_state_mutex' to the more fitting 'net_dm_mutex' name and
      document its scope.
      Signed-off-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      dbf896b7
    • Ido Schimmel's avatar
      drop_monitor: Use correct error code · 2230a7ef
      Ido Schimmel authored
      The error code 'ENOTSUPP' is reserved for use with NFS. Use 'EOPNOTSUPP'
      instead.
      Signed-off-by: default avatarIdo Schimmel <idosch@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      2230a7ef
    • Marek Vasut's avatar
      net: dsa: ksz: Drop NET_DSA_TAG_KSZ9477 · 267df70f
      Marek Vasut authored
      This Kconfig option is unused, drop it.
      Signed-off-by: default avatarMarek Vasut <marex@denx.de>
      Cc: Andrew Lunn <andrew@lunn.ch>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Florian Fainelli <f.fainelli@gmail.com>
      Cc: Tristram Ha <Tristram.Ha@microchip.com>
      Cc: Vivien Didelot <vivien.didelot@gmail.com>
      Cc: Woojung Huh <woojung.huh@microchip.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      267df70f
    • Marek Vasut's avatar
      net: dsa: ksz: Merge ksz_priv.h into ksz_common.h · 6a7abc61
      Marek Vasut authored
      Merge the two headers into one, no functional change.
      Signed-off-by: default avatarMarek Vasut <marex@denx.de>
      Cc: Andrew Lunn <andrew@lunn.ch>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Florian Fainelli <f.fainelli@gmail.com>
      Cc: Tristram Ha <Tristram.Ha@microchip.com>
      Cc: Vivien Didelot <vivien.didelot@gmail.com>
      Cc: Woojung Huh <woojung.huh@microchip.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6a7abc61
    • Marek Vasut's avatar
      net: dsa: ksz: Remove dead code and fix warnings · ffc60b55
      Marek Vasut authored
      Remove ksz_port_cleanup(), which is unused. Add missing include
      "ksz_common.h", which fixes the following warning when built with
      make ... W=1
      
      drivers/net/dsa/microchip/ksz_common.c:23:6: warning: no previous prototype for ‘...’ [-Wmissing-prototypes]
      
      Note that the order of the headers cannot be swapped, as that would
      trigger missing forward declaration errors, which would indicate the
      way forward is to merge the two headers into one.
      Signed-off-by: default avatarMarek Vasut <marex@denx.de>
      Cc: Andrew Lunn <andrew@lunn.ch>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Florian Fainelli <f.fainelli@gmail.com>
      Cc: Tristram Ha <Tristram.Ha@microchip.com>
      Cc: Vivien Didelot <vivien.didelot@gmail.com>
      Cc: Woojung Huh <woojung.huh@microchip.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      ffc60b55
  2. 05 Aug, 2019 4 commits
  3. 03 Aug, 2019 23 commits