summaryrefslogtreecommitdiff
path: root/arch/x86/cpu/ivybridge/gma.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2016-01-17 16:11:59 -0700
committerBin Meng <bmeng.cn@gmail.com>2016-01-24 12:09:42 +0800
commit25d5352c71dcc599030a4a764d8087185ed537d3 (patch)
tree2fa7d292b53be82731264d453b473d2e17782ef5 /arch/x86/cpu/ivybridge/gma.c
parent98655f3a8d23d322d91ebb1897ff02a6e8a46b10 (diff)
x86: ivybridge: Use syscon for the GMA device
Until we have a proper video uclass we can use syscon to handle the GMA device, and avoid the special device tree and PCI searching. Update the code to work this way. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'arch/x86/cpu/ivybridge/gma.c')
-rw-r--r--arch/x86/cpu/ivybridge/gma.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/arch/x86/cpu/ivybridge/gma.c b/arch/x86/cpu/ivybridge/gma.c
index f9b03f2ef6..3b6291e905 100644
--- a/arch/x86/cpu/ivybridge/gma.c
+++ b/arch/x86/cpu/ivybridge/gma.c
@@ -538,8 +538,10 @@ static int gma_pm_init_pre_vbios(void *gtt_bar, int rev)
return 0;
}
-int gma_pm_init_post_vbios(int rev, void *gtt_bar, const void *blob, int node)
+int gma_pm_init_post_vbios(struct udevice *dev, int rev, void *gtt_bar)
{
+ const void *blob = gd->fdt_blob;
+ int node = dev->of_offset;
u32 reg32, cycle_delay;
debug("GT Power Management Init (post VBIOS)\n");
@@ -794,7 +796,7 @@ void sandybridge_setup_graphics(struct udevice *dev, struct udevice *video_dev)
writel(reg32, MCHBAR_REG(0x5418));
}
-int gma_func0_init(struct udevice *dev, const void *blob, int node)
+int gma_func0_init(struct udevice *dev)
{
#ifdef CONFIG_VIDEO
ulong start;
@@ -839,7 +841,7 @@ int gma_func0_init(struct udevice *dev, const void *blob, int node)
debug("BIOS ran in %lums\n", get_timer(start));
#endif
/* Post VBIOS init */
- ret = gma_pm_init_post_vbios(rev, gtt_bar, blob, node);
+ ret = gma_pm_init_post_vbios(dev, rev, gtt_bar);
if (ret)
return ret;