diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/video/sh_mobile_hdmi.c | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/drivers/video/sh_mobile_hdmi.c b/drivers/video/sh_mobile_hdmi.c index d7df10315d8d..fcda0e970113 100644 --- a/drivers/video/sh_mobile_hdmi.c +++ b/drivers/video/sh_mobile_hdmi.c | |||
@@ -787,6 +787,9 @@ static int sh_hdmi_read_edid(struct sh_hdmi *hdmi) | |||
787 | found_rate_error = rate_error; | 787 | found_rate_error = rate_error; |
788 | } | 788 | } |
789 | 789 | ||
790 | hdmi->var.width = hdmi->monspec.max_x * 10; | ||
791 | hdmi->var.height = hdmi->monspec.max_y * 10; | ||
792 | |||
790 | /* | 793 | /* |
791 | * TODO 1: if no ->info is present, postpone running the config until | 794 | * TODO 1: if no ->info is present, postpone running the config until |
792 | * after ->info first gets registered. | 795 | * after ->info first gets registered. |
@@ -960,8 +963,12 @@ static bool sh_hdmi_must_reconfigure(struct sh_hdmi *hdmi) | |||
960 | dev_dbg(info->dev, "Old %ux%u, new %ux%u\n", | 963 | dev_dbg(info->dev, "Old %ux%u, new %ux%u\n", |
961 | mode1.xres, mode1.yres, mode2.xres, mode2.yres); | 964 | mode1.xres, mode1.yres, mode2.xres, mode2.yres); |
962 | 965 | ||
963 | if (fb_mode_is_equal(&mode1, &mode2)) | 966 | if (fb_mode_is_equal(&mode1, &mode2)) { |
967 | /* It can be a different monitor with an equal video-mode */ | ||
968 | old_var->width = new_var->width; | ||
969 | old_var->height = new_var->height; | ||
964 | return false; | 970 | return false; |
971 | } | ||
965 | 972 | ||
966 | dev_dbg(info->dev, "Switching %u -> %u lines\n", | 973 | dev_dbg(info->dev, "Switching %u -> %u lines\n", |
967 | mode1.yres, mode2.yres); | 974 | mode1.yres, mode2.yres); |
@@ -1057,8 +1064,11 @@ static void sh_hdmi_edid_work_fn(struct work_struct *work) | |||
1057 | * on, if we run a resume here, the logo disappears | 1064 | * on, if we run a resume here, the logo disappears |
1058 | */ | 1065 | */ |
1059 | if (lock_fb_info(hdmi->info)) { | 1066 | if (lock_fb_info(hdmi->info)) { |
1060 | sh_hdmi_display_on(hdmi, hdmi->info); | 1067 | struct fb_info *info = hdmi->info; |
1061 | unlock_fb_info(hdmi->info); | 1068 | info->var.width = hdmi->var.width; |
1069 | info->var.height = hdmi->var.height; | ||
1070 | sh_hdmi_display_on(hdmi, info); | ||
1071 | unlock_fb_info(info); | ||
1062 | } | 1072 | } |
1063 | } else { | 1073 | } else { |
1064 | /* New monitor or have to wake up */ | 1074 | /* New monitor or have to wake up */ |