From 4a9569a1230935e20adfca0762be50dcae97487e Mon Sep 17 00:00:00 2001 From: Angel Pons Date: Mon, 8 Jun 2020 01:39:25 +0200 Subject: nb/intel/x4x: Use PCI bitwise ops Tested with BUILD_TIMELESS=1, Intel DG43GT does not change. Change-Id: I1bb7a7fd808cbbb45efbbfb9581c6a948323a48f Signed-off-by: Angel Pons Reviewed-on: https://review.coreboot.org/c/coreboot/+/42155 Reviewed-by: HAOUAS Elyes Tested-by: build bot (Jenkins) --- src/northbridge/intel/x4x/gma.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/northbridge/intel/x4x/gma.c') diff --git a/src/northbridge/intel/x4x/gma.c b/src/northbridge/intel/x4x/gma.c index d2d2bb067d..68d382ef20 100644 --- a/src/northbridge/intel/x4x/gma.c +++ b/src/northbridge/intel/x4x/gma.c @@ -48,11 +48,9 @@ static void gma_func0_init(struct device *dev) static void gma_func0_disable(struct device *dev) { struct device *dev_host = pcidev_on_root(0, 0); - u16 ggc; - ggc = pci_read_config16(dev_host, D0F0_GGC); - ggc |= (1 << 1); /* VGA cycles to discrete GPU */ - pci_write_config16(dev_host, D0F0_GGC, ggc); + /* VGA cycles to discrete GPU */ + pci_or_config16(dev_host, D0F0_GGC, 1 << 1); } static void gma_generate_ssdt(const struct device *device) -- cgit v1.2.3