1. 13 1月, 2014 1 次提交
    • G
      powerpc/mpc512x: improve DIU related clock setup · ba218127
      Gerhard Sittig 提交于
      adapt the DIU clock initialization to the COMMON_CLK approach:
      device tree based clock lookup, prepare and unprepare for clocks,
      work with frequencies not dividers, call the appropriate clk_*()
      routines and don't access CCM registers
      
      the "best clock" determination now completely relies on the
      platform's clock driver to pick a frequency close to what the
      caller requests, and merely checks whether the desired frequency
      was met (fits the tolerance of the monitor)
      
      this approach shall succeed upon first try in the usual case,
      will test a few less desirable yet acceptable frequencies in
      edge cases, and will fallback to "best effort" if none of the
      previously tried frequencies pass the test
      
      provide a fallback clock lookup approach in case the OF based clock
      lookup for the DIU fails, this allows for successful operation in
      the presence of an outdated device tree which lacks clock specs
      
      Cc: Anatolij Gustschin <agust@denx.de>
      Cc: linuxppc-dev@lists.ozlabs.org
      Signed-off-by: NGerhard Sittig <gsi@denx.de>
      Signed-off-by: NAnatolij Gustschin <agust@denx.de>
      ba218127
  2. 31 10月, 2013 2 次提交
    • B
      powerpc/mpc512x: remove unnecessary #if · 7e198197
      Brian Norris 提交于
      Several functions are only ever referenced locally, so make them static.
      Of those functions, many of them are protected by an #if. However, the
      code which can compile fine in either case.
      
      Now that (1) the unneeded code is marked 'static' and (2) the code is
      only used under a C 'if (IS_ENABLED(CONFIG_FB_FSL_DIU))', the compiler
      can automatically remove the unneeded code, and we don't need the #if or
      the empty stub functions.
      Signed-off-by: NBrian Norris <computersforpeace@gmail.com>
      Signed-off-by: NAnatolij Gustschin <agust@denx.de>
      7e198197
    • G
      powerpc/mpc512x: silence build warning upon disabled DIU · 45d20e83
      Gerhard Sittig 提交于
      a disabled Kconfig option results in a reference to a not implemented
      routine when the IS_ENABLED() macro is used for both conditional
      implementation of the routine as well as a C language source code test
      at the call site -- the "if (0) func();" construct only gets eliminated
      later by the optimizer, while the compiler already has emitted its
      warning about "func()" being undeclared
      
      provide an empty implementation for the mpc512x_setup_diu() and
      mpc512x_init_diu() routines in case of the disabled option, to avoid the
      compiler warning which is considered fatal and breaks compilation
      
      the bug appeared with commit 2abbbb63
      "powerpc/mpc512x: move common code to shared.c file", how to reproduce:
      
        make mpc512x_defconfig
        echo CONFIG_FB_FSL_DIU=n >> .config && make olddefconfig
        make
      
          CC      arch/powerpc/platforms/512x/mpc512x_shared.o
        .../arch/powerpc/platforms/512x/mpc512x_shared.c: In function 'mpc512x_init_early':
        .../arch/powerpc/platforms/512x/mpc512x_shared.c:456:3: error: implicit declaration of function 'mpc512x_init_diu' [-Werror=implicit-function-declaration]
        .../arch/powerpc/platforms/512x/mpc512x_shared.c: In function 'mpc512x_setup_arch':
        .../arch/powerpc/platforms/512x/mpc512x_shared.c:469:3: error: implicit declaration of function 'mpc512x_setup_diu' [-Werror=implicit-function-declaration]
        cc1: all warnings being treated as errors
        make[4]: *** [arch/powerpc/platforms/512x/mpc512x_shared.o] Error 1
      Signed-off-by: NGerhard Sittig <gsi@denx.de>
      CC: <stable@vger.kernel.org> # v3.11
      Signed-off-by: NAnatolij Gustschin <agust@denx.de>
      45d20e83
  3. 25 6月, 2013 1 次提交
  4. 21 5月, 2013 2 次提交
    • G
      powerpc/mpc512x: initialize board restart earlier · a4f4124c
      Gerhard Sittig 提交于
      move the MPC512x restart initialization from the shared init routine
      to the shared init_early routine
      
      recent problems in the proc(5) filesystem initialization led to the
      situation where the platform's restart routine was invoked yet the
      registers required for software reset were not yet available, which
      made the board hang instead of reboot
      Signed-off-by: NGerhard Sittig <gsi@denx.de>
      Signed-off-by: NAnatolij Gustschin <agust@denx.de>
      a4f4124c
    • G
      powerpc/mpc512x: move common code to shared.c file · 2abbbb63
      Gerhard Sittig 提交于
      - implement all of the init, init early, and setup arch routines in the
        shared source file for the MPC512x PowerPC platform, and make all
        MPC512x based boards (ADS, PDM, generic) use those common routines
      - remove declarations from header files for routines which aren't
        referenced from external callers any longer
      
      this modification concentrates knowledge about the optional FSL DIU
      support in one spot within the shared code, and makes all boards benefit
      transparently from future improvements in the shared platform code
      
      the change does not modify any behaviour but preserves all code paths
      Signed-off-by: NGerhard Sittig <gsi@denx.de>
      Signed-off-by: NAnatolij Gustschin <agust@denx.de>
      2abbbb63
  5. 30 4月, 2013 1 次提交
  6. 11 4月, 2013 1 次提交
  7. 01 4月, 2013 1 次提交
  8. 16 2月, 2013 1 次提交
  9. 05 2月, 2013 1 次提交
  10. 29 1月, 2013 1 次提交
  11. 04 12月, 2012 1 次提交
  12. 10 9月, 2012 1 次提交
    • P
      powerpc: Option FB_FSL_DIU is not really optional for mpc512x · 12e36309
      Paul Gortmaker 提交于
      In powerpc randconfig builds, this keeps showing up:
      
        CC      arch/powerpc/platforms/512x/mpc512x_shared.o
      arch/powerpc/platforms/512x/mpc512x_shared.c:70:9: warning: 'enum fsl_diu_monitor_port' declared inside parameter list
      arch/powerpc/platforms/512x/mpc512x_shared.c:70:9: warning: its scope is only this definition or declaration, which is probably not what you want
      arch/powerpc/platforms/512x/mpc512x_shared.c:69:56: error: parameter 1 ('port') has incomplete type
      arch/powerpc/platforms/512x/mpc512x_shared.c:69:5: warning: function declaration isn't a prototype
      arch/powerpc/platforms/512x/mpc512x_shared.c:84:9: warning: 'enum fsl_diu_monitor_port' declared inside parameter list
      arch/powerpc/platforms/512x/mpc512x_shared.c:83:56: error: parameter 1 ('port') has incomplete type
      arch/powerpc/platforms/512x/mpc512x_shared.c:83:6: warning: function declaration isn't a prototype
      arch/powerpc/platforms/512x/mpc512x_shared.c:88:36: warning: 'enum fsl_diu_monitor_port' declared inside parameter list
      arch/powerpc/platforms/512x/mpc512x_shared.c:88:57: error: parameter 1 ('port') has incomplete type
      arch/powerpc/platforms/512x/mpc512x_shared.c:88:6: warning: function declaration isn't a prototype
      arch/powerpc/platforms/512x/mpc512x_shared.c:187:54: error: parameter 1 ('port') has incomplete type
      arch/powerpc/platforms/512x/mpc512x_shared.c:187:1: error: return type is an incomplete type
      arch/powerpc/platforms/512x/mpc512x_shared.c:187:1: warning: function declaration isn't a prototype
      arch/powerpc/platforms/512x/mpc512x_shared.c: In function 'mpc512x_valid_monitor_port':
      arch/powerpc/platforms/512x/mpc512x_shared.c:189:9: error: 'FSL_DIU_PORT_DVI' undeclared (first use in this function)
      arch/powerpc/platforms/512x/mpc512x_shared.c:189:9: note: each undeclared identifier is reported only once for each function it appears in
      arch/powerpc/platforms/512x/mpc512x_shared.c:189:2: warning: 'return' with a value, in function returning void
      make[2]: *** [arch/powerpc/platforms/512x/mpc512x_shared.o] Error 1
      
      The reason is that mpc512x_shared.c has a couple token #ifdef
      on FB_FSL_DIU/FB_FSL_DIU_MODULE, but they don't come close to
      masking all the DIU dependencies, as the above fail shows.
      
      Rather than sprinkle more pointless #ifdef in this file, just
      remove the existing two, and make FB_FSL_DIU part of the
      dependency.  The mpc512x_defconfig already has the line
      "CONFIG_FB_FSL_DIU=y" so this change should be zero impact
      on real world configs.
      Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com>
      Signed-off-by: NAnatolij Gustschin <agust@denx.de>
      12e36309
  13. 05 10月, 2011 1 次提交
  14. 13 7月, 2011 1 次提交
  15. 02 8月, 2010 1 次提交
  16. 25 5月, 2010 1 次提交
  17. 17 2月, 2010 3 次提交
  18. 17 6月, 2009 1 次提交
  19. 13 7月, 2008 1 次提交
  20. 07 2月, 2008 1 次提交