diff options
author | Kyösti Mälkki <kyosti.malkki@gmail.com> | 2020-07-01 13:15:27 +0300 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2020-12-15 18:50:13 +0000 |
commit | d786520de1c6e8f6218c4b853ba2d17d084ec78d (patch) | |
tree | 56df644ed10ae66fb5d6f4321ca868801f32b8b6 /src/soc/amd/stoneyridge | |
parent | c2503dbe8864a3a3b917f08794d2414455118891 (diff) |
soc/amd/common: Refactor SMBus base arguments
Replace SMBus base addresses with proper symbols.
Change-Id: I5e0ebd7609c5c83d0e443ffba74dae68017d3ebc
Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/42074
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc/amd/stoneyridge')
-rw-r--r-- | src/soc/amd/stoneyridge/smbus_spd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/soc/amd/stoneyridge/smbus_spd.c b/src/soc/amd/stoneyridge/smbus_spd.c index 7c54d8dcb2..773aad19f4 100644 --- a/src/soc/amd/stoneyridge/smbus_spd.c +++ b/src/soc/amd/stoneyridge/smbus_spd.c @@ -1,7 +1,7 @@ /* SPDX-License-Identifier: GPL-2.0-only */ #include <amdblocks/agesawrapper.h> -#include <amdblocks/acpimmio_map.h> +#include <amdblocks/acpimmio.h> #include <console/console.h> #include <device/pci_def.h> #include <device/device.h> @@ -34,7 +34,7 @@ static int readspd(uint8_t SmbusSlaveAddress, char *buffer, size_t count) dev_addr = (SmbusSlaveAddress >> 1); /* Read the first SPD byte */ - error = do_smbus_read_byte(ACPIMMIO_SMBUS_BASE, dev_addr, 0); + error = do_smbus_read_byte((uintptr_t)acpimmio_smbus, dev_addr, 0); if (error < 0) { printk(BIOS_ERR, "-------------SPD READ ERROR-----------\n"); return error; @@ -44,7 +44,7 @@ static int readspd(uint8_t SmbusSlaveAddress, char *buffer, size_t count) /* Read the remaining SPD bytes using do_smbus_recv_byte for speed */ for (index = 1 ; index < count ; index++) { - error = do_smbus_recv_byte(ACPIMMIO_SMBUS_BASE, dev_addr); + error = do_smbus_recv_byte((uintptr_t)acpimmio_smbus, dev_addr); if (error < 0) { printk(BIOS_ERR, "-------------SPD READ ERROR-----------\n"); return error; |