x86: Update mpspec to build on 64-bit machines

At present this uses u32 to store an address. We should use unsigned long
and avoid special types in function return values and parameters unless
necessary. This makes the code more portable.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
This commit is contained in:
Simon Glass
2017-01-16 07:03:36 -07:00
committed by Bin Meng
parent 42fd8c19b5
commit e71ffd0951
2 changed files with 10 additions and 10 deletions

View File

@@ -224,9 +224,9 @@ struct mp_ext_compat_address_space {
* @mc: configuration table header address
* @return: configuration table end address
*/
static inline u32 mp_next_mpc_entry(struct mp_config_table *mc)
static inline ulong mp_next_mpc_entry(struct mp_config_table *mc)
{
return (u32)mc + mc->mpc_length;
return (ulong)mc + mc->mpc_length;
}
/**
@@ -254,9 +254,9 @@ static inline void mp_add_mpc_entry(struct mp_config_table *mc, uint length)
* @mc: configuration table header address
* @return: configuration table end address
*/
static inline u32 mp_next_mpe_entry(struct mp_config_table *mc)
static inline ulong mp_next_mpe_entry(struct mp_config_table *mc)
{
return (u32)mc + mc->mpc_length + mc->mpe_length;
return (ulong)mc + mc->mpc_length + mc->mpe_length;
}
/**