1. 12 9月, 2012 1 次提交
    • V
      ARM: OMAP3+: hwmod: Add AM33XX HWMOD data · a2cfc509
      Vaibhav Hiremath 提交于
      This patch adds HWMOD data for all the peripherals of
      AM335X device and also hooks up to the existing OMAP framework.
      
      hwmod data has been already been cleaned up for the recent
      changes in clocktree, where all leaf nodes have been removed,
      since with modulemode based control, both clock and hwmod
      interface does same thing. This reduces the code size to large
      extent and also avoids duplication of same control.
      So instead of specifying module's leaf node as a main_clk,
      now we are relying on parent clock of module's functional clock.
      Signed-off-by: NVaibhav Hiremath <hvaibhav@ti.com>
      Signed-off-by: NAfzal Mohammed <afzal@ti.com>
      Signed-off-by: NVaibhav Bedia <vaibhav.bedia@ti.com>
      Cc: Paul Walmsley <paul@pwsan.com>
      Cc: Benoit Cousson <b-cousson@ti.com>
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: Kevin Hilman <khilman@ti.com>
      Cc: Rajendra Nayak <rnayak@ti.com>
      [paul@pwsan.com: removed period in hwmod device names; changed mmc2 main_clk
       to mmc_clk at Vaibhav's request; added trailing commas to structure
       records at Tony's request to deal with some rmk parsing issues; added
       OMAP_INTC_START to facilitate sparse-IRQ conversion]
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      a2cfc509
  2. 09 7月, 2012 1 次提交
  3. 30 6月, 2012 1 次提交
    • V
      ARM: OMAP3+: clock33xx: Add AM33XX clock tree data · e30384ab
      Vaibhav Hiremath 提交于
      AM33XX clock implementation is different than any existing OMAP
      family of devices. Although DPLL module is similar to OMAP4
      device, but the usage is very much different than OMAP4.
      AM33XX has different peripheral set and each module gets
      integrated to the clock framework differently than OMAP
      family of devices.
      
      This patch adds full Clock tree data for AM33XX family
      of devices and also integrates it into existing OMAP framework.
      Signed-off-by: NVaibhav Hiremath <hvaibhav@ti.com>
      Signed-off-by: NAfzal Mohammed <afzal@ti.com>
      Signed-off-by: NVaibhav Bedia <vaibhav.bedia@ti.com>
      Cc: Kevin Hilman <khilman@ti.com>
      Cc: Rajendra Nayak <rnayak@ti.com>
      CC: Tony Lindgren <tony@atomide.com>
      Cc: Paul Walmsley <paul@pwsan.com>
      Cc: Benoit Cousson <b-cousson@ti.com>
      [paul@pwsan.com: updated to apply; changed 'soc_is_am33xx' to
       'cpu_is_am33xx' to match usage in Tony's current am33xx branch]
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      e30384ab
  4. 19 6月, 2012 2 次提交
    • V
      ARM: OMAP AM33xx: clockdomains: Add clockdomain data and respective operations · 9c80f3aa
      Vaibhav Hiremath 提交于
      AM33XX PRCM module consists of various clockdomains, in all
      total we have 18 clockdomains available, with following
      controlling options,
         - SW Sleep: sw forced sleep transition
         - SW Wakeup: sw forced wakeup transition
      
      This patch adds all available clockdomain data, respective
      clockdomain operations for AM33XX family of device, and also
      integrates it into existing OMAP framework.
      Signed-off-by: NVaibhav Hiremath <hvaibhav@ti.com>
      Signed-off-by: NAfzal Mohammed <afzal@ti.com>
      Signed-off-by: NVaibhav Bedia <vaibhav.bedia@ti.com>
      Cc: Kevin Hilman <khilman@ti.com>
      Cc: Rajendra Nayak <rnayak@ti.com>
      CC: Tony Lindgren <tony@atomide.com>
      Cc: Paul Walmsley <paul@pwsan.com>
      Cc: Benoit Cousson <b-cousson@ti.com>
      [paul@pwsan.com: removed CLKDM_NO_AUTODEPS from clockdomain flags, removed
       unnecessary .clktrctrl_offs field; updated for 3.5]
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      9c80f3aa
    • V
      ARM: OMAP AM33xx: powerdomains: add AM335x support · 3f0ea764
      Vaibhav Hiremath 提交于
      Add offset & mask fields to struct powerdomain
      
      In case of AM33xx family of devices, there is no consistency between
      PWRSTCTRL & PWRSTST register offsers in PRM space, for example -
      
      PRM_XXX           PWRSTCTRL     PWRSTST
      =======================================
      PRM_PER_MOD:      0x0C,         0x08
      PRM_WKUP_MOD:     0x04,         0x08
      PRM_MPU_MOD:      0x00,         0x04
      PRM_DEVICE_MOD:   NA,           NA
      
      And also, there is no consistency between bit-offsets inside
      PWRSTCTRL & PWRSTST register, for example -
      
      PRM_XXX           LOGICRET  MEMON  MEMRET
      =======================================
      GFX_PWRCTRL:      2,        17,    6
      PER_PWRCTRL:      3,        25,    29
      MPU_PWRCTRL:      2,        18,    22
      WKUP_PWRCTRL:     3,        NA,    NA
      
      This means, we need to maintain and pass on all this information
      in powerdomain handle; so adding fields for,
         - PWRSTCTRL/ST register offset
         - Logic retention state mask
         - mem_on/ret/pwrst/retst mask
      
      Currently, this fields is only applicable and used for AM33XX devices.
      Signed-off-by: NVaibhav Hiremath <hvaibhav@ti.com>
      Cc: Benoit Cousson <b-cousson@ti.com>
      Cc: Tony Lindgren <tony@atomide.com>
      Cc: Kevin Hilman <khilman@ti.com>
      Cc: Paul Walmsley <paul@pwsan.com>
      Cc: Rajendra Nayak <rnayak@ti.com>
      [paul@pwsan.com: this patch is a combination of "Add offset & mask fields to
       struct powerdomain" and the powerdomain portions of "ARM: OMAP3+: am33xx:
       Add powerdomain & PRM support"; updated for 3.5]
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      3f0ea764
  5. 18 6月, 2012 1 次提交
  6. 05 6月, 2012 1 次提交
  7. 11 5月, 2012 2 次提交
  8. 09 5月, 2012 1 次提交
    • K
      ARM: OMAP2+: WDTIMER integration: fix !PM boot crash, disarm timer after hwmod reset · 414e4128
      Kevin Hilman 提交于
      Without runtime PM enabled, hwmod needs to leave all IP blocks in an
      enabled state by default so any driver access to the HW will succeed.
      This is accomplished by seting the postsetup_state to enabled for all
      hwmods during init when runtime PM is disabled.
      
      Currently, we have a special case for WDT in that its postsetup_state
      is always set to disabled.  This is done so that the WDT is disabled
      and the timer is disarmed at boot in case there is no WDT driver.
      This also means that when runtime PM is disabled, if a WDT driver *is*
      built in the kernel, the kernel will crash on the first access to the
      WDT hardware.
      
      We can't simply leave the WDT module enabled, because the timer is
      armed by default after reset. That means that if there is no WDT
      driver initialzed or loaded before the timer expires, the kernel will
      reboot.
      
      To fix this, a custom reset method is added to the watchdog class of
      omap_hwmod.  This method will *always* disarm the timer after hwmod
      reset.  The WDT timer then will only be rearmed when/if the driver is
      loaded for the WDT.  With the timer disarmed by default, we no longer
      need a special-case for the postsetup_state of WDT during init, so it
      is removed.
      
      Any platforms wishing to ensure the watchdog remains armed across the
      entire boot boot can simply disable the reset-on-init feature of the
      watchdog hwmod using omap_hwmod_no_setup_reset().
      
      Tested on 3530/Overo, 4430/Panda.
      
      NOTE: on 4430, the hwmod OCP reset does not seem to rearm the timer as
      documented in the TRM (and what happens on OMAP3.)  I noticed this
      because testing the HWMOD_INIT_NO_RESET feature with no driver loaded,
      I expected a reboot part way through the boot, but did not see a
      reboot.  Adding some debug to read the counter, I verified that right
      after OCP softreset, the counter is not firing.  After writing the
      magic start sequence, the timer starts counting.  This means that the
      timer disarm sequence added here does not seem to be needed for 4430,
      but is technically the correct way to ensure the timer is disarmed, so
      it is left in for OMAP4.
      
      Special thanks to Paul Walmsley for helping brainstorm ideas to fix
      this problem.
      
      Cc: Paul Walmsley <paul@pwsan.com>
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      Cc: Santosh Shilimkar <santosh.shilimkar@ti.com>
      Acked-by: NSantosh Shilimkar <santosh.shilimkar@ti.com>
      [paul@pwsan.com: updated the omap2_wd_timer_reset() function in the
       wake of commit 3c55c1ba ("ARM:
       OMAP2+: hwmod: Revert "ARM: OMAP2+: hwmod: Make omap_hwmod_softreset
       wait for reset status""); added kerneldoc; rolled in warning fix from Kevin]
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      414e4128
  9. 08 5月, 2012 2 次提交
  10. 13 4月, 2012 1 次提交
    • P
      ARM: OMAP: add includes for missing prototypes · e2ed89fc
      Paul Walmsley 提交于
      Several C files in arch/arm/mach-omap* and arch/arm/plat-omap declare
      functions that are used by other files, but don't include the header
      file where the prototype is declared.  This results in the following
      warnings from sparse:
      
          arch/arm/mach-omap2/irq.c:114:5: warning: symbol 'omap_irq_pending' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:186:13: warning: symbol 'omap2_init_irq' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:191:13: warning: symbol 'omap3_init_irq' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:196:13: warning: symbol 'ti81xx_init_irq' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:233:39: warning: symbol 'omap2_intc_handle_irq' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:242:6: warning: symbol 'omap_intc_save_context' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:265:6: warning: symbol 'omap_intc_restore_context' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:291:6: warning: symbol 'omap3_intc_suspend' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:297:6: warning: symbol 'omap3_intc_prepare_idle' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:306:6: warning: symbol 'omap3_intc_resume_idle' was not declared. Should it be static?
          arch/arm/mach-omap2/irq.c:312:39: warning: symbol 'omap3_intc_handle_irq' was not declared. Should it be static?
          arch/arm/mach-omap2/omap-secure.c:59:12: warning: symbol 'omap_secure_ram_reserve_memblock' was not declared. Should it be static?
          arch/arm/mach-omap2/board-zoom-display.c:133:13: warning: symbol 'zoom_display_init' was not declared. Should it be static?
          arch/arm/plat-omap/common.c:73:13: warning: symbol 'omap_init_consistent_dma_size' was not declared. Should it be static?
          arch/arm/mach-omap1/irq.c:61:5: warning: symbol 'omap_irq_flags' was not declared. Should it be static?
          arch/arm/mach-omap1/irq.c:179:13: warning: symbol 'omap1_init_irq' was not declared. Should it be static?
          arch/arm/mach-omap1/reset.c:11:6: warning: symbol 'omap1_restart' was not declared. Should it be static?
      
      Fix by including the appropriate header files.
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      Cc: Santosh Shilimkar <santosh.shilimkar@ti.com>
      Cc: Senthilvadivu Guruswamy <svadivu@ti.com>
      Acked-by: NSantosh Shilimkar <santosh.shilimkar@ti.com>
      
      e2ed89fc
  11. 07 3月, 2012 1 次提交
  12. 06 3月, 2012 1 次提交
  13. 25 2月, 2012 2 次提交
    • T
      ARM: OMAP2+: Limit omap_read/write usage to legacy USB drivers · acea7c7b
      Tony Lindgren 提交于
      Drivers should no longer use omap_read/write functions
      but instead use ioremap + read/write functions.
      
      As some USB legacy code is still shared between omap1 and
      omap2420, let's limit the omap_read/write to plat/usb.h.
      
      Note that the long term fix is to update the drivers to
      use ioremap and read/write functions. That can now be
      done as a separate patch series that is limited to the
      USB drivers.
      
      Also make sure the legacy omap1-keypad.c driver builds
      if selected for 2420 based systems.
      
      Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      acea7c7b
    • T
      ARM: OMAP2+: Move most of plat/io.h into local iomap.h · ee0839c2
      Tony Lindgren 提交于
      There's no need to have these defines in plat/io.h.
      
      Note that we now need to ifdef omap_read/write calls
      as they will be available for omap1 only.
      
      While at it, clean up the includes to group them like
      they typically are grouped.
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      ee0839c2
  14. 23 2月, 2012 1 次提交
  15. 15 2月, 2012 1 次提交
  16. 26 1月, 2012 1 次提交
    • P
      ARM: OMAP2+: io: fix compilation breakage on 2420-only configs · 16110798
      Paul Walmsley 提交于
      Commit 7b250aff ("ARM: OMAP: Avoid
      cpu_is_omapxxxx usage until map_io is done") breaks the build on a
      2420-only config on v3.3-rc1:
      
      arch/arm/mach-omap2/built-in.o: In function `omap2430_init_early':
      arch/arm/mach-omap2/io.c:406: undefined reference to `omap2_set_globals_243x'
      arch/arm/mach-omap2/io.c:410: undefined reference to `omap243x_clockdomains_init'
      arch/arm/mach-omap2/io.c:411: undefined reference to `omap2430_hwmod_init'
      
      Fix by only compiling omap2420_init_early() when CONFIG_SOC_OMAP2420
      is selected, and only compiling omap2430_init_early() when
      CONFIG_SOC_OMAP2430 is selected.
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      Cc: Tony Lindgren <tony@atomide.com>
      16110798
  17. 20 12月, 2011 1 次提交
  18. 14 12月, 2011 2 次提交
  19. 09 12月, 2011 1 次提交
    • S
      ARM: OMAP4: Fix errata i688 with MPU interconnect barriers. · 137d105d
      Santosh Shilimkar 提交于
      On OMAP4 SOC, intecronnects has many write buffers in the async bridges
      and they need to be drained before CPU enters into standby state.
      
      Patch 'OMAP4: PM: Add CPUX OFF mode support' added CPU PM support
      but OMAP errata i688 (Async Bridge Corruption) needs to be taken
      care to avoid issues like system freeze, CPU deadlocks, random
      crashes with register accesses, synchronisation loss on initiators
      operating on both interconnect port simultaneously.
      
      As per the errata, if a data is stalled inside asynchronous bridge
      because of back pressure, it may be accepted multiple times, creating
      pointer misalignment that will corrupt next transfers on that data
      path until next reset of the system (No recovery procedure once
      the issue is hit, the path remains consistently broken).
      Async bridge can be found on path between MPU to EMIF and
      MPU to L3 interconnect. This situation can happen only when the
      idle is initiated by a Master Request Disconnection (which is
      trigged by software when executing WFI on CPU).
      
      The work-around for this errata needs all the initiators
      connected through async bridge must ensure that data path
      is properly drained before issuing WFI. This condition will be
      met if one Strongly ordered access is performed to the
      target right before executing the WFI. In MPU case, L3 T2ASYNC
      FIFO and DDR T2ASYNC FIFO needs to be drained. IO barrier ensure
      that there is no synchronisation loss on initiators operating
      on both interconnect port simultaneously.
      
      Thanks to Russell for a tip to conver assembly function to
      C fuction there by reducing 40 odd lines of code from the patch.
      Signed-off-by: NSantosh Shilimkar <santosh.shilimkar@ti.com>
      Signed-off-by: NRichard Woodruff <r-woodruff2@ti.com>
      Acked-by: NJean Pihet <j-pihet@ti.com>
      Reviewed-by: NKevin Hilman <khilman@ti.com>
      Tested-by: NVishwanath BS <vishwanath.bs@ti.com>
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      137d105d
  20. 19 11月, 2011 1 次提交
  21. 18 11月, 2011 1 次提交
  22. 16 11月, 2011 1 次提交
  23. 05 11月, 2011 1 次提交
    • S
      ARM: OMAP: Fix errors and warnings when building for one board · c4e2d245
      Sanjeev Premi 提交于
      When customizing omap2plus_defconfig to build for only
      one board (omap3evm), I came across these warnings and
      errors (filenames truncated):
      
      arch/arm/mach-omap2/board-generic.c:76:20: warning: 'omap4_init' defined but not used
      arch/arm/mach-omap2/built-in.o: In function `omap2420_init_early':
      arch/arm/mach-omap2/io.c:364: undefined reference to `omap2_set_globals_242x'
      arch/arm/mach-omap2/io.c:366: undefined reference to `omap2xxx_voltagedomains_init'
      arch/arm/mach-omap2/io.c:367: undefined reference to `omap242x_powerdomains_init'
      arch/arm/mach-omap2/io.c:368: undefined reference to `omap242x_clockdomains_init'
      arch/arm/mach-omap2/io.c:369: undefined reference to `omap2420_hwmod_init'
      arch/arm/mach-omap2/built-in.o: In function `omap2430_init_early':
      arch/arm/mach-omap2/io.c:376: undefined reference to `omap2_set_globals_243x'
      arch/arm/mach-omap2/io.c:378: undefined reference to `omap2xxx_voltagedomains_init'
      arch/arm/mach-omap2/io.c:379: undefined reference to `omap243x_powerdomains_init'
      arch/arm/mach-omap2/io.c:380: undefined reference to `omap243x_clockdomains_init'
      arch/arm/mach-omap2/io.c:381: undefined reference to `omap2430_hwmod_init'
      arch/arm/mach-omap2/built-in.o: In function `omap4430_init_early':
      arch/arm/mach-omap2/io.c:436: undefined reference to `omap2_set_globals_443x'
      arch/arm/mach-omap2/io.c:438: undefined reference to `omap44xx_voltagedomains_init'
      arch/arm/mach-omap2/io.c:439: undefined reference to `omap44xx_powerdomains_init'
      arch/arm/mach-omap2/io.c:440: undefined reference to `omap44xx_clockdomains_init'
      arch/arm/mach-omap2/io.c:441: undefined reference to `omap44xx_hwmod_init'
      
      This patch fixes them.
      Signed-off-by: NSanjeev Premi <premi@ti.com>
      Acked-by: NThomas Weber <weber@corscience.de>
      [tony@atomide.com: updated to fix warnings for board-generic.c]
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      c4e2d245
  24. 20 10月, 2011 4 次提交
  25. 16 9月, 2011 2 次提交
    • K
      OMAP2: add voltage domains and connect to powerdomains · aae030fa
      Kevin Hilman 提交于
      Create basic voltagedomains for OMAP2 and associate OMAP2 powerdomains
      with the newly created voltage domains.
      
      While here, update copyright on powerdomain data to 2011.
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      aae030fa
    • K
      OMAP2+: voltage: start towards a new voltagedomain layer · 81a60482
      Kevin Hilman 提交于
      Start cleaning up the voltage layer to have a voltage domain layer
      that resembles the structure of the existing clock and power domain
      layers.  To that end:
      
      - move the 'struct voltagedomain' out of 'struct omap_vdd_info' to
        become the primary data structure.
      
      - convert any functions taking a pointer to struct omap_vdd_info into
        functions taking a struct voltagedomain pointer.
      
      - convert the register & initialize of voltage domains to look like
        that of powerdomains
      
      - convert omap_voltage_domain_lookup() to voltdm_lookup(), modeled
        after the current powerdomain and clockdomain lookup functions.
      
      - omap_voltage_late_init(): only configure VDD info when
        the vdd_info struct is non-NULL
      Signed-off-by: NKevin Hilman <khilman@ti.com>
      81a60482
  26. 15 9月, 2011 2 次提交
    • P
      OMAP: powerdomain: remove omap_chip bitmasks · 8179488a
      Paul Walmsley 提交于
      At Tony's request, remove the omap_chip bitmasks from the powerdomain
      definitions.  Instead, initialize powerdomains based on one or more
      lists that are applicable to a particular SoC family, variant, and
      silicon revision.
      
      Gražvydas Ignotas <notasas@gmail.com> found and reported a bug in a
      related patch that also applied to this patch - thanks Gražvydas.
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      Cc: Gražvydas Ignotas <notasas@gmail.com>
      8179488a
    • P
      OMAP: clockdomain code/data: remove omap_chip bitmask from struct clockdomain · a5ffef6a
      Paul Walmsley 提交于
      At Tony's request, remove the omap_chip bitmasks from the clockdomain
      and clockdomain dependency definitions.  Instead, initialize
      clockdomains based on one or more lists that are applicable to a
      particular SoC family, variant, and silicon revision.
      
      Tony Lindgren <tony@atomide.com> found a bug in a previous version of this
      patch - thanks Tony.
      Signed-off-by: NPaul Walmsley <paul@pwsan.com>
      Cc: Tony Lindgren <tony@atomide.com>
      a5ffef6a
  27. 24 8月, 2011 2 次提交
    • T
      ARM: OMAP: Introduce SoC specific early_init · 8f5b5a41
      Tony Lindgren 提交于
      Introduce them for each omap variant and just make them all call
      omap2_init_common_infrastructure for now. Do this for each board-*.c
      file except for board-generic and board-omap3beagle as they use
      the same machine ID for multiple SoCs.
      
      No functional changes.
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      8f5b5a41
    • T
      ARM: OMAP: Move omap2_init_common_devices out of init_early · a4ca9dbe
      Tony Lindgren 提交于
      There's no need to call omap2_init_common_devices from init_early.
      
      It no longer does anything else except reprogram the memory timings
      for some boards, so it's better to do it later so we have a chance
      to get console messages if something goes wrong.
      
      Move it to happen after omap_serial_init gets called. And while
      patching it anyways, rename it to omap_sdrc_init as suggested by
      Benoit Cousson <b-cousson@ti.com>.
      Signed-off-by: NTony Lindgren <tony@atomide.com>
      a4ca9dbe
  28. 22 8月, 2011 1 次提交
  29. 16 6月, 2011 1 次提交