diff options
author | Simon Glass <sjg@chromium.org> | 2020-09-22 12:45:23 -0600 |
---|---|---|
committer | Bin Meng <bmeng.cn@gmail.com> | 2020-09-25 11:27:20 +0800 |
commit | ca60199fee9a5259250b6e4bd407bac239e52dca (patch) | |
tree | 94a4e0ca466f7e9c03cd24944de712613db016f1 /arch/x86/cpu | |
parent | ea78675b963e2e9991b4f787a29421799c13a49e (diff) | |
download | u-boot-ca60199fee9a5259250b6e4bd407bac239e52dca.tar.gz u-boot-ca60199fee9a5259250b6e4bd407bac239e52dca.tar.xz u-boot-ca60199fee9a5259250b6e4bd407bac239e52dca.zip |
x86: apl: Drop unnecessary code in PMC driver
We don't have CONFIG_PCI in TPL but it is present in SPL, etc. So this
code is not needed. Drop it, and fix a code-style nit just above.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'arch/x86/cpu')
-rw-r--r-- | arch/x86/cpu/apollolake/pmc.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/arch/x86/cpu/apollolake/pmc.c b/arch/x86/cpu/apollolake/pmc.c index 192dec7109..576d018757 100644 --- a/arch/x86/cpu/apollolake/pmc.c +++ b/arch/x86/cpu/apollolake/pmc.c @@ -118,7 +118,8 @@ int apl_pmc_ofdata_to_uc_platdata(struct udevice *dev) int size; int ret; - ret = dev_read_u32_array(dev, "early-regs", base, ARRAY_SIZE(base)); + ret = dev_read_u32_array(dev, "early-regs", base, + ARRAY_SIZE(base)); if (ret) return log_msg_ret("Missing/short early-regs", ret); if (spl_phase() == PHASE_TPL) { @@ -133,11 +134,6 @@ int apl_pmc_ofdata_to_uc_platdata(struct udevice *dev) } upriv->acpi_base = base[4]; - /* Since PCI is not enabled, we must get the BDF manually */ - plat->bdf = pci_get_devfn(dev); - if (plat->bdf < 0) - return log_msg_ret("Cannot get PMC PCI address", plat->bdf); - /* Get the dwX values for pmc gpe settings */ size = dev_read_size(dev, "gpe0-dw"); if (size < 0) |