All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: "Srinivas, Vidya" <vidya.srinivas@intel.com>
Cc: "igt-dev@lists.freedesktop.org" <igt-dev@lists.freedesktop.org>
Subject: Re: [igt-dev] [PATCH i-g-t] tests/kms_plane_alpha_blend: Fix a check in is_6bpc function
Date: Thu, 15 Jul 2021 06:05:49 +0300	[thread overview]
Message-ID: <YO+mDZpuBTE3fVmy@intel.com> (raw)
In-Reply-To: <BY5PR11MB43728C08415336D8744C91F989139@BY5PR11MB4372.namprd11.prod.outlook.com>

On Wed, Jul 14, 2021 at 03:01:36PM +0000, Srinivas, Vidya wrote:
> Hello Ville,
> 
> Thank you so much. I limited the bpp to 18 in compute_sink_pipe_bpp.
> I tested on external monitor both HDMI and DP. Tests did not fail. It passed without CRC mismatch.
> I checked display_info and ensure bpp shows 18 on pipe B for both HDMI and DP case.
> Dithering was set to ON.
> 
> [CRTC:152:pipe B]:
>         uapi: enable=yes, active=yes, mode="3840x2160": 30 266640 3840 3848 3992 4000 2160 2214 2219 2222 0x40 0x9
>         hw: active=yes, adjusted_mode="3840x2160": 30 266640 3840 3848 3992 4000 2160 2214 2219 2222 0x40 0x9
>         pipe src size=3840x2160, dither=yes, bpp=18
> 
> I am really sorry. Should I revert this patch? Kindly guide me further. Thank you so much.

Well, before we go making too many changes would be nice to see if we
can figure out what is really causing the crc mismatches on eDP. I can't
immediately think of anything eDP specific it could be really, apart 
from maybe some PSR/etc. related bug. Have we ruled those sort if things
out?

> 
> Regards
> Vidya
> 
> -----Original Message-----
> From: Ville Syrjälä <ville.syrjala@linux.intel.com> 
> Sent: Wednesday, July 14, 2021 7:57 PM
> To: Srinivas, Vidya <vidya.srinivas@intel.com>
> Cc: igt-dev@lists.freedesktop.org
> Subject: Re: [igt-dev] [PATCH i-g-t] tests/kms_plane_alpha_blend: Fix a check in is_6bpc function
> 
> On Wed, Jul 14, 2021 at 01:22:26PM +0000, Srinivas, Vidya wrote:
> > Hello Ville,
> > 
> > I am sorry, I don’t have a 6 bpc external panel. 
> 
> You don't need one. Just limit the bpp to 18 when computing the link params.
> 
> > Juha-Pekka had suggested we use the set_lut table as being used in 
> > kms_flip_scaled_crc.c But when I tried that, max upto 0x7F it would pass (not with original 0xFF00). After that it would give back CRC mismatch.
> > 
> > Set_lut:
> > uint16_t v  = (i * 0xffff / (lut_size - 1)) & 0x7f; lut[i].red = v; 
> > lut[i].green = v; lut[i].blue = v;
> > 
> > Other solutions which worked were:
> > 1. Use alpha for primary plane 
> > https://patchwork.freedesktop.org/patch/440263/?series=90828&rev=6
> > 
> > 2. Adding this line before setting the primary gray
> > 	
> > igt_plane_set_prop_value(igt_pipe_get_plane_type(&display->pipes[pipe]
> > , DRM_PLANE_TYPE_PRIMARY), IGT_PLANE_ALPHA, 0);
> > 
> > 2. Remove primary plane 
> > https://patchwork.freedesktop.org/patch/436178/?series=90828&rev=1
> > 
> > 3. Use lower alpha values 0x7e for coverage, pre-multiplied and 
> > constant 
> > https://patchwork.freedesktop.org/patch/438831/?series=90828&rev=3
> > 
> > 4. Use an alpha buffer for primary commit 
> > https://patchwork.freedesktop.org/patch/440157/?series=90828&rev=5
> > 
> > 5. Use black_fb instead of gray_fb in coverage-vs-premult-vs-constant 
> > for primary 
> > https://patchwork.freedesktop.org/patch/441554/?series=90828&rev=7
> > 
> > Apart from these, I disabled dithering in kernel and that too did not help. Screen shows content correctly but CRC mismatch is seen.
> > 
> > Regards
> > Vidya
> > 
> > 
> > -----Original Message-----
> > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > Sent: Wednesday, July 14, 2021 6:34 PM
> > To: Srinivas, Vidya <vidya.srinivas@intel.com>
> > Cc: igt-dev@lists.freedesktop.org
> > Subject: Re: [igt-dev] [PATCH i-g-t] tests/kms_plane_alpha_blend: Fix 
> > a check in is_6bpc function
> > 
> > On Wed, Jul 14, 2021 at 11:21:47AM +0000, Srinivas, Vidya wrote:
> > > Hello Ville,
> > > 
> > > Apologies. I tried to turn off dithering from kernel itself. But still CRC mismatch came up.
> > > This is on Jasperlake chromebook which is using 6bpc panel.
> > > 
> > > Same jasperlake with 8bpc panel is working fine. 
> > > 
> > > So, as last resort we did this ☹.
> > 
> > Well that's a bit unfortunate because now the commit messages are lying, and we still don't know what is going on.
> > 
> > Do the same failures happen with external DP @ 6bpc? I wouldn't really expect any crc differences since AFAIK nothing in the pipe should change before the dithering block, and with dithering disabled the port should just chop off the extra bits at the very end.
> > 
> > > 
> > > Regards
> > > Vidya
> > > 
> > > -----Original Message-----
> > > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > > Sent: Wednesday, July 14, 2021 3:55 PM
> > > To: Srinivas, Vidya <vidya.srinivas@intel.com>
> > > Cc: igt-dev@lists.freedesktop.org
> > > Subject: Re: [igt-dev] [PATCH i-g-t] tests/kms_plane_alpha_blend: 
> > > Fix a check in is_6bpc function
> > > 
> > > On Wed, Jul 14, 2021 at 01:30:02PM +0530, Vidya Srinivas wrote:
> > > > Fixes commit 3bf28f9dffd41b85c262d4e6664ffbdf5b7d9a93.
> > > > 
> > > > is_6bpc is supposed to return false if connector is not eDP or DSI.
> > > > The right check will be DRM_MODE_CONNECTOR_eDP && 
> > > > DRM_MODE_CONNECTOR_DSI By mistake DRM_MODE_CONNECTOR_eDP || 
> > > > DRM_MODE_CONNECTOR_DSI was being used.
> > > 
> > > Instead of these incomplete hacks why aren't we just turning off dithering when doing crc capture?
> > > 
> > > > 
> > > > Credits-to: Ashutosh Dixit <ashutosh.dixit@intel.com>
> > > > Signed-off-by: Vidya Srinivas <vidya.srinivas@intel.com>
> > > > ---
> > > >  tests/kms_plane_alpha_blend.c | 2 +-
> > > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > > > 
> > > > diff --git a/tests/kms_plane_alpha_blend.c 
> > > > b/tests/kms_plane_alpha_blend.c index a3529dc2190f..8020216c1594
> > > > 100644
> > > > --- a/tests/kms_plane_alpha_blend.c
> > > > +++ b/tests/kms_plane_alpha_blend.c
> > > > @@ -454,7 +454,7 @@ static bool is_6bpc(igt_display_t *display, enum pipe pipe) {
> > > >  		return false;
> > > >  
> > > >  	c = output->config.connector;
> > > > -	if (c->connector_type != DRM_MODE_CONNECTOR_eDP ||
> > > > +	if (c->connector_type != DRM_MODE_CONNECTOR_eDP &&
> > > >  		c->connector_type != DRM_MODE_CONNECTOR_DSI)
> > > >  		return false;
> > > >  
> > > > --
> > > > 2.32.0
> > > > 
> > > > _______________________________________________
> > > > igt-dev mailing list
> > > > igt-dev@lists.freedesktop.org
> > > > https://lists.freedesktop.org/mailman/listinfo/igt-dev
> > > 
> > > --
> > > Ville Syrjälä
> > > Intel
> > 
> > --
> > Ville Syrjälä
> > Intel
> 
> --
> Ville Syrjälä
> Intel

-- 
Ville Syrjälä
Intel
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

  reply	other threads:[~2021-07-15  3:05 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-14  8:00 [igt-dev] [PATCH i-g-t] tests/kms_plane_alpha_blend: Fix a check in is_6bpc function Vidya Srinivas
2021-07-14  8:50 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2021-07-14 10:04 ` [igt-dev] [PATCH i-g-t] " Ramalingam C
2021-07-14 11:22   ` Srinivas, Vidya
2021-07-14 10:25 ` Ville Syrjälä
2021-07-14 11:21   ` Srinivas, Vidya
2021-07-14 13:03     ` Ville Syrjälä
2021-07-14 13:22       ` Srinivas, Vidya
2021-07-14 14:27         ` Ville Syrjälä
2021-07-14 15:01           ` Srinivas, Vidya
2021-07-15  3:05             ` Ville Syrjälä [this message]
2021-07-15  3:50               ` Srinivas, Vidya
2021-07-22 13:40                 ` Srinivas, Vidya
2021-07-14 16:09 ` [igt-dev] ✗ Fi.CI.IGT: failure for " Patchwork

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=YO+mDZpuBTE3fVmy@intel.com \
    --to=ville.syrjala@linux.intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=vidya.srinivas@intel.com \
    /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.