* Re: [PATCH - v3] drm/i915: Discard large BIOS framebuffers causing display corruption.
[not found] <31D69334-DEF9-41B7-968B-B847796926FF@outlook.com>
@ 2022-01-11 8:36 ` Jani Nikula
2022-01-12 13:37 ` [Intel-gfx] " Ville Syrjälä
1 sibling, 0 replies; 2+ messages in thread
From: Jani Nikula @ 2022-01-11 8:36 UTC (permalink / raw)
To: Ashish Arora, joonas.lahtinen, rodrigo.vivi
Cc: Linux Kernel Mailing List, intel-gfx, ville.syrjala
On Tue, 11 Jan 2022, Ashish Arora <ashisharora.linux@outlook.com> wrote:
> From: Ashish Arora <ashisharora.linux@outlook.com>
>
> On certain 4k panels and Macs, the BIOS framebuffer is larger than what
> panel requires causing display corruption. Introduce a check for the same.
>
>
> Signed-off-by: Ashish Arora <ashisharora.linux@outlook.com>
> Reviewed-by: Aun-Ali Zaidi <admin@kodeit.net>
I'll defer to Ville on this one, Cc'd.
BR,
Jani.
> ---
> V2 :- Use != instead of < and >
> V3 :- Mention Macs (Thanks to Orlando)
> drivers/gpu/drm/i915/display/intel_fbdev.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_fbdev.c b/drivers/gpu/drm/i915/display/intel_fbdev.c
> index 842c04e63..16b1c82b2 100644
> --- a/drivers/gpu/drm/i915/display/intel_fbdev.c
> +++ b/drivers/gpu/drm/i915/display/intel_fbdev.c
> @@ -181,10 +181,10 @@ static int intelfb_create(struct drm_fb_helper *helper,
> int ret;
>
> if (intel_fb &&
> - (sizes->fb_width > intel_fb->base.width ||
> - sizes->fb_height > intel_fb->base.height)) {
> + (sizes->fb_width != intel_fb->base.width ||
> + sizes->fb_height != intel_fb->base.height)) {
> drm_dbg_kms(&dev_priv->drm,
> - "BIOS fb too small (%dx%d), we require (%dx%d),"
> + "BIOS fb not valid (%dx%d), we require (%dx%d),"
> " releasing it\n",
> intel_fb->base.width, intel_fb->base.height,
> sizes->fb_width, sizes->fb_height);
--
Jani Nikula, Intel Open Source Graphics Center
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Intel-gfx] [PATCH - v3] drm/i915: Discard large BIOS framebuffers causing display corruption.
[not found] <31D69334-DEF9-41B7-968B-B847796926FF@outlook.com>
2022-01-11 8:36 ` [PATCH - v3] drm/i915: Discard large BIOS framebuffers causing display corruption Jani Nikula
@ 2022-01-12 13:37 ` Ville Syrjälä
1 sibling, 0 replies; 2+ messages in thread
From: Ville Syrjälä @ 2022-01-12 13:37 UTC (permalink / raw)
To: Ashish Arora
Cc: jani.nikula, joonas.lahtinen, rodrigo.vivi, intel-gfx,
Linux Kernel Mailing List
On Tue, Jan 11, 2022 at 07:55:22AM +0000, Ashish Arora wrote:
> From: Ashish Arora <ashisharora.linux@outlook.com>
>
> On certain 4k panels and Macs, the BIOS framebuffer is larger than what
> panel requires causing display corruption. Introduce a check for the same.
If a larger fb causes corruption then there is a real bug somewhere.
>
>
> Signed-off-by: Ashish Arora <ashisharora.linux@outlook.com>
> Reviewed-by: Aun-Ali Zaidi <admin@kodeit.net>
> ---
> V2 :- Use != instead of < and >
> V3 :- Mention Macs (Thanks to Orlando)
> drivers/gpu/drm/i915/display/intel_fbdev.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_fbdev.c b/drivers/gpu/drm/i915/display/intel_fbdev.c
> index 842c04e63..16b1c82b2 100644
> --- a/drivers/gpu/drm/i915/display/intel_fbdev.c
> +++ b/drivers/gpu/drm/i915/display/intel_fbdev.c
> @@ -181,10 +181,10 @@ static int intelfb_create(struct drm_fb_helper *helper,
> int ret;
>
> if (intel_fb &&
> - (sizes->fb_width > intel_fb->base.width ||
> - sizes->fb_height > intel_fb->base.height)) {
> + (sizes->fb_width != intel_fb->base.width ||
> + sizes->fb_height != intel_fb->base.height)) {
> drm_dbg_kms(&dev_priv->drm,
> - "BIOS fb too small (%dx%d), we require (%dx%d),"
> + "BIOS fb not valid (%dx%d), we require (%dx%d),"
> " releasing it\n",
> intel_fb->base.width, intel_fb->base.height,
> sizes->fb_width, sizes->fb_height);
> --
> 2.25.1
>
--
Ville Syrjälä
Intel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-01-12 13:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <31D69334-DEF9-41B7-968B-B847796926FF@outlook.com>
2022-01-11 8:36 ` [PATCH - v3] drm/i915: Discard large BIOS framebuffers causing display corruption Jani Nikula
2022-01-12 13:37 ` [Intel-gfx] " Ville Syrjälä
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).