diff options
author | Simon Glass <sjg@chromium.org> | 2020-07-07 21:32:05 -0600 |
---|---|---|
committer | Bin Meng <bmeng.cn@gmail.com> | 2020-07-17 14:32:24 +0800 |
commit | 8d7ff12e635f255afce74767a78d7584abbbaed0 (patch) | |
tree | baf23081ee65e40970ec4c1c83a1aa7c44ae5601 /arch/x86/cpu/tangier/acpi.c | |
parent | 8f9877df95ae0068ce14a962bd72c22026c1d2e8 (diff) | |
download | u-boot-8d7ff12e635f255afce74767a78d7584abbbaed0.tar.gz u-boot-8d7ff12e635f255afce74767a78d7584abbbaed0.tar.xz u-boot-8d7ff12e635f255afce74767a78d7584abbbaed0.zip |
acpi: Allow creating the GNVS to fail
In some cases an internal error may prevent this from working. Update the
function return value and report the error. At present the API for writing
tables does not easily support reporting errors, but once it is fully
updated to use a context pointer, this will be easier.
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Wolfgang Wallner <wolfgang.wallner@br-automation.com>
Diffstat (limited to 'arch/x86/cpu/tangier/acpi.c')
-rw-r--r-- | arch/x86/cpu/tangier/acpi.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/arch/x86/cpu/tangier/acpi.c b/arch/x86/cpu/tangier/acpi.c index 4ec8fdd6f8..41bd177e09 100644 --- a/arch/x86/cpu/tangier/acpi.c +++ b/arch/x86/cpu/tangier/acpi.c @@ -107,7 +107,7 @@ u32 acpi_fill_csrt(u32 current) return current; } -void acpi_create_gnvs(struct acpi_global_nvs *gnvs) +int acpi_create_gnvs(struct acpi_global_nvs *gnvs) { struct udevice *dev; int ret; @@ -122,4 +122,6 @@ void acpi_create_gnvs(struct acpi_global_nvs *gnvs) if (ret > 0) gnvs->pcnt = ret; } + + return 0; } |