diff options
author | Florian Tobias Schandinat <FlorianSchandinat@gmx.de> | 2010-07-23 07:32:25 -0400 |
---|---|---|
committer | Florian Tobias Schandinat <FlorianSchandinat@gmx.de> | 2010-07-23 10:46:11 -0400 |
commit | af29a5b1781bf642a29b5e9bb6162dccfcd626df (patch) | |
tree | 71620cfea61cefeb502149a6c61e1937b4d31dfc /drivers/video/via | |
parent | cd5899551c48dff5fe05914fc187932111091953 (diff) |
viafb: fix accel_flags check_var bug
viafb: fix accel_flags check_var bug
In check_var we should check and modify the var given and not the
one which is currently active. So this code was obviously wrong.
Probably this was doing no harm because all acceleration functions
also check whether acceleration is possible. (otherwise I would
expect this to lead to a null pointer dereference)
Signed-off-by: Florian Tobias Schandinat <FlorianSchandinat@gmx.de>
Cc: Joseph Chan <JosephChan@via.com.tw>
Diffstat (limited to 'drivers/video/via')
-rw-r--r-- | drivers/video/via/viafbdev.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/video/via/viafbdev.c b/drivers/video/via/viafbdev.c index 0f56eb28227d..bdd0e4130f4e 100644 --- a/drivers/video/via/viafbdev.c +++ b/drivers/video/via/viafbdev.c | |||
@@ -216,9 +216,9 @@ static int viafb_check_var(struct fb_var_screeninfo *var, | |||
216 | 216 | ||
217 | /* Adjust var according to our driver's own table */ | 217 | /* Adjust var according to our driver's own table */ |
218 | viafb_fill_var_timing_info(var, viafb_refresh, vmode_entry); | 218 | viafb_fill_var_timing_info(var, viafb_refresh, vmode_entry); |
219 | if (info->var.accel_flags & FB_ACCELF_TEXT && | 219 | if (var->accel_flags & FB_ACCELF_TEXT && |
220 | !ppar->shared->vdev->engine_mmio) | 220 | !ppar->shared->vdev->engine_mmio) |
221 | info->var.accel_flags = 0; | 221 | var->accel_flags = 0; |
222 | 222 | ||
223 | return 0; | 223 | return 0; |
224 | } | 224 | } |