Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 339797
b: refs/heads/master
c: d08cce6
h: refs/heads/master
i:
  339795: 34827ab
v: v3
  • Loading branch information
Paul Walmsley committed Nov 8, 2012
1 parent fc1ef48 commit 9c7cc1c
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b6a4226c14001b0aa20b11c69190cb89d2237d3d
refs/heads/master: d08cce6a1d6952a7774e4b61066d469c16d47a11
14 changes: 14 additions & 0 deletions trunk/arch/arm/mach-omap2/prm2xxx.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,20 @@ static u32 omap2xxx_prm_read_reset_sources(void)
return r;
}

/**
* omap2xxx_prm_dpll_reset - use DPLL reset to reboot the OMAP SoC
*
* Set the DPLL reset bit, which should reboot the SoC. This is the
* recommended way to restart the SoC. No return value.
*/
void omap2xxx_prm_dpll_reset(void)
{
omap2_prm_set_mod_reg_bits(OMAP_RST_DPLL3_MASK, WKUP_MOD,
OMAP2_RM_RSTCTRL);
/* OCP barrier */
omap2_prm_read_mod_reg(WKUP_MOD, OMAP2_RM_RSTCTRL);
}

int omap2xxx_clkdm_sleep(struct clockdomain *clkdm)
{
omap2_prm_set_mod_reg_bits(OMAP24XX_FORCESTATE_MASK,
Expand Down
2 changes: 2 additions & 0 deletions trunk/arch/arm/mach-omap2/prm2xxx.h
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@
extern int omap2xxx_clkdm_sleep(struct clockdomain *clkdm);
extern int omap2xxx_clkdm_wakeup(struct clockdomain *clkdm);

extern void omap2xxx_prm_dpll_reset(void);

extern int __init prm2xxx_init(void);
extern int __exit prm2xxx_exit(void);

Expand Down
15 changes: 15 additions & 0 deletions trunk/arch/arm/mach-omap2/prm3xxx.c
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,21 @@ u32 omap3_prm_vcvp_rmw(u32 mask, u32 bits, u8 offset)
return omap2_prm_rmw_mod_reg_bits(mask, bits, OMAP3430_GR_MOD, offset);
}

/**
* omap3xxx_prm_dpll3_reset - use DPLL3 reset to reboot the OMAP SoC
*
* Set the DPLL3 reset bit, which should reboot the SoC. This is the
* recommended way to restart the SoC, considering Errata i520. No
* return value.
*/
void omap3xxx_prm_dpll3_reset(void)
{
omap2_prm_set_mod_reg_bits(OMAP_RST_DPLL3_MASK, OMAP3430_GR_MOD,
OMAP2_RM_RSTCTRL);
/* OCP barrier */
omap2_prm_read_mod_reg(OMAP3430_GR_MOD, OMAP2_RM_RSTCTRL);
}

/**
* omap3xxx_prm_read_pending_irqs - read pending PRM MPU IRQs into @events
* @events: ptr to a u32, preallocated by caller
Expand Down
2 changes: 2 additions & 0 deletions trunk/arch/arm/mach-omap2/prm3xxx.h
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,8 @@ extern void omap3xxx_prm_ocp_barrier(void);
extern void omap3xxx_prm_save_and_clear_irqen(u32 *saved_mask);
extern void omap3xxx_prm_restore_irqen(u32 *saved_mask);

extern void omap3xxx_prm_dpll3_reset(void);

extern u32 omap3xxx_prm_get_reset_sources(void);

#endif /* __ASSEMBLER */
Expand Down

0 comments on commit 9c7cc1c

Please sign in to comment.