[PATCH]arm64: ignore FACS load failed for arm64

Fu Wei fu.wei at linaro.org
Mon Oct 20 09:58:19 UTC 2014


On 10/20/2014 05:16 PM, Graeme Gregory wrote:
> On Mon, Oct 20, 2014 at 04:37:42PM +0800, Fu Wei wrote:
>> arm64: ignore load failed for FACS which is involved in old 
>> BIOS style suspend/hibernate and does not make sense on arm64.
>>
>> Signed-off-by: Fu Wei <fu.wei at linaro.org>
>> ---
>>  src/lib/src/fwts_acpi_tables.c | 5 +++++
>>  1 file changed, 5 insertions(+)
>>
>> diff --git a/src/lib/src/fwts_acpi_tables.c b/src/lib/src/fwts_acpi_tables.c
>> index 56498e0..0641d93 100644
>> --- a/src/lib/src/fwts_acpi_tables.c
>> +++ b/src/lib/src/fwts_acpi_tables.c
>> @@ -375,7 +375,12 @@ static int fwts_acpi_handle_fadt(
>>  	    "FACS", "FIRMWARE_CTRL", "X_FIRMWARE_CTRL",
>>  	     &fadt->firmware_control, &fadt->x_firmware_ctrl,
>>  	     provenance) != FWTS_OK) {
>> +#if defined(__aarch64__)
>> +		fwts_log_warning(fw, "Failed to load FACS: Cannot determine "
>> +				"address of FACS from FADT. IGNORE for AArch64 platform!");
>> +#else
>>  		return FWTS_ERROR;
>> +#endif
> 
> I have a feeling doing this compile time might end up biting us on the
> ass in some situations where we need to check ACPI 5.1 vs 5.2 etc. I am
> not massively familiar with the code but my gut feeling is this should
> be solved runtime.

Agree, so I should try to make "#if defined" became "if (is_aarch64)", right?

I also noticed : Yi Li has submitted a patch for SMBIOS, so maybe I can use "#ifdef FWTS_ARCH_AARCH64"

any suggestion or idea ?

> 
> Graeme
> 
>>  	}
>>  	/* Determine DSDT addr and load it */
>>  	if (fwts_acpi_handle_fadt_tables(fw, fadt,
>> -- 
>> 1.9.1


-- 
Best regards,

Fu Wei
Software Engineer From Red Hat
LEG Team
Linaro.org | Open source software for ARM SoCs
Ph: +86 186 2020 4684 (mobile)
IRC: fuwei
Skype: tekkamanninja
Room 1512, Regus One Corporate Avenue,Level 15,
One Corporate Avenue,222 Hubin Road,Huangpu District,
Shanghai,China 200021 



More information about the fwts-devel mailing list