From: Jesse Barnes <jbarnes@virtuousgeek.org>
To: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Intel Graphics Development <intel-gfx@lists.freedesktop.org>
Subject: Re: [PATCH 09/10] drm/i915: clean up plane bpp confusion
Date: Tue, 26 Mar 2013 14:04:47 -0700 [thread overview]
Message-ID: <20130326140447.60f1e342@jbarnes-desktop> (raw)
In-Reply-To: <1361491014-13888-10-git-send-email-daniel.vetter@ffwll.ch>
On Fri, 22 Feb 2013 00:56:53 +0100
Daniel Vetter <daniel.vetter@ffwll.ch> wrote:
> - There is no 16bpc linear color format in our hw. gen4+ has a 16 bpc
> float layout, but we don't really support it.
> - 10bpc is a gen4+ feature, fix up the support for it.
> - Update_plane should never see a wrong fb bpp value, BUG in the
> corresponding cases.
>
> v2: Rebase on top of Ville's plane pixel layout changes.
>
> v3: Actually drop the old gen4 check for 10bpc planes, spotted
> by Ville Syrjälä.
>
> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> ---
> drivers/gpu/drm/i915/intel_display.c | 20 ++++++++------------
> 1 file changed, 8 insertions(+), 12 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 04ae8ae..1258883 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -2083,8 +2083,7 @@ static int i9xx_update_plane(struct drm_crtc *crtc, struct drm_framebuffer *fb,
> dspcntr |= DISPPLANE_RGBX101010;
> break;
> default:
> - DRM_ERROR("Unknown pixel format 0x%08x\n", fb->pixel_format);
> - return -EINVAL;
> + BUG();
> }
>
> if (INTEL_INFO(dev)->gen >= 4) {
> @@ -2177,8 +2176,7 @@ static int ironlake_update_plane(struct drm_crtc *crtc,
> dspcntr |= DISPPLANE_RGBX101010;
> break;
> default:
> - DRM_ERROR("Unknown pixel format 0x%08x\n", fb->pixel_format);
> - return -EINVAL;
> + BUG();
> }
>
> if (obj->tiling_mode != I915_TILING_NONE)
> @@ -7347,21 +7345,19 @@ pipe_config_set_bpp(struct drm_crtc *crtc,
> bpp = 8*3;
> break;
> case 30:
> + if (INTEL_INFO(dev)->gen < 4) {
> + DRM_DEBUG_KMS("10 bpc not supported on gen2/3\n");
> + return -EINVAL;
> + }
> +
> bpp = 10*3;
> break;
> - case 48:
> - bpp = 12*3;
> - break;
> + /* TODO: gen4+ supports 16 bpc floating point, too. */
> default:
> DRM_DEBUG_KMS("unsupported depth\n");
> return -EINVAL;
> }
>
> - if (fb->depth > 24 && !HAS_PCH_SPLIT(dev)) {
> - DRM_DEBUG_KMS("high depth not supported on gmch platforms\n");
> - return -EINVAL;
> - }
> -
> pipe_config->pipe_bpp = bpp;
>
> /* Clamp display bpp to EDID value */
Why not squash this into the last one? The "high depth not supported"
jumped out at me and I had to check the docs that it really is
supported.
For the 64 bit float mode, we just need some tests in i-g-t; shouldn't
be a big deal to expose it from the kernel even if commodity userspace
doesn't use it.
--
Jesse Barnes, Intel Open Source Technology Center
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2013-03-26 21:04 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-21 23:56 [PATCH 00/10] basic infrastructure for pipe_config Daniel Vetter
2013-02-21 23:56 ` [PATCH 01/10] drm/i915: introduce struct intel_crtc_config Daniel Vetter
2013-02-22 10:23 ` Ville Syrjälä
2013-02-22 11:05 ` [PATCH] " Daniel Vetter
2013-02-26 17:09 ` Paulo Zanoni
2013-02-21 23:56 ` [PATCH 02/10] drm/i915: compute pipe_config earlier Daniel Vetter
2013-02-26 17:11 ` Paulo Zanoni
2013-02-21 23:56 ` [PATCH 03/10] drm/i915: add pipe_config->timings_set Daniel Vetter
2013-02-22 13:51 ` Ville Syrjälä
2013-03-03 18:01 ` Daniel Vetter
2013-03-04 14:18 ` Ville Syrjälä
2013-02-26 17:23 ` Paulo Zanoni
2013-03-03 17:58 ` Daniel Vetter
2013-02-21 23:56 ` [PATCH 04/10] drm/i915: add pipe_config->pixel_multiplier Daniel Vetter
2013-02-26 17:27 ` Paulo Zanoni
2013-03-03 18:05 ` Daniel Vetter
2013-02-21 23:56 ` [PATCH 05/10] drm/i915: drop helper vtable for sdvo encoder Daniel Vetter
2013-02-21 23:56 ` [PATCH 06/10] drm/i915: add pipe_config->has_pch_encoder Daniel Vetter
2013-02-26 17:39 ` Paulo Zanoni
2013-03-03 18:13 ` Daniel Vetter
2013-03-03 18:16 ` [PATCH] " Daniel Vetter
2013-03-04 22:24 ` Daniel Vetter
2013-02-21 23:56 ` [PATCH 07/10] drm/i915: add pipe_config->limited_color_range Daniel Vetter
2013-02-26 17:46 ` Paulo Zanoni
2013-02-21 23:56 ` [PATCH 08/10] drm/i915: move pipe bpp computation to pipe_config Daniel Vetter
2013-03-26 21:12 ` Jesse Barnes
2013-03-26 21:32 ` Daniel Vetter
2013-02-21 23:56 ` [PATCH 09/10] drm/i915: clean up plane bpp confusion Daniel Vetter
2013-03-26 21:04 ` Jesse Barnes [this message]
2013-02-21 23:56 ` [PATCH 10/10] drm/i915: clean up pipe " Daniel Vetter
2013-03-26 21:06 ` Jesse Barnes
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=20130326140447.60f1e342@jbarnes-desktop \
--to=jbarnes@virtuousgeek.org \
--cc=daniel.vetter@ffwll.ch \
--cc=intel-gfx@lists.freedesktop.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox