1. 13 Oct, 2018 1 commit
  2. 12 Oct, 2018 35 commits
  3. 11 Oct, 2018 4 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
    • Peter Oberparleiter's avatar
      vmlinux.lds.h: Fix linker warnings about orphan .LPBX sections · 52c8ee5b
      Peter Oberparleiter authored
      Enabling both CONFIG_LD_DEAD_CODE_DATA_ELIMINATION=y and
      CONFIG_GCOV_PROFILE_ALL=y results in linker warnings:
      
        warning: orphan section `.data..LPBX1' being placed in
        section `.data..LPBX1'.
      
      LD_DEAD_CODE_DATA_ELIMINATION adds compiler flag -fdata-sections. This
      option causes GCC to create separate data sections for data objects,
      including those generated by GCC internally for gcov profiling. The
      names of these objects start with a dot (.LPBX0, .LPBX1), resulting in
      section names starting with 'data..'.
      
      As section names starting with 'data..' are used for specific purposes
      in the Linux kernel, the linker script does not automatically include
      them in the output data section, resulting in the "orphan section"
      linker warnings.
      
      Fix this by specifically including sections named "data..LPBX*" in the
      data section.
      Reported-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
      Tested-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
      Tested-by: default avatarArnd Bergmann <arnd@arndb.de>
      Acked-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarPeter Oberparleiter <oberpar@linux.ibm.com>
      Signed-off-by: default avatarStephen Rothwell <sfr@canb.auug.org.au>
      52c8ee5b