New issue
Advanced search Search tips

Issue 900579 link

Starred by 2 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug

Blocked on:
issue 865112



Sign in to add a comment

flaky: graphics autotest for hw overlays and HTML Canvas

Project Member Reported by mcasas@chromium.org, Oct 31

Issue description

Sometimes I see [a]:

plane[27]: plane-0
	crtc=(null)
	fb=0
	crtc-pos=2400x1600+0+0
	src-pos=2400.000000x1600.000000+0.000000+0.000000
	rotation=1
plane[29]: plane-1
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1
plane[34]: plane-2
	crtc=crtc-1
	fb=68
		format=XR24 little-endian (0x34325258)
			modifier=0xf000000000000001
		size=2400x1600
		layers:
			pitch[0]=9600
			offset[0]=0
	crtc-pos=2400x1600+0+0
	src-pos=2400.000000x1600.000000+0.000000+0.000000
	rotation=1
plane[36]: plane-3
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1
plane[41]: plane-4
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1
plane[44]: plane-5
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1


And sometimes I see [b] (differences are inside the first "plane" set):

plane[27]: plane-0
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1
plane[29]: plane-1
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1
plane[34]: plane-2
	crtc=crtc-1
	fb=60
		format=XR24 little-endian (0x34325258)
			modifier=0xf000000000000001
		size=2400x1600
		layers:
			pitch[0]=9600
			offset[0]=0
	crtc-pos=2400x1600+0+0
	src-pos=2400.000000x1600.000000+0.000000+0.000000
	rotation=1
plane[36]: plane-3
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1
plane[41]: plane-4
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1
plane[44]: plane-5
	crtc=(null)
	fb=0
	crtc-pos=0x0+0+0
	src-pos=0.000000x0.000000+0.000000+0.000000
	rotation=1

(this is the dump of /sys/kernel/debug/dri/{0,1}/state).
With the current python regex [1] we count the number of planes in the first
dump as 2, but only 1 on the second dump.  I was told by dcastagna@ that
we started switching off the primary plane (plane[27]) recently (re. the "fb=0"
on those); when that switch-off happens, the value of crtc-pos is whatever
it had before :-(

But that also means that we won't know when we are getting a given <canvas>
promoted to overlay correctly, since it seems that the primary plane might
be turned off "under its feet".



[1] https://cs.corp.google.com/chromeos_public/src/third_party/autotest/files/client/cros/graphics/graphics_utils.py?type=cs&q=get_num_hardware_overlays+package:%5Echromeos_public$&g=0&l=1247

[a] https://00e9e64bac2b013fcb1fec2839254c156fcf5f7eb6a847a651-apidata.googleusercontent.com/download/storage/v1/b/chromeos-autotest-results/o/254017539-chromeos-test%2Fchromeos6-row4-rack16-host9%2Fgraphics_HwOverlays%2Fdebug%2Fgraphics_HwOverlays.DEBUG?qk=AD5uMEvtwbAxoz93IO_FAPTTZ5UdTy0tlsm6gVOleowAc5jpz_Ucumw2Y3GQmC9SV4FxA3hxhiM1m9pU5XjJg5OpSItjCZSLQ7cbcm0S6UbjTRhUR4gOleFs80aJcvIi82fibNNH8lLtJM0gEVvZEnZ87ZPFHsqgJ-s5K4LUqDzkteNRj4uWft9lbPSt30xecF15Obj8yfsahTnG9fFpdtjHprylkhTyVi5dVlDA8JqBSLEG_jwrD8Tn5xbd7WhkoOsSyuvyfL9aVsT33I6sVR8A9x8AmvxVENrDDYmzRooKkeUgT2A4SJiLl3XJOzumcVZiHoHRtytOEQdwwal0Ux930j4FyWS4xzxqMnmvzMq8KLI6wyFpIC8lxQaEvyKtWnYqOE2be2G_EdgCPCWoKyKLBRMvf1biBR4WqSg7iaDieKtPlG0kBmLRj2uc-XmHACJzEu3-GMIylzbeZABxlkzVYP0BZcpkB9kRQCM39K47fFJBmEdLXKOksp_wBOLqTCZoGfZewn3INHhrM4MLCu86j2QGcVcyYr2skcoGKwt1Zx6o4VA-OgzRcIm2-X0V5C7QI_gQ4UUkEnCq4uFuPQsO9TxlyLl43OlNURJk8qqlhU9x-xhrYWdmMB61nCPctE4tBIU29VlEX3Y2qI2eKjm_3nCmgaA_HuvNz5lmkw0N2UqWoJt5uF0HvQ_oF8yFx0t9-n-kNxnqPb7j0M3ewGZib1jc-rZ759FAVdwb6pmbQ9AW1JvwIO7C8Vxjvkto6gSSaBqhffSazozQcxzSWek8uyAS4gGNkDwABqHpOz3WjQQ3IF8sH9v8MO1ceS0bs6eJTgH3yqgAVtYnraWbixhjs5XEvSCkzMew-ib6IBJz2oQPQqt-gpgBfd6BLTqhWv4BIs1jIPHF2kL5ehwIUWhyoDTqRG4WTA
[b] https://00e9e64bac9233c4640453c8126aa2b5ea604c1536ab32b49c-apidata.googleusercontent.com/download/storage/v1/b/chromeos-autotest-results/o/253825438-chromeos-test%2Fchromeos6-row2-rack24-host11%2Fgraphics_HwOverlays%2Fdebug%2Fgraphics_HwOverlays.DEBUG?qk=AD5uMEunzdFiIcuA3yqsmZ8ldIUtqiWU--HQxOQwMej3XsjEKsd6L5qdZacNlzp8Y1vOPmBLPtXteiG_5Ll87iWVkf04P9ENj6QwW239KipSz45PnjBHZ3qIkwcE9wBeflyVGAExjI_KKQx6_g0IT13YHU3V8hPwPUP_ltrpzbaZhWhV5Pc_7OspgiZJg0vAKwSrDeJYafQ_6FIScnVOBeu85MynFi_fJWdXIwxDCJkfknDZIltX68SepSeb2NeSwmOS5-4jtSbFBuzLHVKGbQ3Q1_mJDf2u_YJ2Q86-sad4meHD0OcJddY3AEQyVVR5371mFy8-mvZm0vjHrhSontaS9VZtvJsQQ4Q8D2EuTreqSKV2F4n4Xd_YMhlv4hP_Fja_CoMO9OHRTneNhvTfq5f-2v_Y0bNpaSgRYfOAcxaLazBaL438YsfNpFCmCfsGI37FiMcT7WzXaymBdESb1Ha8eDebEqldPXa9Nzep5yw6MY1lPBAVaNCfdpd_KYAa8-NZTgGiqFj9L5OFyMW3hSUn28FJPLjnI5-1VdglJjmiryamDev6DA7MYKoh5kbEjkm05ITgh6XR8JAHArYoax8e3vEodmHWPOYOCkwOsttqxTOJc4SOzMiH259yF_nz_2mtv976TT8CxYZOz0tkFZ8LphCTv8DhaK15Av5jb-31puolAoH4YSyWolDnmqRCcRmqU2v5nqRcGEdXv1srxB_BumO6kfSYjIlPDvdEaPWk91tPRTA7P5VI3lAVSTOXoV6DYV8GYvchHWgZ7GcP_k8wdyfd-F347faF5txSXhlqdtudZPnwy6-10vgshRF7tSOrPrZjS7c0lqO4VvxdRo4a1URTKdi2pbypdiB30YtN1n53NekJAlaYkNQOYZ995DCOrmqWww4afDpodBvcSWzL_VfgIaBV_Q
I think it's more robust to consider crtc=(null) as "plane disabled", but other than that, Daniele is right, positions keep whatever values they had before.
Project Member

Comment 4 by bugdroid1@chromium.org, Nov 7

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/third_party/autotest/+/e3cd5fd957e2f06f553e276965d659affd709c6d

commit e3cd5fd957e2f06f553e276965d659affd709c6d
Author: Miguel Casas <mcasas@chromium.org>
Date: Wed Nov 07 04:19:28 2018

autotest/graphics: make get_num_hardware_overlays() smarter

As the associated bug describes at length, the dri debug output
contains some disabled crtc lines with lingering "crtc-pos=blabla"
entries, that confuse the get_num_hardware_overlays() routine.

This CL fixes this situation by walking the output (see e.g. [1])
plane by plane, and skipping those planes with "crtc=(null)"
association.

TEST=glinux python running a copy of the code against [1] dumps.
[1] crbug.com/900579#c2

Change-Id: Iff5a367d06d3c54884fa747bea824de68b732d8b
Bug: 900579
Reviewed-on: https://chromium-review.googlesource.com/1315749
Commit-Ready: Miguel Casas <mcasas@chromium.org>
Tested-by: Miguel Casas <mcasas@chromium.org>
Reviewed-by: Pohsien Wang <pwang@chromium.org>
Reviewed-by: Ilja H. Friedel <ihf@chromium.org>

[modify] https://crrev.com/e3cd5fd957e2f06f553e276965d659affd709c6d/client/cros/graphics/graphics_utils.py

Sign in to add a comment