Re: Modesetting (amdgpudrmfb) artifacts on RAVEN APU

2018-03-07 Thread KARBOWSKI Piotr

On 2018-03-07 22:15, Harry Wentland wrote:

amd-stg has some other patches relating to DCN pipe-split that I don't fully 
understand. We might need one or more of those.

As a workaround you can probably set 'force_single_disp_pipe_split' to 'false' 
in 'debug_defaults_drv' in dc/dcn10/dcn10_resource.c.



Thank you for the information. This indeed make it working on 
drm-fixes-4.16.



diff --git a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c 
b/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c

index 44825e2c9ebb..df5eefbcc854 100644
--- a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c
+++ b/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c
@@ -444,7 +444,7 @@ static const struct dc_debug debug_defaults_drv = {
.disable_pplib_wm_range = false,
.pplib_wm_report_mode = WM_REPORT_DEFAULT,
.pipe_split_policy = MPC_SPLIT_AVOID_MULT_DISP,
-   .force_single_disp_pipe_split = true,
+   .force_single_disp_pipe_split = false,
.disable_dcc = DCC_ENABLE,
.voltage_align_fclk = true,
.disable_stereo_support = true,


-- Piotr.
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


Re: Modesetting (amdgpudrmfb) artifacts on RAVEN APU

2018-03-07 Thread KARBOWSKI Piotr

On 2018-03-07 20:12, Harry Wentland wrote:

Thanks for testing.

What do you mean with broken video? I tried going back in the email thread but 
I'm not 100% clear what you mean by this.

BTW, drm-fixes-4.16 are fixes we intend to get into the 4.16 upstream kernel. 
amd-staging-drm-next is our development tree and quite a bit farther ahead in 
development. I'm trying to find fixes to backmerge to 4.16 to make everyone 
happy when it releases.


Like on those screenshots


https://i.imgur.com/qnDOKY7.jpg
https://i.imgur.com/XH42zit.jpg

To describe it better, lets split the screen into 4 segments

+-+-+
|  A  |  B  |
+-+-+
|  C  |  D  |
+-+-+

The screen resolution kicks in as it should, 1080p, then A displays 
proper part of screen, around 25%, then B contain a copy of what A 
displays, so the same 25% of top-left part of screen, then C and D 
remain black, if I scroll the screen a bit, C and D an get a bold 
vertical line of whatever color was on screen, if I had a white/gray 
font, it will be it, if there was some blue text, it will be blue until 
I scroll a bit more.



drm-fixes-4.16 yield the same effect as amd-staging-drm-next without 
0001-drm-amd-display-Fix-takeover-from-VGA-mode.patch, but it seems that 
htis patch is already in drm-fixes-4.16 so I am confused.


-- Piotr.
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


Re: Modesetting (amdgpudrmfb) artifacts on RAVEN APU

2018-03-07 Thread KARBOWSKI Piotr

On 2018-03-07 20:31, KARBOWSKI Piotr wrote:

On 2018-03-07 20:12, Harry Wentland wrote:

Thanks for testing.

What do you mean with broken video? I tried going back in the email 
thread but I'm not 100% clear what you mean by this.


BTW, drm-fixes-4.16 are fixes we intend to get into the 4.16 upstream 
kernel. amd-staging-drm-next is our development tree and quite a bit 
farther ahead in development. I'm trying to find fixes to backmerge to 
4.16 to make everyone happy when it releases.


Like on those screenshots


     https://i.imgur.com/qnDOKY7.jpg
     https://i.imgur.com/XH42zit.jpg

To describe it better, lets split the screen into 4 segments

+-+-+
|  A  |  B  |
+-+-+
|  C  |  D  |
+-+-+

The screen resolution kicks in as it should, 1080p, then A displays 
proper part of screen, around 25%, then B contain a copy of what A 
displays, so the same 25% of top-left part of screen, then C and D 
remain black, if I scroll the screen a bit, C and D an get a bold 
vertical line of whatever color was on screen, if I had a white/gray 
font, it will be it, if there was some blue text, it will be blue until 
I scroll a bit more.



drm-fixes-4.16 yield the same effect as amd-staging-drm-next without 
0001-drm-amd-display-Fix-takeover-from-VGA-mode.patch, but it seems that 
htis patch is already in drm-fixes-4.16 so I am confused.


I was not correct.

The drm-fixes-4.16 is a bit better It fixes half of my issue! So with 
this handy ascii art of mine


  +-+-+
  |  A  |  B  |
  +-+-+
  |  C  |  D  |
  +-+-+

A and C works, so I have full termianl on left side. but B remains copy 
of A and D either is black of have the fancy line.


I compared manually the patch that did worked for me and it seems it was 
not fully applied, the .h and .c does not look the same. Perhaps that's 
the source here.


-- Piotr.
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


Re: Modesetting (amdgpudrmfb) artifacts on RAVEN APU

2018-03-07 Thread KARBOWSKI Piotr

On 2018-03-07 17:48, KARBOWSKI Piotr wrote:

On 2018-03-07 17:14, Harry Wentland wrote:
Pushed a drm-fixes-4.16 branch (based on Alex's) to my FDO repo 
athttps://cgit.freedesktop.org/~hwentland/linux/  but I don't have a 
Raven system setup to test this at the moment.


Tom, or Piotr, would you be able to check that the fix works as 
intended on that branch?


Tested that branch, confirmed that the VGA patch is there but I got the 
original result of broken video. Rebooted few times. It seems that my 
issue was not the VGA turnover afterall. I will re-test it with vanilla 
amd-staging-drm-next of git://people.freedesktop.org/~agd5f/linux 
without the VGA patch and update you.


I re-tested original tree of git://people.freedesktop.org/~agd5f/linux 
on branch amd-staging-drm-next and got the 'double screen' glitches, 
then I applied the patch Tom sent me as the very first response to this 
thread and then it indeed fixed it. So the VGA takeover patch is needed 
it, it seems.


I triple checked and build the images and the drm-fixes-4.16 of 
git://people.freedesktop.org/~hwentland/linux does not fix the problem 
for me.


So far only amd-staging-drm-next with 
0001-drm-amd-display-Fix-takeover-from-VGA-mode.patch does the trick. 
One thing worth note is that the amd-staging-drm-next goes as `rc1` 
where yours fork Harry appears to be rc3, no idea if it's related or not.


-- Piotr.
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


Re: Modesetting (amdgpudrmfb) artifacts on RAVEN APU

2018-03-07 Thread KARBOWSKI Piotr

On 2018-03-07 17:14, Harry Wentland wrote:

Pushed a drm-fixes-4.16 branch (based on Alex's) to my FDO repo 
athttps://cgit.freedesktop.org/~hwentland/linux/  but I don't have a Raven 
system setup to test this at the moment.

Tom, or Piotr, would you be able to check that the fix works as intended on 
that branch?


Tested that branch, confirmed that the VGA patch is there but I got the 
original result of broken video. Rebooted few times. It seems that my 
issue was not the VGA turnover afterall. I will re-test it with vanilla 
amd-staging-drm-next of git://people.freedesktop.org/~agd5f/linux 
without the VGA patch and update you.


-- Piotr.
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


Re: Modesetting (amdgpudrmfb) artifacts on RAVEN APU

2018-03-06 Thread KARBOWSKI Piotr

On 2018-03-06 18:28, Tom St Denis wrote:
I routinely rebase this patch on top of our amd-staging-drm-next tree at 
fdo.


https://cgit.freedesktop.org/~agd5f/linux/log/?h=amd-staging-drm-next


Awesome.

So I used this tree, branch amd-staging-drm-next, and applied the patch 
- and my screen works now!


Is there a chance that those changes will still be included in 4.16, 
like, next rc?


-- Piotr.
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


Re: Modesetting (amdgpudrmfb) artifacts on RAVEN APU

2018-03-06 Thread KARBOWSKI Piotr

Hi,

On 2018-03-06 12:18, Tom St Denis wrote:

I believe this is the same issue I had which is a VGA handoff problem.

Can you try this patch the display team sent me?

Harry:  Will this patch be promoted in the next cycle?


What is the base for this patch? I cannot apply it on the top of any 
4.16-rc I try


1 out of 4 hunks FAILED -- saving rejects to file 
drivers/gpu/drm/amd/display/dc/dce/dce_hwseq.h.rej


is there any tree that contain this fix, that I can clone sources from?

-- Piotr.
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


Modesetting (amdgpudrmfb) artifacts on RAVEN APU

2018-03-05 Thread KARBOWSKI Piotr

Hi list,

I'd like to report a very odd screen artifacts while running both 
4.16-rc3, as well as latest 4.16-rc4 with git linux-firmware.


I am using Ryzen 2400G with the integrate Vega.

I am aware that RAVEN support is yet to be finished, however I've read 
that some people do run it already, so I figured I will report the 
issues, since other does not seems to hit it.


I have amdgpu and all it's symbols built into the kernel image, and the 
firmware added to initrammfs. The moment modesetting is initializing I 
can see that native screen resolution goes, however, I can see only like 
25% of the screen and this very top-left 25% of screen is duplicated to 
top-right. While the bottom half of screen is either black or have 
lines, usually gray, unless some text on screen had another color then 
it's green, blue, etc.


Screenshots:

https://i.imgur.com/qnDOKY7.jpg
https://i.imgur.com/XH42zit.jpg

The AMD symbols that I've enabled in kernel:

CONFIG_CPU_SUP_AMD=y
CONFIG_X86_MCE_AMD=y
CONFIG_AMD_NB=y
CONFIG_NET_VENDOR_AMD=y
CONFIG_DRM_AMDGPU=y
CONFIG_DRM_AMDGPU_SI=y
CONFIG_DRM_AMDGPU_CIK=y
CONFIG_DRM_AMD_ACP=y
CONFIG_DRM_AMD_DC=y
CONFIG_DRM_AMD_DC_FBC=y
CONFIG_DRM_AMD_DC_DCN1_0=y
CONFIG_HSA_AMD=y
CONFIG_AMD_IOMMU=y
CONFIG_AMD_IOMMU_V2=y

The kernel log that had either drm, amd or firmware in there:

[0.00] RAMDISK: [mem 0x7f88c000-0x7fff]
[0.00] ACPI: SSDT 0x9BD94908 005367 (v02 AMD 
AmdTable 0002 MSFT 0202)
[0.00] ACPI: SSDT 0x9BD99C70 00119C (v01 AMDAMD 
CPU  0001 AMD  0001)
[0.00] ACPI: CRAT 0x9BD9AE10 000810 (v01 AMDAMD 
CRAT 0001 AMD  0001)
[0.00] ACPI: CDIT 0x9BD9B620 29 (v01 AMDAMD 
CDIT 0001 AMD  0001)
[0.00] ACPI: SSDT 0x9BD9B650 002E6E (v01 AMDAMD 
AOD  0001 INTL 20120913)
[0.00] ACPI: IVRS 0x9BD9E580 D0 (v02 AMDAMD 
IVRS 0001 AMD  )
[0.00] ACPI: SSDT 0x9BD9E650 F8 (v01 AMDAMD 
PT   1000 INTL 20120913)
[0.00] ACPI: SSDT 0x9BD9E748 000E96 (v01 AMD 
AmdTable 0001 INTL 20120913)
[0.00] ACPI: SSDT 0x9BD9F5E0 000850 (v01 AMD 
AmdTable 0001 INTL 20120913)
[0.00] ACPI: SSDT 0x9BD9FE30 001993 (v01 AMD 
AmdTable 0001 INTL 20120913)
[0.00] Kernel command line: BOOT_IMAGE=/bzImage-4.16.0-rc4 
rootfstype=ext4 luks enc_root=/dev/sda2 lvm 
root=/dev/mapper/megumin-rootfs 
initrd=/initramfs.cpio.gz,/firmware-initramfs.cpio.gz
[0.00] ACPI Error: AE_ALREADY_EXISTS, (SSDT:  AMD PT) while 
loading table (20180105/tbxfload-228)
[0.08] smpboot: CPU0: AMD Ryzen 5 2400G with Radeon Vega 
Graphics (family: 0x17, model: 0x11, stepping: 0x0)

[0.08] Performance Events: Fam17h core perfctr, AMD PMU driver.
[0.101786] ACPI: [Firmware Bug]: BIOS _OSI(Linux) query ignored
[0.615782] AMD-Vi: IOMMU performance counters supported
[0.623179] AMD-Vi: Found IOMMU at :00:00.2 cap 0x40
[0.623314] AMD-Vi: Extended features (0x4f77ef22294ada):
[0.623684] AMD-Vi: Lazy IO/TLB flushing enabled
[0.624533] amd_uncore: AMD NB counters detected
[0.624666] amd_uncore: AMD LLC counters detected
[0.625076] perf/amd_iommu: Detected AMD IOMMU #0 (2 banks, 4 
counters/bank).

[0.636229] AMD IOMMUv2 driver by Joerg Roedel 
[0.637179] [drm] amdgpu kernel modesetting enabled.
[0.637409] [drm] initializing kernel modesetting (RAVEN 
0x1002:0x15DD 0x1458:0xD000 0xC6).

[0.637583] [drm] register mmio base: 0xFE50
[0.637709] [drm] register mmio size: 524288
[0.637852] [drm] probing gen 2 caps for device 1022:15db = 700d03/e
[0.638005] [drm] probing mlw for device 1022:15db = 700d03
[0.638213] [drm] VCN decode is enabled in VM mode
[0.638341] [drm] VCN encode is enabled in VM mode
[0.660265] [drm] BIOS signature incorrect 74 7
[0.660422] [drm] vm size is 262144 GB, 4 levels, block size is 
9-bit, fragment size is 9-bit
[0.660515] amdgpu :09:00.0: VRAM: 1024M 0x00F4 
- 0x00F43FFF (1024M used)
[0.660607] amdgpu :09:00.0: GTT: 1024M 0x00F5 - 
0x00F53FFF

[0.660689] [drm] Detected VRAM RAM=1024M, BAR=256M
[0.660756] [drm] RAM width 128bits UNKNOWN
[0.661653] [drm] amdgpu: 1024M of VRAM memory ready
[0.661720] [drm] amdgpu: 3072M of GTT memory ready.
[0.661793] [drm] GART: num cpu pages 262144, num gpu pages 262144
[0.662027] [drm] PCIE GART of 1024M enabled (table at 
0x00F40080).

[0.663093] [drm] use_doorbell being set to: [true]
[0.663229] [drm] Found VCN firmware Version: 1.73 Family ID: 18
[1.011745]