Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 271216
b: refs/heads/master
c: 10a6c1d
h: refs/heads/master
v: v3
  • Loading branch information
Laurent Pinchart committed Aug 19, 2011
1 parent 884a491 commit a078e81
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8f0246d6287fbb37c05b7983ff61c7f57ad86a92
refs/heads/master: 10a6c1de2ca2761f87c9bd62ab882577a80995f1
9 changes: 5 additions & 4 deletions trunk/drivers/video/vt8623fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -620,13 +620,14 @@ static int vt8623fb_pan_display(struct fb_var_screeninfo *var, struct fb_info *i
unsigned int offset;

/* Calculate the offset */
if (var->bits_per_pixel == 0) {
offset = (var->yoffset / 16) * var->xres_virtual + var->xoffset;
if (info->var.bits_per_pixel == 0) {
offset = (var->yoffset / 16) * info->var.xres_virtual
+ var->xoffset;
offset = offset >> 3;
} else {
offset = (var->yoffset * info->fix.line_length) +
(var->xoffset * var->bits_per_pixel / 8);
offset = offset >> ((var->bits_per_pixel == 4) ? 2 : 1);
(var->xoffset * info->var.bits_per_pixel / 8);
offset = offset >> ((info->var.bits_per_pixel == 4) ? 2 : 1);
}

/* Set the offset */
Expand Down

0 comments on commit a078e81

Please sign in to comment.