summaryrefslogtreecommitdiff
path: root/drivers/video/tegra/fb.c
diff options
context:
space:
mode:
authorJon Mayo <jmayo@nvidia.com>2011-08-23 19:01:29 -0700
committerDan Willemsen <dwillemsen@nvidia.com>2011-11-30 21:48:34 -0800
commitd9f696579b5f3d4d43ebe338b8f203c07cdf4a0c (patch)
treef165fd01ac7ea350e0207e9dc67826a30db792e7 /drivers/video/tegra/fb.c
parenteb6bcb9d0852c24db00f425f7609b59d25886160 (diff)
video: tegra: fb: do not set mode on register
Do not load a default mode on fb register. This causes a race with any userspace attempts to set a mode on hotplug. Bug 862473 Original-Change-Id: I52a93c4348753ca73d01a96025512bf9d179e1e5 Reviewed-on: http://git-master/r/48861 Reviewed-by: Jonathan Mayo <jmayo@nvidia.com> Tested-by: Jonathan Mayo <jmayo@nvidia.com> Reviewed-by: Donghan Ryu <dryu@nvidia.com> Reviewed-by: Michael Frydrych <mfrydrych@nvidia.com> Tested-by: Michael Frydrych <mfrydrych@nvidia.com> Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com> Reviewed-by: Robert Morell <rmorell@nvidia.com> Rebase-Id: R1204d8e40ce56d0de22ec059fb6a73a0952f94ce
Diffstat (limited to 'drivers/video/tegra/fb.c')
-rw-r--r--drivers/video/tegra/fb.c21
1 files changed, 0 insertions, 21 deletions
diff --git a/drivers/video/tegra/fb.c b/drivers/video/tegra/fb.c
index 9eb8adb2feaa..b7acecc8f562 100644
--- a/drivers/video/tegra/fb.c
+++ b/drivers/video/tegra/fb.c
@@ -312,7 +312,6 @@ void tegra_fb_update_monspecs(struct tegra_fb_info *fb_info,
struct fb_videomode *mode))
{
struct fb_event event;
- struct fb_modelist *m;
int i;
mutex_lock(&fb_info->info->lock);
@@ -344,26 +343,6 @@ void tegra_fb_update_monspecs(struct tegra_fb_info *fb_info,
}
}
- if (list_empty(&fb_info->info->modelist)) {
- struct tegra_dc_mode mode;
- memset(&fb_info->info->var, 0x0, sizeof(fb_info->info->var));
- memset(&mode, 0x0, sizeof(mode));
- tegra_dc_set_mode(fb_info->win->dc, &mode);
- } else {
- /* in case the first mode was not matched */
- m = list_first_entry(&fb_info->info->modelist, struct fb_modelist, list);
- m->mode.flag |= FB_MODE_IS_FIRST;
- fb_info->info->mode = (struct fb_videomode *)
- fb_find_best_display(specs, &fb_info->info->modelist);
-
- /* fb_videomode_to_var doesn't fill out all the members
- of fb_var_screeninfo */
- memset(&fb_info->info->var, 0x0, sizeof(fb_info->info->var));
-
- fb_videomode_to_var(&fb_info->info->var, fb_info->info->mode);
- tegra_fb_set_par(fb_info->info);
- }
-
event.info = fb_info->info;
fb_notifier_call_chain(FB_EVENT_NEW_MODELIST, &event);
mutex_unlock(&fb_info->info->lock);