1. 22 11月, 2014 2 次提交
  2. 17 11月, 2014 2 次提交
  3. 13 11月, 2014 1 次提交
  4. 12 11月, 2014 2 次提交
    • F
      net: bcmgenet: apply MII configuration in bcmgenet_open() · dbd479db
      Florian Fainelli 提交于
      In case an interface has been brought down before entering S3, and then
      brought up out of S3, all the initialization done during
      bcmgenet_probe() by bcmgenet_mii_init() calling bcmgenet_mii_config() is
      just lost since register contents are restored to their reset values.
      
      Re-apply this configuration anytime we call bcmgenet_open() to make sure
      our port multiplexer is properly configured to match the PHY interface.
      
      Since we are now calling bcmgenet_mii_config() everytime bcmgenet_open()
      is called, make sure we only print the message during initialization
      time not to pollute the console.
      
      Fixes: b6e978e5 ("net: bcmgenet: add suspend/resume callbacks")
      Fixes: 1c1008c7 ("net: bcmgenet: add main driver file")
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      dbd479db
    • F
      net: bcmgenet: connect and disconnect from the PHY state machine · c96e731c
      Florian Fainelli 提交于
      phy_disconnect() is the only way to guarantee that we are not going to
      schedule more work on the PHY state machine workqueue for that
      particular PHY device.
      
      This fixes an issue where a network interface was suspended prior to a
      system suspend/resume cycle and would then be resumed as part of
      mdio_bus_resume(), since the GENET interface clocks would have been
      disabled, this basically resulted in bus errors to appear since we are
      invoking the GENET driver adjust_link() callback.
      
      Fixes: b6e978e5 ("net: bcmgenet: add suspend/resume callbacks")
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c96e731c
  5. 02 11月, 2014 2 次提交
  6. 31 10月, 2014 1 次提交
  7. 30 10月, 2014 1 次提交
  8. 29 10月, 2014 2 次提交
    • F
      net: systemport: reset UniMAC coming out of a suspend cycle · 704d33e7
      Florian Fainelli 提交于
      bcm_sysport_resume() was missing an UniMAC reset which can lead to
      various receive FIFO corruptions coming out of a suspend cycle. If the
      RX FIFO is stuck, it will deliver corrupted/duplicate packets towards
      the host CPU interface.
      
      This could be reproduced on crowded network and when Wake-on-LAN is
      enabled for this particular interface because the switch still forwards
      packets towards the host CPU interface (SYSTEMPORT), and we had to leave
      the UniMAC RX enable bit on to allow matching MagicPackets.
      
      Once we re-enter the resume function, there is a small window during
      which the UniMAC receive is still enabled, and we start queueing
      packets, but the RDMA and RBUF engines are not ready, which leads to
      having packets stuck in the UniMAC RX FIFO, ultimately delivered towards
      the host CPU as corrupted.
      
      Fixes: 40755a0f ("net: systemport: add suspend and resume support")
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      704d33e7
    • F
      net: systemport: enable RX interrupts after NAPI · 8edf0047
      Florian Fainelli 提交于
      There is currently a small window during which the SYSTEMPORT adapter
      enables its RX interrupts without having enabled its NAPI handler, which
      can result in packets to be discarded during interface bringup.
      
      A similar but more serious window exists in bcm_sysport_resume() during
      which we can have the RDMA engine not fully prepared to receive packets
      and yet having RX interrupts enabled.
      
      Fix this my moving the RX interrupt enable down to
      bcm_sysport_netif_start() after napi_enable() for the RX path is called,
      which fixes both call sites: bcm_sysport_open() and
      bcm_sysport_resume().
      
      Fixes: b02e6d9b ("net: systemport: add bcm_sysport_netif_{enable,stop}")
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      8edf0047
  9. 15 10月, 2014 1 次提交
  10. 11 10月, 2014 3 次提交
  11. 08 10月, 2014 1 次提交
  12. 06 10月, 2014 1 次提交
  13. 05 10月, 2014 1 次提交
  14. 02 10月, 2014 3 次提交
  15. 27 9月, 2014 1 次提交
  16. 23 9月, 2014 3 次提交
  17. 20 9月, 2014 5 次提交
  18. 13 9月, 2014 1 次提交
  19. 10 9月, 2014 1 次提交
  20. 09 9月, 2014 2 次提交
    • F
      net: bcmgenet: check harder for out of memory conditions · b629be5c
      Florian Fainelli 提交于
      There is a potential case where we might be failing to refill a
      control block, leaving it with both a NULL skb pointer *and* a NULL
      dma_unmap_addr.
      
      The way we process incoming packets, by first calling
      dma_unmap_single(), and then only checking for a potential NULL skb can
      lead to situations where do pass a NULL dma_unmap_addr() to
      dma_unmap_single(), resulting in an oops.
      
      Fix this my moving the NULL skb check earlier, since no backing skb
      also means no corresponding DMA mapping for this packet.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b629be5c
    • F
      net: systemport: check harder for out of memory conditions · fe24ba08
      Florian Fainelli 提交于
      There is a potential case where we might be failing to refill a
      control block, leaving it with both a NULL skb pointer *and* a NULL
      dma_unmap_addr.
      
      The way we process incoming packets, by first calling
      dma_unmap_single(), and then only checking for a potential NULL skb can
      lead to situations where do pass a NULL dma_unmap_addr() to
      dma_unmap_single(), resulting in an oops.
      
      Fix this my moving the NULL skb check earlier, since no backing skb
      also means no corresponding DMA mapping for this packet.
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      fe24ba08
  21. 06 9月, 2014 2 次提交
  22. 05 9月, 2014 1 次提交
    • F
      net: systemport: update UMAC_CMD only when link is detected · 4a804c01
      Florian Fainelli 提交于
      When we bring the interface down, phy_stop() will schedule the PHY
      state machine to call our link adjustment callback. By the time we do so,
      we may have clock gated off the SYSTEMPORT hardware block, and this will
      cause bus errors to happen in bcm_sysport_adj_link():
      
      Make sure that we only touch the UMAC_CMD register when there is an
      actual link. This is safe to do for two reasons:
      
      - updating the Ethernet MAC registers only make sense when a physical
        link is present
      - the PHY library state machine first set phydev->link = 0 before
        invoking phydev->adjust_link in the PHY_HALTED case
      
      This is a similar fix to the GENET one:
      c677ba8b ("net: bcmgenet: update
      UMAC_CMD only when link is detected").
      
      Fixes: 80105bef ("net: systemport: add Broadcom SYSTEMPORT Ethernet MAC driver")
      Signed-off-by: NFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4a804c01
  23. 03 9月, 2014 1 次提交