This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/AM3354: Application is not running with EGLS flag with platform.

Part Number: AM3354

Tool/software: Linux

I am working on AM3354 custom board.

and I have developed qt application and need to run with "-platform eglfs" but I am facing below error please do the needful.

root@am335x-evm:/tmp# ./qt_application -platform eglfs
failed to load module: /usr/lib/gbm/gbm_dri.so: cannot open shared object file: No such file or directory
failed to load module: /usr/lib/gbm/gbm_gallium_drm.so: cannot open shared object file: No such file or directory
loaded module : gbm_pvr.so
found valid GBM backend : gbm_pvr.so
PVR:(Error): OpenServices: PVRDRMOpenRender failed [0, ]
PVR:(Error): PVRSRVConnect: Unable to open connection. [0, ]
PVR:(Error): Couldn't connect to services [0, ]
Could not initialize egl display
Aborted (core dumped)

Regards,

Ronak

  • Hello Ronak,

    Could you please tell me which PSDK Linux you are using while running your application? Also, on my AM335x board, I was able to replicate your error by removing the pvrsrvkm module and running a Qt application. Please make sure the module is loaded before running your application.

    Regards,
    Krunal
  • Hello, 

    Thank You for your support.

    Before "sgx" support was disable from dts file. I have enable that support from dts.

    So I can get below log in dmesg(kernel log)

    =======================================================

    root@am335x-evm:/# dmesg | grep pvr
    [ 13.458033] Registering driver pvrsrvkm
    [ 15.609634] [drm] Initialized pvr 1.14.3699939 20110701 on minor 1

    ========================================================

     

    While running the application (Kernel version is 4.4.32)

    ========================================================

    root@am335x-evm:/tmp# ./qt_application -platform eglfs
    failed to load module: /usr/lib/gbm/gbm_dri.so: cannot open shared object file: No such file or directory
    failed to load module: /usr/lib/gbm/gbm_gallium_drm.so: cannot open shared object file: No such file or directory
    loaded module : gbm_pvr.so
    found valid GBM backend : gbm_pvr.so
    [ 197.873898] PVR_K:(Error): BridgedDispatchKM: Driver initialisation not completed yet.
    PVR:(Error): PVRSRVBridgeCall: Failed to access device. Function ID:3223086849 (strerror returns no value.). [0, ]
    PVR:(Error): PVRSRVEnumerateDevices: BridgeCall failed [0, ]
    PVR:(Error): PVRSRVConnect: Unable to enumerate devices. [0, ]
    PVR:(Error): Couldn't connect to services [0, ]
    Could not initialize egl display
    Aborted (core dumped)

    ========================================
    root@am335x-evm:/tmp# lsmod | grep pvr
    pvrsrvkm 406903 0

    Please do the needful.

    Regards,

    Ronak

  • Hi Ronak,

    I believe you also need to run the command "pvrsrvctl --start". Please refer to the following threads:

    Regards,

    Krunal

  • Hello Ronak,

    Could you please share your steps for building and installing the sgx drivers?

    Regards,
    Krunal
  • Hi Krunal,

    I have enable sgx support from the dts file. Please find below snippet for the same.

    &sgx {
    status = "okay";
    };

    And one more thing, I am running the qt application with out the "platform flag".

    Do you know which platform will be selected by default?

    Regards,

    Ronak

  • Hello Ronak,

    I believe you did not install the appropriate SGX drivers. For example, in PSDK Linux 5.01, using the top level Makefile please call the
    following commands: "make ti-sgx-ddk-km" and "make ti-sgx-ddk-km_install". This will install the corresponding SGX kernel modules in your filesystem.

    Also, if you run your application without the "-platform", wayland-egl is the default QPA.

    Regards,
    Krunal