Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci
Commits
658ce97e
Commit
658ce97e
authored
Nov 04, 2008
by
Kevin Hilman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
OMAP3: PM: decouple PER and CORE context save and restore
Signed-off-by:
Kevin Hilman
<
khilman@deeprootsystems.com
>
parent
d7814e4d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
22 deletions
+29
-22
arch/arm/mach-omap2/pm34xx.c
arch/arm/mach-omap2/pm34xx.c
+29
-22
No files found.
arch/arm/mach-omap2/pm34xx.c
View file @
658ce97e
...
...
@@ -338,19 +338,20 @@ static void omap_sram_idle(void)
if
(
pwrdm_read_pwrst
(
neon_pwrdm
)
==
PWRDM_POWER_ON
)
set_pwrdm_state
(
neon_pwrdm
,
mpu_next_state
);
/* CORE & PER */
/* PER */
per_next_state
=
pwrdm_read_next_pwrst
(
per_pwrdm
);
if
(
per_next_state
<
PWRDM_POWER_ON
)
{
omap2_gpio_prepare_for_retention
();
omap_uart_prepare_idle
(
2
);
if
(
per_next_state
==
PWRDM_POWER_OFF
)
omap3_per_save_context
();
}
/* CORE */
core_next_state
=
pwrdm_read_next_pwrst
(
core_pwrdm
);
if
(
core_next_state
<
PWRDM_POWER_ON
)
{
omap2_gpio_prepare_for_retention
();
omap_uart_prepare_idle
(
0
);
omap_uart_prepare_idle
(
1
);
/* PER changes only with core */
per_next_state
=
pwrdm_read_next_pwrst
(
per_pwrdm
);
if
(
per_next_state
<
PWRDM_POWER_ON
)
{
omap_uart_prepare_idle
(
2
);
if
(
per_next_state
==
PWRDM_POWER_OFF
)
omap3_per_save_context
();
}
if
(
core_next_state
==
PWRDM_POWER_OFF
)
{
omap3_core_save_context
();
omap3_prcm_save_context
();
...
...
@@ -392,14 +393,8 @@ static void omap_sram_idle(void)
if
(
pwrdm_read_prev_pwrst
(
mpu_pwrdm
)
==
PWRDM_POWER_OFF
)
restore_table_entry
();
/* CORE */
if
(
core_next_state
<
PWRDM_POWER_ON
)
{
if
(
per_next_state
<
PWRDM_POWER_ON
)
omap_uart_resume_idle
(
2
);
omap_uart_resume_idle
(
1
);
omap_uart_resume_idle
(
0
);
/* Disable IO-PAD wakeup */
prm_clear_mod_reg_bits
(
OMAP3430_EN_IO
,
WKUP_MOD
,
PM_WKEN
);
core_prev_state
=
pwrdm_read_prev_pwrst
(
core_pwrdm
);
if
(
core_prev_state
==
PWRDM_POWER_OFF
)
{
omap3_core_restore_context
();
...
...
@@ -407,15 +402,27 @@ static void omap_sram_idle(void)
omap3_sram_restore_context
();
omap2_sms_restore_context
();
}
if
(
per_next_state
<
PWRDM_POWER_ON
)
{
per_prev_state
=
pwrdm_read_prev_pwrst
(
per_pwrdm
);
if
(
per_prev_state
==
PWRDM_POWER_OFF
)
omap3_per_restore_context
();
}
omap_uart_resume_idle
(
0
);
omap_uart_resume_idle
(
1
);
if
(
core_next_state
==
PWRDM_POWER_OFF
)
prm_clear_mod_reg_bits
(
OMAP3430_AUTO_OFF
,
OMAP3430_GR_MOD
,
OMAP3_PRM_VOLTCTRL_OFFSET
);
}
/* PER */
if
(
per_next_state
<
PWRDM_POWER_ON
)
{
per_prev_state
=
pwrdm_read_prev_pwrst
(
per_pwrdm
);
omap_uart_resume_idle
(
2
);
if
(
per_prev_state
==
PWRDM_POWER_OFF
)
omap3_per_restore_context
();
omap2_gpio_resume_after_retention
();
}
/* Disable IO-PAD wakeup */
if
(
core_next_state
<
PWRDM_POWER_ON
)
prm_clear_mod_reg_bits
(
OMAP3430_EN_IO
,
WKUP_MOD
,
PM_WKEN
);
pwrdm_post_transition
();
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment