1. 13 Oct, 2018 2 commits
  2. 12 Oct, 2018 35 commits
  3. 11 Oct, 2018 3 commits
    • David S. Miller's avatar
      Merge branch 'net-dsa-bcm_sf2-Couple-of-fixes' · 6b9bab55
      David S. Miller authored
      Florian Fainelli says:
      
      ====================
      net: dsa: bcm_sf2: Couple of fixes
      
      Here are two fixes for the bcm_sf2 driver that were found during
      testing unbind and analysing another issue during system
      suspend/resume.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6b9bab55
    • Florian Fainelli's avatar
      net: dsa: bcm_sf2: Call setup during switch resume · 54baca09
      Florian Fainelli authored
      There is no reason to open code what the switch setup function does, in
      fact, because we just issued a switch reset, we would make all the
      register get their default values, including for instance, having unused
      port be enabled again and wasting power and leading to an inappropriate
      switch core clock being selected.
      
      Fixes: 8cfa9498 ("net: dsa: bcm_sf2: add suspend/resume callbacks")
      Signed-off-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      54baca09
    • Florian Fainelli's avatar
      net: dsa: bcm_sf2: Fix unbind ordering · bf3b452b
      Florian Fainelli authored
      The order in which we release resources is unfortunately leading to bus
      errors while dismantling the port. This is because we set
      priv->wol_ports_mask to 0 to tell bcm_sf2_sw_suspend() that it is now
      permissible to clock gate the switch. Later on, when dsa_slave_destroy()
      comes in from dsa_unregister_switch() and calls
      dsa_switch_ops::port_disable, we perform the same dismantling again, and
      this time we hit registers that are clock gated.
      
      Make sure that dsa_unregister_switch() is the first thing that happens,
      which takes care of releasing all user visible resources, then proceed
      with clock gating hardware. We still need to set priv->wol_ports_mask to
      0 to make sure that an enabled port properly gets disabled in case it
      was previously used as part of Wake-on-LAN.
      
      Fixes: d9338023 ("net: dsa: bcm_sf2: Make it a real platform device driver")
      Signed-off-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      bf3b452b