Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Arm Trusted Firmware
Commits
cf4ee177
Commit
cf4ee177
authored
Apr 25, 2016
by
danh-arm
Browse files
Merge pull request #604 from sandrine-bailleux-arm/sb/validate-psci_cpu_on_start-args
Validate psci_cpu_on_start() arguments
parents
3f84cec5
22b09c17
Changes
3
Hide whitespace changes
Inline
Side-by-side
services/std_svc/psci/psci_main.c
View file @
cf4ee177
...
...
@@ -47,7 +47,6 @@ int psci_cpu_on(u_register_t target_cpu,
{
int
rc
;
unsigned
int
end_pwrlvl
;
entry_point_info_t
ep
;
/* Determine if the cpu exists of not */
...
...
@@ -64,11 +63,7 @@ int psci_cpu_on(u_register_t target_cpu,
* To turn this cpu on, specify which power
* levels need to be turned on
*/
end_pwrlvl
=
PLAT_MAX_PWR_LVL
;
rc
=
psci_cpu_on_start
(
target_cpu
,
&
ep
,
end_pwrlvl
);
return
rc
;
return
psci_cpu_on_start
(
target_cpu
,
&
ep
);
}
unsigned
int
psci_version
(
void
)
...
...
services/std_svc/psci/psci_on.c
View file @
cf4ee177
...
...
@@ -67,13 +67,16 @@ static int cpu_on_validate_state(aff_info_state_t aff_state)
* platform handler as it can return error.
******************************************************************************/
int
psci_cpu_on_start
(
u_register_t
target_cpu
,
entry_point_info_t
*
ep
,
unsigned
int
end_pwrlvl
)
entry_point_info_t
*
ep
)
{
int
rc
;
unsigned
int
target_idx
=
plat_core_pos_by_mpidr
(
target_cpu
);
aff_info_state_t
target_aff_state
;
/* Calling function must supply valid input arguments */
assert
((
int
)
target_idx
>=
0
);
assert
(
ep
!=
NULL
);
/*
* This function must only be called on platforms where the
* CPU_ON platform hooks have been implemented.
...
...
services/std_svc/psci/psci_private.h
View file @
cf4ee177
...
...
@@ -203,8 +203,7 @@ int psci_spd_migrate_info(u_register_t *mpidr);
/* Private exported functions from psci_on.c */
int
psci_cpu_on_start
(
unsigned
long
target_cpu
,
entry_point_info_t
*
ep
,
unsigned
int
end_pwrlvl
);
entry_point_info_t
*
ep
);
void
psci_cpu_on_finish
(
unsigned
int
cpu_idx
,
psci_power_state_t
*
state_info
);
...
...
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