soc/intel/skylake: Correct GPIO pointer assignment

We need to store the acpi_gpio struct, not save its address.

Found-by: Clang Static Analyzer
Signed-off-by: Jacob Garber <jgarber1@ualberta.ca>
Change-Id: I41c8bf10ce72bec736da97ccc33f9ada49804dc1
Reviewed-on: https://review.coreboot.org/c/coreboot/+/32797
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Martin Roth <martinroth@google.com>
This commit is contained in:
Jacob Garber 2019-05-14 16:14:57 -06:00 committed by Patrick Georgi
parent 6644a75b0e
commit e1909eea5c
1 changed files with 1 additions and 1 deletions

View File

@ -35,7 +35,7 @@ int sd_fill_soc_gpio_info(struct acpi_gpio* gpio, struct device *dev)
gpio->pin_count = 1;
gpio->pins[0] = config->sdcard_cd_gpio_default;
} else
gpio = &config->sdcard_cd_gpio;
*gpio = config->sdcard_cd_gpio;
return 0;
}