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
dfe5c78e
Unverified
Commit
dfe5c78e
authored
Oct 24, 2018
by
Antonio Niño Díaz
Committed by
GitHub
Oct 24, 2018
Browse files
Merge pull request #1639 from chandnich/scmi-update
plat/arm/scmi: introduce plat_css_get_scmi_info API
parents
44445ae5
b911dddc
Changes
5
Hide whitespace changes
Inline
Side-by-side
plat/arm/board/juno/juno_topology.c
View file @
dfe5c78e
...
@@ -9,6 +9,21 @@
...
@@ -9,6 +9,21 @@
#include <plat_arm.h>
#include <plat_arm.h>
#include <platform.h>
#include <platform.h>
#include "juno_def.h"
#include "juno_def.h"
#include "../../css/drivers/scmi/scmi.h"
#include "../../css/drivers/mhu/css_mhu_doorbell.h"
static
scmi_channel_plat_info_t
juno_scmi_plat_info
=
{
.
scmi_mbx_mem
=
CSS_SCMI_PAYLOAD_BASE
,
.
db_reg_addr
=
PLAT_CSS_MHU_BASE
+
CSS_SCMI_MHU_DB_REG_OFF
,
.
db_preserve_mask
=
0xfffffffe
,
.
db_modify_mask
=
0x1
,
.
ring_doorbell
=
&
mhu_ring_doorbell
,
};
scmi_channel_plat_info_t
*
plat_css_get_scmi_info
()
{
return
&
juno_scmi_plat_info
;
}
/*
/*
* On Juno, the system power level is the highest power level.
* On Juno, the system power level is the highest power level.
...
...
plat/arm/css/drivers/scmi/scmi.h
View file @
dfe5c78e
...
@@ -159,4 +159,7 @@ int scmi_sys_pwr_state_get(void *p, uint32_t *system_state);
...
@@ -159,4 +159,7 @@ int scmi_sys_pwr_state_get(void *p, uint32_t *system_state);
int
scmi_ap_core_set_reset_addr
(
void
*
p
,
uint64_t
reset_addr
,
uint32_t
attr
);
int
scmi_ap_core_set_reset_addr
(
void
*
p
,
uint64_t
reset_addr
,
uint32_t
attr
);
int
scmi_ap_core_get_reset_addr
(
void
*
p
,
uint64_t
*
reset_addr
,
uint32_t
*
attr
);
int
scmi_ap_core_get_reset_addr
(
void
*
p
,
uint64_t
*
reset_addr
,
uint32_t
*
attr
);
/* API to get the platform specific SCMI channel information. */
scmi_channel_plat_info_t
*
plat_css_get_scmi_info
();
#endif
/* __CSS_SCMI_H__ */
#endif
/* __CSS_SCMI_H__ */
plat/arm/css/drivers/scp/css_pm_scmi.c
View file @
dfe5c78e
...
@@ -13,7 +13,6 @@
...
@@ -13,7 +13,6 @@
#include <platform.h>
#include <platform.h>
#include <string.h>
#include <string.h>
#include "../scmi/scmi.h"
#include "../scmi/scmi.h"
#include "../mhu/css_mhu_doorbell.h"
#include "css_scp.h"
#include "css_scp.h"
/*
/*
...
@@ -298,14 +297,6 @@ void __dead2 css_scp_sys_reboot(void)
...
@@ -298,14 +297,6 @@ void __dead2 css_scp_sys_reboot(void)
css_scp_system_off
(
SCMI_SYS_PWR_COLD_RESET
);
css_scp_system_off
(
SCMI_SYS_PWR_COLD_RESET
);
}
}
static
scmi_channel_plat_info_t
plat_css_scmi_plat_info
=
{
.
scmi_mbx_mem
=
CSS_SCMI_PAYLOAD_BASE
,
.
db_reg_addr
=
PLAT_CSS_MHU_BASE
+
CSS_SCMI_MHU_DB_REG_OFF
,
.
db_preserve_mask
=
0xfffffffe
,
.
db_modify_mask
=
0x1
,
.
ring_doorbell
=
&
mhu_ring_doorbell
,
};
static
int
scmi_ap_core_init
(
scmi_channel_t
*
ch
)
static
int
scmi_ap_core_init
(
scmi_channel_t
*
ch
)
{
{
#if PROGRAMMABLE_RESET_ADDRESS
#if PROGRAMMABLE_RESET_ADDRESS
...
@@ -330,7 +321,7 @@ static int scmi_ap_core_init(scmi_channel_t *ch)
...
@@ -330,7 +321,7 @@ static int scmi_ap_core_init(scmi_channel_t *ch)
void
__init
plat_arm_pwrc_setup
(
void
)
void
__init
plat_arm_pwrc_setup
(
void
)
{
{
channel
.
info
=
&
plat_css_scmi_
plat_
info
;
channel
.
info
=
plat_css_
get_
scmi_info
()
;
channel
.
lock
=
ARM_SCMI_LOCK_GET_INSTANCE
;
channel
.
lock
=
ARM_SCMI_LOCK_GET_INSTANCE
;
scmi_handle
=
scmi_init
(
&
channel
);
scmi_handle
=
scmi_init
(
&
channel
);
if
(
scmi_handle
==
NULL
)
{
if
(
scmi_handle
==
NULL
)
{
...
...
plat/arm/css/sgi/sgi_bl31_setup.c
View file @
dfe5c78e
...
@@ -9,6 +9,21 @@
...
@@ -9,6 +9,21 @@
#include <plat_arm.h>
#include <plat_arm.h>
#include <sgi_plat_config.h>
#include <sgi_plat_config.h>
#include <sgi_ras.h>
#include <sgi_ras.h>
#include "../../css/drivers/scmi/scmi.h"
#include "../../css/drivers/mhu/css_mhu_doorbell.h"
static
scmi_channel_plat_info_t
sgi575_scmi_plat_info
=
{
.
scmi_mbx_mem
=
CSS_SCMI_PAYLOAD_BASE
,
.
db_reg_addr
=
PLAT_CSS_MHU_BASE
+
CSS_SCMI_MHU_DB_REG_OFF
,
.
db_preserve_mask
=
0xfffffffe
,
.
db_modify_mask
=
0x1
,
.
ring_doorbell
=
&
mhu_ring_doorbell
,
};
scmi_channel_plat_info_t
*
plat_css_get_scmi_info
()
{
return
&
sgi575_scmi_plat_info
;
}
void
bl31_early_platform_setup2
(
u_register_t
arg0
,
u_register_t
arg1
,
void
bl31_early_platform_setup2
(
u_register_t
arg0
,
u_register_t
arg1
,
u_register_t
arg2
,
u_register_t
arg3
)
u_register_t
arg2
,
u_register_t
arg3
)
...
...
plat/arm/css/sgm/sgm_bl31_setup.c
View file @
dfe5c78e
...
@@ -8,6 +8,21 @@
...
@@ -8,6 +8,21 @@
#include <debug.h>
#include <debug.h>
#include <plat_arm.h>
#include <plat_arm.h>
#include <sgm_plat_config.h>
#include <sgm_plat_config.h>
#include "../../css/drivers/scmi/scmi.h"
#include "../../css/drivers/mhu/css_mhu_doorbell.h"
static
scmi_channel_plat_info_t
sgm775_scmi_plat_info
=
{
.
scmi_mbx_mem
=
CSS_SCMI_PAYLOAD_BASE
,
.
db_reg_addr
=
PLAT_CSS_MHU_BASE
+
CSS_SCMI_MHU_DB_REG_OFF
,
.
db_preserve_mask
=
0xfffffffe
,
.
db_modify_mask
=
0x1
,
.
ring_doorbell
=
&
mhu_ring_doorbell
,
};
scmi_channel_plat_info_t
*
plat_css_get_scmi_info
()
{
return
&
sgm775_scmi_plat_info
;
}
void
bl31_early_platform_setup2
(
u_register_t
arg0
,
u_register_t
arg1
,
void
bl31_early_platform_setup2
(
u_register_t
arg0
,
u_register_t
arg1
,
u_register_t
arg2
,
u_register_t
arg3
)
u_register_t
arg2
,
u_register_t
arg3
)
...
...
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