device: Use pcidev_on_root()
Change-Id: Icf34b39d80f6e46d32a39b68f38fb2752c0bcebc Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Signed-off-by: Elyes HAOUAS <ehaouas@noos.fr> Reviewed-on: https://review.coreboot.org/c/26484 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Piotr Król <piotr.krol@3mdeb.com> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
This commit is contained in:
committed by
Felix Held
parent
54efaae701
commit
c70eed1e62
@ -72,7 +72,7 @@ void gma_set_gnvs_aslb(void *gnvs, uintptr_t aslb)
|
||||
static int gtt_setup(u8 *mmiobase)
|
||||
{
|
||||
u32 gttbase;
|
||||
struct device *dev = dev_find_slot(0, PCI_DEVFN(0,0));
|
||||
struct device *dev = pcidev_on_root(0, 0);
|
||||
|
||||
gttbase = pci_read_config32(dev, BGSM);
|
||||
printk(BIOS_DEBUG, "gttbase = %08x\n", gttbase);
|
||||
@ -319,7 +319,7 @@ static void gma_set_subsystem(struct device *dev, unsigned int vendor,
|
||||
|
||||
const struct i915_gpu_controller_info *intel_gma_get_controller_info(void)
|
||||
{
|
||||
struct device *dev = dev_find_slot(0, PCI_DEVFN(0x2,0));
|
||||
struct device *dev = pcidev_on_root(0x2, 0);
|
||||
if (!dev) {
|
||||
printk(BIOS_WARNING, "WARNING: Can't find IGD (0,2,0)\n");
|
||||
return NULL;
|
||||
|
Reference in New Issue
Block a user