errors when executing GPU demo applications on i.MX537

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

errors when executing GPU demo applications on i.MX537

1,476 Views
dawoo
Contributor I

Hi,

I am trying to activate Gpu (3D) support on my i.MX537 development board for being able to run Qt (QtQuick) applications.

Using Buildroot I have created a kernel image (mainline 3.12.5), device tree file, rootfs

and a u-boot image. Since the mainline kernel does not include a driver for the gpus (z160 and z430)

I have ported the amd-gpu driver derived from earlier freescale kernel sources (I think it was 3.0).

I managed the driver to be initialized and probed during boot without errors.

I took oGL and EGL libs from "amd-gpu-bin-mx51-11.09.01_201112.tar.gz" and copied the files to my rootfs.

When I start one of the demos supplied with "amd-gpu-bin-mx51-11.09.01_201112.tar.gz"

the following errors are printed to console:


# /usr/bin/tiger

Press Enter key to terminate

Color formats don't match.  Falling back to copy forward swap.

tiger: /u/build/nightly_build/build/ltib/rpm/BUILD/amd-gpu-src-11.09.01/driver/build/linux/mx51/../../../../tests/vg/base_linux.c:153: CreateEGLContext: Assertion `g_egl.cxt != ((EGLContext)0)' failed.

# /usr/bin/torusknot   

Color formats don't match.  Falling back to copy forward swap.

torusknot: /u/build/nightly_build/build/ltib/rpm/BUILD/amd-gpu-src-11.09.01/driver/build/linux/mx51/../../../rb/src/rb_device.c:120: rb_device_create: Assertion `0' failed.

I get the same error with my own Qt based application.

Nothing is visualized on the display and the board hangs and has to be rebooted afterwards.

I should also mention that only 3d support is activated currently since activating 2d and 3d exceeds

available vmalloc memory space of 512MB. For each gpu the driver (in its current form) tries to allocate

(ioremap) 256MB of virtual memory space.

I assume that the error messages (the last one in each case) originate from the libs supllied with "amd-gpu-bin-mx51-11.09.01_201112.tar.gz".

Can anybody help me to understand what these error messages are supposed to mean?

Thanks.

Labels (1)
0 Kudos
6 Replies

812 Views
dawoo
Contributor I

Hi again,

I managed to solve one of the problems:

I should also mention that only 3d support is activated currently since activating 2d and 3d exceeds

available vmalloc memory space of 512MB. For each gpu the driver (in its current form) tries to allocate

(ioremap) 256MB of virtual memory space.

In kernel configuration I chose a 2G/2G memory space split between kernel and user. This way my vmalloc space size is around 1,5G and I can initialize both GPU units (2D and 3D).

# cat /proc/meminfo

MemTotal:         513984 kB

MemFree:          502624 kB

Buffers:               0 kB

Cached:             4044 kB

SwapCached:            0 kB

Active:             1980 kB

Inactive:           2644 kB

Active(anon):        608 kB

Inactive(anon):       20 kB

Active(file):       1372 kB

Inactive(file):     2624 kB

Unevictable:           0 kB

Mlocked:               0 kB

HighTotal:             0 kB

HighFree:              0 kB

LowTotal:         513984 kB

LowFree:          502624 kB

SwapTotal:             0 kB

SwapFree:              0 kB

Dirty:                 0 kB

Writeback:             0 kB

AnonPages:           596 kB

Mapped:             1104 kB

Shmem:                48 kB

Slab:               3036 kB

SReclaimable:        812 kB

SUnreclaim:         2224 kB

KernelStack:         296 kB

PageTables:          136 kB

NFS_Unstable:          0 kB

Bounce:                0 kB

WritebackTmp:          0 kB

CommitLimit:      256992 kB

Committed_AS:       2700 kB

VmallocTotal:    1548288 kB

VmallocUsed:      598204 kB

VmallocChunk:     749548 kB

The console output of the demos has slightly changed:

# /usr/bin/tiger

    Press Enter key to terminate

    Color formats don't match.  Falling back to copy forward swap.

    Color formats don't match.  Falling back to copy forward swap.

# /usr/bin/torusknot

Color formats don't match.  Falling back to copy forward swap.

torusknot: /u/build/nightly_build/build/ltib/rpm/BUILD/amd-gpu-src-11.09.01/driver/build/linux/mx51/../../../rb/src/rb_device.c:120: rb_device_create: Assertion `0' failed.

The driver still hangs up the system though. No output on display.

Thanks

0 Kudos

812 Views
dawoo
Contributor I

I found out a little bit more:

for tiger app:

     Driver hangs in function "kgsl_cmdstream_waittimestamp" called by ioctl IOCTL_KGSL_CMDSTREAM_WAITTIMESTAMP

     on execution of "device->ftbl.device_waittimestamp(device, timestamp, timeout);" (timeout is set to either a very high number or to "never")

Thanks

0 Kudos

812 Views
YixingKong
Senior Contributor IV

Andre

We are sorry for getting back to you so late. Are you still stuck with the issue? If you have somehow to resolved the issue, can we close the discussion? If you still need help, please feel free to reply with an update to this discussion.

Thanks,

Yixing

0 Kudos

812 Views
dawoo
Contributor I

Hi Yixing,

no, I was not able to solve the problem on i.MX537. To be able to continue with our project we decided to move from iMX5 to iMX6.

We are using a kernel that is based on freescale 3.0.35 kernel and are now able to execute QML-based applications.

Thanks

0 Kudos

812 Views
YixingKong
Senior Contributor IV

Andre

Thank you for notifying us about your status. We are going to close the discussion. If you still need help, please feel free to reply with an update to this discussion. If you have new issue, please create another discussion.

Thanks,

Yixing

0 Kudos

812 Views
maxmustermann
Contributor I

BIG FAT WARNING !

DO NOT use the proprietary kgsql stuff - it's BROKEN and INSECURE.

*ugly* coding (not even checking array sizes) on the one hand, but

fundamentally broken by design on the other hand. Unfixable.

[imx53] WARNING! Do NOT use the proprietary GPU drivers / KGSL stuff - MAJOR RISK!

As long as freescale doesn't tell us exactly how to program these GPUs,

consider them non-existant.

0 Kudos