diff options
author | Ken Adams <kadams@nvidia.com> | 2012-11-27 14:14:41 -0500 |
---|---|---|
committer | Dan Willemsen <dwillemsen@nvidia.com> | 2013-09-14 13:21:28 -0700 |
commit | 932f820e0f4d19da44fc4b97a68ecf72c8bedf96 (patch) | |
tree | 4a963681dfee53150f6d57f38e50235eb29777cd /arch/arm/mach-tegra/board-bonaire-panel.c | |
parent | 147893fc833fc61b06512e7aeb79c9c4a614ff33 (diff) |
ARM: tegra: merge fixups
This change accounts for changes necessary due to
change http://git-master/r/161923 in the previous merge.
Change-Id: Ie0b1454d4ac051a473a793c9cab449da2fe866d9
Signed-off-by: Ken Adams <kadams@nvidia.com>
Reviewed-on: http://git-master/r/166644
Reviewed-by: Adeel Raza <araza@nvidia.com>
Reviewed-by: Jin Qian <jqian@nvidia.com>
Diffstat (limited to 'arch/arm/mach-tegra/board-bonaire-panel.c')
-rw-r--r-- | arch/arm/mach-tegra/board-bonaire-panel.c | 21 |
1 files changed, 13 insertions, 8 deletions
diff --git a/arch/arm/mach-tegra/board-bonaire-panel.c b/arch/arm/mach-tegra/board-bonaire-panel.c index 02f4f858f6b8..9eb884ebc3f4 100644 --- a/arch/arm/mach-tegra/board-bonaire-panel.c +++ b/arch/arm/mach-tegra/board-bonaire-panel.c @@ -179,7 +179,7 @@ static struct platform_device bonaire_backlight_device = { }, }; -static int bonaire_panel_enable(void) +static int bonaire_panel_enable(struct device *dev) { static struct regulator *reg; @@ -604,7 +604,7 @@ static struct tegra_dc_platform_data bonaire_disp1_pdata = { #endif }; -static struct nvhost_device bonaire_disp1_device = { +static struct platform_device bonaire_disp1_device = { .name = "tegradc", .id = 0, .resource = bonaire_disp1_resources, @@ -665,6 +665,9 @@ int __init bonaire_panel_init(void) { int err; struct resource *res; +#if defined(CONFIG_TEGRA_GRHOST) + struct platform_device *phost1x; +#endif bonaire_carveouts[1].base = tegra_carveout_start; bonaire_carveouts[1].size = tegra_carveout_size; @@ -675,19 +678,21 @@ int __init bonaire_panel_init(void) ARRAY_SIZE(bonaire_gfx_devices)); #ifdef CONFIG_TEGRA_GRHOST - err = tegra12_register_host1x_devices(); - if (err) - return err; + phost1x = tegra12_register_host1x_devices(); + if (!phost1x) + return -EINVAL; #endif #if defined(CONFIG_TEGRA_GRHOST) && defined(CONFIG_TEGRA_DC) - res = nvhost_get_resource_byname(&bonaire_disp1_device, + res = platform_get_resource_byname(&bonaire_disp1_device, IORESOURCE_MEM, "fbmem"); res->start = tegra_fb_start; res->end = tegra_fb_start + tegra_fb_size - 1; - if (!err) - err = nvhost_device_register(&bonaire_disp1_device); + if (!err) { + bonaire_disp1_device.dev.parent = &phost1x->dev; + err = platform_device_register(&bonaire_disp1_device); + } #endif return err; } |