From: Thomas Hellstrom <thellstrom@vmware.com>
To: Christopher Friedt <chrisfriedt@gmail.com>
Cc: Thomas Hellstrom <thellstrom@vmware.com>,
LKML <linux-kernel@vger.kernel.org>,
dri-devel <dri-devel@lists.freedesktop.org>
Subject: Re: [PATCH 1/1] drm/vmwgfx: correct fb_fix_screeninfo.line_length
Date: Tue, 01 Apr 2014 12:00:50 +0200 [thread overview]
Message-ID: <533A8E52.5050304@vmware.com> (raw)
In-Reply-To: <CAPM=9tx4hdU0PZqdZcCd-x3HMu+6ZsGibeOHZPLe3OpW9Wsa0g@mail.gmail.com>
On 03/28/2014 02:45 AM, Dave Airlie wrote:
> On Fri, Mar 28, 2014 at 10:45 AM, Christopher Friedt
> <chrisfriedt@gmail.com> wrote:
>> Previously, the vmwgfx_fb driver would allow users to call FBIOSET_VINFO, but it would not adjust
>> the FINFO properly, resulting in distorted screen rendering. The patch corrects that behaviour.
>>
>> See https://bugs.gentoo.org/show_bug.cgi?id=494794 for examples.
>>
> Just adding cc's of maintainer list.
Looks correct to me.
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Will add it to vmgfx-next and cc stable.
Thanks,
Thomas
>> Signed-off-by: Christopher Friedt <chrisfriedt@gmail.com>
>> ---
>> drivers/gpu/drm/vmwgfx/vmwgfx_fb.c | 5 ++++-
>> 1 file changed, 4 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c b/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
>> index ed5ce2a..021b522 100644
>> --- a/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
>> +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
>> @@ -147,7 +147,7 @@ static int vmw_fb_check_var(struct fb_var_screeninfo *var,
>> }
>>
>> if (!vmw_kms_validate_mode_vram(vmw_priv,
>> - info->fix.line_length,
>> + var->xres * var->bits_per_pixel/8,
>> var->yoffset + var->yres)) {
>> DRM_ERROR("Requested geom can not fit in framebuffer\n");
>> return -EINVAL;
>> @@ -162,6 +162,8 @@ static int vmw_fb_set_par(struct fb_info *info)
>> struct vmw_private *vmw_priv = par->vmw_priv;
>> int ret;
>>
>> + info->fix.line_length = info->var.xres * info->var.bits_per_pixel/8;
>> +
>> ret = vmw_kms_write_svga(vmw_priv, info->var.xres, info->var.yres,
>> info->fix.line_length,
>> par->bpp, par->depth);
>> @@ -177,6 +179,7 @@ static int vmw_fb_set_par(struct fb_info *info)
>> vmw_write(vmw_priv, SVGA_REG_DISPLAY_POSITION_Y, info->var.yoffset);
>> vmw_write(vmw_priv, SVGA_REG_DISPLAY_WIDTH, info->var.xres);
>> vmw_write(vmw_priv, SVGA_REG_DISPLAY_HEIGHT, info->var.yres);
>> + vmw_write(vmw_priv, SVGA_REG_BYTES_PER_LINE, info->fix.line_length);
>> vmw_write(vmw_priv, SVGA_REG_DISPLAY_ID, SVGA_ID_INVALID);
>> }
>>
>> --
>> 1.8.3.2
>>
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at http://vger.kernel.org/majordomo-info.html
>> Please read the FAQ at http://www.tux.org/lkml/
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
WARNING: multiple messages have this Message-ID (diff)
From: Thomas Hellstrom <thellstrom@vmware.com>
To: Christopher Friedt <chrisfriedt@gmail.com>
Cc: Dave Airlie <airlied@gmail.com>,
Thomas Hellstrom <thellstrom@vmware.com>,
LKML <linux-kernel@vger.kernel.org>,
dri-devel <dri-devel@lists.freedesktop.org>
Subject: Re: [PATCH 1/1] drm/vmwgfx: correct fb_fix_screeninfo.line_length
Date: Tue, 01 Apr 2014 12:00:50 +0200 [thread overview]
Message-ID: <533A8E52.5050304@vmware.com> (raw)
In-Reply-To: <CAPM=9tx4hdU0PZqdZcCd-x3HMu+6ZsGibeOHZPLe3OpW9Wsa0g@mail.gmail.com>
On 03/28/2014 02:45 AM, Dave Airlie wrote:
> On Fri, Mar 28, 2014 at 10:45 AM, Christopher Friedt
> <chrisfriedt@gmail.com> wrote:
>> Previously, the vmwgfx_fb driver would allow users to call FBIOSET_VINFO, but it would not adjust
>> the FINFO properly, resulting in distorted screen rendering. The patch corrects that behaviour.
>>
>> See https://bugs.gentoo.org/show_bug.cgi?id=494794 for examples.
>>
> Just adding cc's of maintainer list.
Looks correct to me.
Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
Will add it to vmgfx-next and cc stable.
Thanks,
Thomas
>> Signed-off-by: Christopher Friedt <chrisfriedt@gmail.com>
>> ---
>> drivers/gpu/drm/vmwgfx/vmwgfx_fb.c | 5 ++++-
>> 1 file changed, 4 insertions(+), 1 deletion(-)
>>
>> diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c b/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
>> index ed5ce2a..021b522 100644
>> --- a/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
>> +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c
>> @@ -147,7 +147,7 @@ static int vmw_fb_check_var(struct fb_var_screeninfo *var,
>> }
>>
>> if (!vmw_kms_validate_mode_vram(vmw_priv,
>> - info->fix.line_length,
>> + var->xres * var->bits_per_pixel/8,
>> var->yoffset + var->yres)) {
>> DRM_ERROR("Requested geom can not fit in framebuffer\n");
>> return -EINVAL;
>> @@ -162,6 +162,8 @@ static int vmw_fb_set_par(struct fb_info *info)
>> struct vmw_private *vmw_priv = par->vmw_priv;
>> int ret;
>>
>> + info->fix.line_length = info->var.xres * info->var.bits_per_pixel/8;
>> +
>> ret = vmw_kms_write_svga(vmw_priv, info->var.xres, info->var.yres,
>> info->fix.line_length,
>> par->bpp, par->depth);
>> @@ -177,6 +179,7 @@ static int vmw_fb_set_par(struct fb_info *info)
>> vmw_write(vmw_priv, SVGA_REG_DISPLAY_POSITION_Y, info->var.yoffset);
>> vmw_write(vmw_priv, SVGA_REG_DISPLAY_WIDTH, info->var.xres);
>> vmw_write(vmw_priv, SVGA_REG_DISPLAY_HEIGHT, info->var.yres);
>> + vmw_write(vmw_priv, SVGA_REG_BYTES_PER_LINE, info->fix.line_length);
>> vmw_write(vmw_priv, SVGA_REG_DISPLAY_ID, SVGA_ID_INVALID);
>> }
>>
>> --
>> 1.8.3.2
>>
>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at http://vger.kernel.org/majordomo-info.html
>> Please read the FAQ at http://www.tux.org/lkml/
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2014-04-01 10:01 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-28 0:45 [PATCH 1/1] drm/vmwgfx: correct fb_fix_screeninfo.line_length Christopher Friedt
2014-03-28 0:48 ` Christopher Friedt
2014-03-28 1:45 ` Dave Airlie
2014-03-28 1:45 ` Dave Airlie
2014-04-01 10:00 ` Thomas Hellstrom [this message]
2014-04-01 10:00 ` Thomas Hellstrom
2014-06-30 10:19 ` Christopher Friedt
2014-06-30 11:48 ` Thomas Hellstrom
2014-06-30 11:48 ` Thomas Hellstrom
2014-06-30 12:25 ` Christopher Friedt
2014-06-30 12:39 ` Thomas Hellstrom
2014-06-30 12:39 ` Thomas Hellstrom
2014-06-30 12:49 ` Christopher Friedt
2014-06-30 13:03 ` Thomas Hellstrom
2014-06-30 13:03 ` Thomas Hellstrom
2014-06-30 13:18 ` Christopher Friedt
2014-06-30 13:22 ` Thomas Hellstrom
2014-06-30 13:22 ` Thomas Hellstrom
2014-07-02 3:01 ` Christopher Friedt
2014-07-02 3:01 ` Christopher Friedt
2014-07-02 4:16 ` Thomas Hellstrom
2014-07-02 4:16 ` Thomas Hellstrom
2014-07-02 12:15 ` Christopher Friedt
2014-07-02 22:19 ` Christopher Friedt
2014-07-02 22:19 ` Christopher Friedt
-- strict thread matches above, loose matches on Subject: below --
2014-02-01 15:26 Christopher Friedt
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=533A8E52.5050304@vmware.com \
--to=thellstrom@vmware.com \
--cc=chrisfriedt@gmail.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.