diff options
author | Felix Held <felix.held@amd.corp-partner.google.com> | 2020-06-17 20:09:51 +0200 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2020-06-18 20:15:56 +0000 |
commit | f13b6ebc89706b8298f6eea3ce70d9f1f9e020f0 (patch) | |
tree | fea558f4b009ec50c46c33d35220a69e8af414fd /src | |
parent | 71800909f3f560a4da72a4fea1f2fff945f97732 (diff) |
soc/amd/picasso/i2c: use config_of_soc()
Change-Id: I2ebe072a5c887b16d2a39f029069bc8674f8eaea
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/42478
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/soc/amd/picasso/i2c.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/soc/amd/picasso/i2c.c b/src/soc/amd/picasso/i2c.c index fa59b994a2..6f34573aa9 100644 --- a/src/soc/amd/picasso/i2c.c +++ b/src/soc/amd/picasso/i2c.c @@ -177,13 +177,10 @@ static void restore_i2c_pin_registers(uint8_t gpio, void sb_reset_i2c_slaves(void) { const struct soc_amd_picasso_config *cfg; - const struct device *dev = pcidev_path_on_root(GNB_DEVFN); struct soc_amd_i2c_save save_table[saved_pins_count]; uint8_t i, j, control; - if (!dev || !dev->chip_info) - return; - cfg = dev->chip_info; + cfg = config_of_soc(); control = cfg->i2c_scl_reset & GPIO_I2C_MASK; if (control == 0) return; |