1. 14 2月, 2019 1 次提交
  2. 16 1月, 2019 1 次提交
  3. 19 12月, 2018 2 次提交
    • H
      net: phy: print stack trace in phy_error · fa7b28c1
      Heiner Kallweit 提交于
      So far phy_error() silently stops the PHY state machine. If the network
      driver doesn't inform about a  MDIO error then the user may wonder why
      his network is down. Let's print the stack trace to facilitate search
      for the root cause of the error.
      Signed-off-by: NHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      fa7b28c1
    • H
      net: phy: improve phy state checking · 2b3e88ea
      Heiner Kallweit 提交于
      Add helpers phy_is_started() and __phy_is_started() to avoid open-coded
      checks whether PHY has been started. To make the check easier move
      PHY_HALTED before PHY_UP in enum phy_state. Further improvements:
      
      phy_start_aneg():
      Return -EBUSY and print warning if function is called from a non-started
      state (DOWN, READY, HALTED). Better check because function is exported
      and drivers may use it incorrectly.
      
      phy_interrupt():
      Return IRQ_NONE also if state is DOWN or READY. We should never receive
      an interrupt in one of these states, but better play safe.
      
      phy_stop():
      Just return and print a warning if PHY is in a non-started state.
      This warning should help to identify drivers with unbalanced calls to
      phy_start() / phy_stop().
      
      phy_state_machine():
      Schedule state machine run only if PHY is in a started state.
      E.g. if state is READY we don't need the state machine, it will be
      started by phy_start().
      
      v2:
      - don't use __func__ within phy_warn_state
      v3:
      - use WARN() instead of printing error message to facilitate debugging
      Signed-off-by: NHeiner Kallweit <hkallweit1@gmail.com>
      Reviewed-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2b3e88ea
  4. 06 12月, 2018 1 次提交
  5. 04 12月, 2018 1 次提交
    • H
      net: phy: improve generic EEE ethtool functions · d1420bb9
      Heiner Kallweit 提交于
      So far the two functions consider neither member eee_enabled nor
      eee_active. Therefore network drivers have to do this in some kind
      of glue code. I think this can be avoided.
      
      Getting EEE parameters:
      When not advertising any EEE mode, we can't consider EEE to be enabled.
      Therefore interpret "EEE enabled" as "we advertise at least one EEE
      mode". It's similar with "EEE active": interpret it as "EEE modes
      advertised by both link partner have at least one mode in common".
      
      Setting EEE parameters:
      If eee_enabled isn't set, don't advertise any EEE mode and restart
      aneg if needed to switch off EEE. If eee_enabled is set and
      data->advertised is empty (e.g. because EEE was disabled), advertise
      everything we support as default. This way EEE can easily switched
      on/off by doing ethtool --set-eee <if> eee on/off, w/o any additional
      parameters.
      
      The changes to both functions shouldn't break any existing user.
      Once the changes have been applied, at least some users can be
      simplified.
      Signed-off-by: NHeiner Kallweit <hkallweit1@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d1420bb9
  6. 13 11月, 2018 1 次提交
  7. 12 11月, 2018 6 次提交
  8. 10 11月, 2018 1 次提交
  9. 09 11月, 2018 5 次提交
  10. 08 11月, 2018 1 次提交
  11. 16 10月, 2018 4 次提交
  12. 02 10月, 2018 1 次提交
  13. 22 9月, 2018 1 次提交
  14. 20 9月, 2018 1 次提交
  15. 26 7月, 2018 2 次提交
  16. 22 7月, 2018 1 次提交
  17. 17 7月, 2018 2 次提交
  18. 03 6月, 2018 1 次提交
  19. 29 4月, 2018 1 次提交
    • F
      net: phy: Fix modular PHYLIB build · 9e8d438e
      Florian Fainelli 提交于
      After commit c59530d0 ("net: Move PHY statistics code into PHY
      library helpers") we made net/core/ethtool.c reference symbols which are
      part of the library which can be modular. David introduced a temporary
      fix with 1ecd6e8a ("phy: Temporary build fix after phylib changes.")
      which would prevent such modularity.
      
      This is not desireable of course, so instead, just inline the functions
      into include/linux/phy.h to keep both options available.
      
      Fixes: c59530d0 ("net: Move PHY statistics code into PHY library helpers")
      Fixes: 1ecd6e8a ("phy: Temporary build fix after phylib changes.")
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9e8d438e
  20. 27 4月, 2018 1 次提交
  21. 12 3月, 2018 1 次提交
    • B
      net: phy: Tell caller result of phy_change() · a2c054a8
      Brad Mouring 提交于
      In 664fcf12 (net: phy: Threaded interrupts allow some simplification)
      the phy_interrupt system was changed to use a traditional threaded
      interrupt scheme instead of a workqueue approach.
      
      With this change, the phy status check moved into phy_change, which
      did not report back to the caller whether or not the interrupt was
      handled. This means that, in the case of a shared phy interrupt,
      only the first phydev's interrupt registers are checked (since
      phy_interrupt() would always return IRQ_HANDLED). This leads to
      interrupt storms when it is a secondary device that's actually the
      interrupt source.
      Signed-off-by: NBrad Mouring <brad.mouring@ni.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      a2c054a8
  22. 08 3月, 2018 2 次提交
  23. 28 2月, 2018 1 次提交
  24. 09 2月, 2018 1 次提交