efi_loader: Rename EFI_RUNTIME_{TEXT, DATA} to __efi_runtime{, _data}
Compiler attributes are more commonly __foo style tags rather than big upper case eye sores like EFI_RUNTIME_TEXT. Simon Glass felt quite strongly about this, so this patch converts our existing defines over to more eye friendly ones. Signed-off-by: Alexander Graf <agraf@suse.de> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
65e4c0b168
commit
3c63db9ca9
|
@ -18,7 +18,7 @@
|
||||||
* x0~x7: input arguments
|
* x0~x7: input arguments
|
||||||
* x0~x3: output arguments
|
* x0~x3: output arguments
|
||||||
*/
|
*/
|
||||||
static void EFI_RUNTIME_TEXT hvc_call(struct pt_regs *args)
|
static void __efi_runtime hvc_call(struct pt_regs *args)
|
||||||
{
|
{
|
||||||
asm volatile(
|
asm volatile(
|
||||||
"ldr x0, %0\n"
|
"ldr x0, %0\n"
|
||||||
|
@ -52,7 +52,7 @@ static void EFI_RUNTIME_TEXT hvc_call(struct pt_regs *args)
|
||||||
* x0~x3: output arguments
|
* x0~x3: output arguments
|
||||||
*/
|
*/
|
||||||
|
|
||||||
void EFI_RUNTIME_TEXT smc_call(struct pt_regs *args)
|
void __efi_runtime smc_call(struct pt_regs *args)
|
||||||
{
|
{
|
||||||
asm volatile(
|
asm volatile(
|
||||||
"ldr x0, %0\n"
|
"ldr x0, %0\n"
|
||||||
|
@ -82,9 +82,9 @@ void EFI_RUNTIME_TEXT smc_call(struct pt_regs *args)
|
||||||
* use PSCI on U-Boot running below a hypervisor, please detect
|
* use PSCI on U-Boot running below a hypervisor, please detect
|
||||||
* this and set the flag accordingly.
|
* this and set the flag accordingly.
|
||||||
*/
|
*/
|
||||||
static const EFI_RUNTIME_DATA bool use_smc_for_psci = true;
|
static const __efi_runtime_data bool use_smc_for_psci = true;
|
||||||
|
|
||||||
void __noreturn EFI_RUNTIME_TEXT psci_system_reset(void)
|
void __noreturn __efi_runtime psci_system_reset(void)
|
||||||
{
|
{
|
||||||
struct pt_regs regs;
|
struct pt_regs regs;
|
||||||
|
|
||||||
|
@ -99,7 +99,7 @@ void __noreturn EFI_RUNTIME_TEXT psci_system_reset(void)
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
|
|
||||||
void __noreturn EFI_RUNTIME_TEXT psci_system_off(void)
|
void __noreturn __efi_runtime psci_system_off(void)
|
||||||
{
|
{
|
||||||
struct pt_regs regs;
|
struct pt_regs regs;
|
||||||
|
|
||||||
|
@ -121,7 +121,7 @@ void reset_misc(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_EFI_LOADER
|
#ifdef CONFIG_EFI_LOADER
|
||||||
void EFI_RUNTIME_TEXT EFIAPI efi_reset_system(
|
void __efi_runtime EFIAPI efi_reset_system(
|
||||||
enum efi_reset_type reset_type,
|
enum efi_reset_type reset_type,
|
||||||
efi_status_t reset_status,
|
efi_status_t reset_status,
|
||||||
unsigned long data_size, void *reset_data)
|
unsigned long data_size, void *reset_data)
|
||||||
|
|
|
@ -156,8 +156,8 @@ static inline void ascii2unicode(u16 *unicode, const char *ascii)
|
||||||
* Use these to indicate that your code / data should go into the EFI runtime
|
* Use these to indicate that your code / data should go into the EFI runtime
|
||||||
* section and thus still be available when the OS is running
|
* section and thus still be available when the OS is running
|
||||||
*/
|
*/
|
||||||
#define EFI_RUNTIME_DATA __attribute__ ((section ("efi_runtime_data")))
|
#define __efi_runtime_data __attribute__ ((section ("efi_runtime_data")))
|
||||||
#define EFI_RUNTIME_TEXT __attribute__ ((section ("efi_runtime_text")))
|
#define __efi_runtime __attribute__ ((section ("efi_runtime_text")))
|
||||||
|
|
||||||
/* Call this with mmio_ptr as the _pointer_ to a pointer to an MMIO region
|
/* Call this with mmio_ptr as the _pointer_ to a pointer to an MMIO region
|
||||||
* to make it available at runtime */
|
* to make it available at runtime */
|
||||||
|
@ -165,13 +165,13 @@ void efi_add_runtime_mmio(void *mmio_ptr, u64 len);
|
||||||
|
|
||||||
/* Boards may provide the functions below to implement RTS functionality */
|
/* Boards may provide the functions below to implement RTS functionality */
|
||||||
|
|
||||||
void EFI_RUNTIME_TEXT EFIAPI efi_reset_system(
|
void __efi_runtime EFIAPI efi_reset_system(
|
||||||
enum efi_reset_type reset_type,
|
enum efi_reset_type reset_type,
|
||||||
efi_status_t reset_status,
|
efi_status_t reset_status,
|
||||||
unsigned long data_size, void *reset_data);
|
unsigned long data_size, void *reset_data);
|
||||||
void efi_reset_system_init(void);
|
void efi_reset_system_init(void);
|
||||||
|
|
||||||
efi_status_t EFI_RUNTIME_TEXT EFIAPI efi_get_time(
|
efi_status_t __efi_runtime EFIAPI efi_get_time(
|
||||||
struct efi_time *time,
|
struct efi_time *time,
|
||||||
struct efi_time_cap *capabilities);
|
struct efi_time_cap *capabilities);
|
||||||
void efi_get_time_init(void);
|
void efi_get_time_init(void);
|
||||||
|
@ -179,8 +179,8 @@ void efi_get_time_init(void);
|
||||||
#else /* defined(EFI_LOADER) && !defined(CONFIG_SPL_BUILD) */
|
#else /* defined(EFI_LOADER) && !defined(CONFIG_SPL_BUILD) */
|
||||||
|
|
||||||
/* Without CONFIG_EFI_LOADER we don't have a runtime section, stub it out */
|
/* Without CONFIG_EFI_LOADER we don't have a runtime section, stub it out */
|
||||||
#define EFI_RUNTIME_DATA
|
#define __efi_runtime_data
|
||||||
#define EFI_RUNTIME_TEXT
|
#define __efi_runtime
|
||||||
static inline void efi_add_runtime_mmio(void **mmio_ptr, u64 len) { }
|
static inline void efi_add_runtime_mmio(void **mmio_ptr, u64 len) { }
|
||||||
|
|
||||||
/* No loader configured, stub out EFI_ENTRY */
|
/* No loader configured, stub out EFI_ENTRY */
|
||||||
|
|
|
@ -37,7 +37,7 @@ static bool efi_is_direct_boot = true;
|
||||||
* In most cases we want to pass an FDT to the payload, so reserve one slot of
|
* In most cases we want to pass an FDT to the payload, so reserve one slot of
|
||||||
* config table space for it. The pointer gets populated by do_bootefi_exec().
|
* config table space for it. The pointer gets populated by do_bootefi_exec().
|
||||||
*/
|
*/
|
||||||
static struct efi_configuration_table EFI_RUNTIME_DATA efi_conf_table[2];
|
static struct efi_configuration_table __efi_runtime_data efi_conf_table[2];
|
||||||
|
|
||||||
#ifdef CONFIG_ARM
|
#ifdef CONFIG_ARM
|
||||||
/*
|
/*
|
||||||
|
@ -790,10 +790,10 @@ static const struct efi_boot_services efi_boot_services = {
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
static uint16_t EFI_RUNTIME_DATA firmware_vendor[] =
|
static uint16_t __efi_runtime_data firmware_vendor[] =
|
||||||
{ 'D','a','s',' ','U','-','b','o','o','t',0 };
|
{ 'D','a','s',' ','U','-','b','o','o','t',0 };
|
||||||
|
|
||||||
struct efi_system_table EFI_RUNTIME_DATA systab = {
|
struct efi_system_table __efi_runtime_data systab = {
|
||||||
.hdr = {
|
.hdr = {
|
||||||
.signature = EFI_SYSTEM_TABLE_SIGNATURE,
|
.signature = EFI_SYSTEM_TABLE_SIGNATURE,
|
||||||
.revision = 0x20005, /* 2.5 */
|
.revision = 0x20005, /* 2.5 */
|
||||||
|
|
|
@ -26,9 +26,9 @@ struct efi_runtime_mmio_list {
|
||||||
/* This list contains all runtime available mmio regions */
|
/* This list contains all runtime available mmio regions */
|
||||||
LIST_HEAD(efi_runtime_mmio);
|
LIST_HEAD(efi_runtime_mmio);
|
||||||
|
|
||||||
static efi_status_t EFI_RUNTIME_TEXT EFIAPI efi_unimplemented(void);
|
static efi_status_t __efi_runtime EFIAPI efi_unimplemented(void);
|
||||||
static efi_status_t EFI_RUNTIME_TEXT EFIAPI efi_device_error(void);
|
static efi_status_t __efi_runtime EFIAPI efi_device_error(void);
|
||||||
static efi_status_t EFI_RUNTIME_TEXT EFIAPI efi_invalid_parameter(void);
|
static efi_status_t __efi_runtime EFIAPI efi_invalid_parameter(void);
|
||||||
|
|
||||||
#ifdef CONFIG_SYS_CACHELINE_SIZE
|
#ifdef CONFIG_SYS_CACHELINE_SIZE
|
||||||
#define EFI_CACHELINE_SIZE CONFIG_SYS_CACHELINE_SIZE
|
#define EFI_CACHELINE_SIZE CONFIG_SYS_CACHELINE_SIZE
|
||||||
|
@ -125,7 +125,7 @@ static efi_status_t EFIAPI efi_get_time_boottime(
|
||||||
|
|
||||||
/* Boards may override the helpers below to implement RTS functionality */
|
/* Boards may override the helpers below to implement RTS functionality */
|
||||||
|
|
||||||
void __weak EFI_RUNTIME_TEXT EFIAPI efi_reset_system(
|
void __weak __efi_runtime EFIAPI efi_reset_system(
|
||||||
enum efi_reset_type reset_type,
|
enum efi_reset_type reset_type,
|
||||||
efi_status_t reset_status,
|
efi_status_t reset_status,
|
||||||
unsigned long data_size, void *reset_data)
|
unsigned long data_size, void *reset_data)
|
||||||
|
@ -138,7 +138,7 @@ void __weak efi_reset_system_init(void)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
efi_status_t __weak EFI_RUNTIME_TEXT EFIAPI efi_get_time(
|
efi_status_t __weak __efi_runtime EFIAPI efi_get_time(
|
||||||
struct efi_time *time,
|
struct efi_time *time,
|
||||||
struct efi_time_cap *capabilities)
|
struct efi_time_cap *capabilities)
|
||||||
{
|
{
|
||||||
|
@ -346,7 +346,7 @@ void efi_add_runtime_mmio(void *mmio_ptr, u64 len)
|
||||||
* function or variable below this line.
|
* function or variable below this line.
|
||||||
*
|
*
|
||||||
* Please keep everything fully self-contained and annotated with
|
* Please keep everything fully self-contained and annotated with
|
||||||
* EFI_RUNTIME_TEXT and EFI_RUNTIME_DATA markers.
|
* __efi_runtime and __efi_runtime_data markers.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -355,22 +355,22 @@ void efi_add_runtime_mmio(void *mmio_ptr, u64 len)
|
||||||
* address map calls.
|
* address map calls.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
static efi_status_t EFI_RUNTIME_TEXT EFIAPI efi_unimplemented(void)
|
static efi_status_t __efi_runtime EFIAPI efi_unimplemented(void)
|
||||||
{
|
{
|
||||||
return EFI_UNSUPPORTED;
|
return EFI_UNSUPPORTED;
|
||||||
}
|
}
|
||||||
|
|
||||||
static efi_status_t EFI_RUNTIME_TEXT EFIAPI efi_device_error(void)
|
static efi_status_t __efi_runtime EFIAPI efi_device_error(void)
|
||||||
{
|
{
|
||||||
return EFI_DEVICE_ERROR;
|
return EFI_DEVICE_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
static efi_status_t EFI_RUNTIME_TEXT EFIAPI efi_invalid_parameter(void)
|
static efi_status_t __efi_runtime EFIAPI efi_invalid_parameter(void)
|
||||||
{
|
{
|
||||||
return EFI_INVALID_PARAMETER;
|
return EFI_INVALID_PARAMETER;
|
||||||
}
|
}
|
||||||
|
|
||||||
struct efi_runtime_services EFI_RUNTIME_DATA efi_runtime_services = {
|
struct efi_runtime_services __efi_runtime_data efi_runtime_services = {
|
||||||
.hdr = {
|
.hdr = {
|
||||||
.signature = EFI_RUNTIME_SERVICES_SIGNATURE,
|
.signature = EFI_RUNTIME_SERVICES_SIGNATURE,
|
||||||
.revision = EFI_RUNTIME_SERVICES_REVISION,
|
.revision = EFI_RUNTIME_SERVICES_REVISION,
|
||||||
|
|
Loading…
Reference in New Issue