Forums - Problem with FastRPC and signing

2 posts / 0 new
Last post
Problem with FastRPC and signing
mataninna
Join Date: 3 Oct 17
Posts: 1
Posted: Thu, 2017-10-12 11:39

Hi, I'm using a Dragon Board with pre-installed android and a Hexagon V5 dsp, with the SDK version 2.0, running on Windows 10.

I've discovered the following problems when trying to run the calculator example on the dsp processor, which worked fine locally. Here is the error message from the calculator:

 

255|root@msm8916_64:/ # ./data/calculator 0 0 100
WARNING: linker: ./data/calculator: unused DT entry: type 0x6ffffffe arg 0x610
WARNING: linker: ./data/calculator: unused DT entry: type 0x6fffffff arg 0x1
WARNING: linker: libcalculator.so: unused DT entry: type 0x6ffffffe arg 0x378
WARNING: linker: libcalculator.so: unused DT entry: type 0x6fffffff arg 0x1
- starting calculator test
- allocate 400 bytes from ION heap
- creating sequence of numbers from 0 to 99
- compute sum on the aDSP
Error: compute on aDSP failed
 
I've decided to try and investigate why it failed, then I've discovered I've skipped the signing part of the tutorial, and thought perhaps something is wrong with FastRPC.
 

1st of all, I can't generate a test signature. I've tried to run the testsig.cmd script in tools\scripts but it kept failing. I've then decided to manually execute the script, command by command. After pushing tools\elfsigner\getserial via adb and running it, I get the following error message:

root@msm8916_64:/ # ./data/getserial
WARNING: linker: ./data/getserial: unused DT entry: type 0x6ffffffe arg 0x304
WARNING: linker: ./data/getserial: unused DT entry: type 0x6fffffff arg 0x1
Could not retrieve serial num

This causes testsig.cmd to fail.

In addition, something is off about fastrpc:

​adb shell insmod /system/lib/modules/adsprpc.ko
* daemon not running. starting it now on port 5038 *
* daemon started successfully *
error: device not found

Upon further inspection, it seems that the file /system/lib/modules/adsprpc.ko doesn't exist.

Here's the output from logcat -s adsprpc:

root@msm8916_64:/ # logcat -s adsprpc
--------- beginning of system
--------- beginning of crash
--------- beginning of main
E/adsprpc ( 8816): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:148::error: -1: dev >= 0
E/adsprpc ( 8816): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:125::error: -1: dev >= 0
E/adsprpc ( 8816): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:202:/dev/adsprpc-smd device initialization error: Operation not permitted
E/adsprpc ( 8816): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:256::error: -1: dev != -1
E/adsprpc ( 8816): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:305::error: -1: 0 == (nErr = remotectl_open(name, (int*)ph, dlerrstr, sizeof(dlerrstr), &dlerr))
E/adsprpc ( 8816): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:202:/dev/adsprpc-smd device initialization error: Operation not permitted
E/adsprpc ( 8816): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:256::error: -1: dev != -1
E/adsprpc ( 8817): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:148::error: -1: dev >= 0
E/adsprpc ( 8817): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:125::error: -1: dev >= 0
E/adsprpc ( 8817): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:202:/dev/adsprpc-smd device initialization error: Operation not permitted
E/adsprpc ( 8817): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:256::error: -1: dev != -1
E/adsprpc ( 8817): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:305::error: -1: 0 == (nErr = remotectl_open(name, (int*)ph, dlerrstr, sizeof(dlerrstr), &dlerr))
E/adsprpc ( 8817): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:202:/dev/adsprpc-smd device initialization error: Operation not permitted
E/adsprpc ( 8817): vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:256::error: -1: dev != -1

I suspect that the calculator won't run on the dsp because of the problems mentioned above.

Thanks in advance for any assitance :)

  • Up0
  • Down0
michael10
Join Date: 27 Nov 17
Posts: 11
Posted: Sun, 2017-12-17 12:07

I'm in a similar situation on a handheld device - no kernel modules present and getserial failing.

From what I understand you have to load specific firmware (push_adsp.{sh,py} script) before you can access the DSP. 

Were you ever able to make progress with your issue? 

  • Up0
  • Down0
or Register

Opinions expressed in the content posted here are the personal opinions of the original authors, and do not necessarily reflect those of Qualcomm Incorporated or its subsidiaries (“Qualcomm”). The content is provided for informational purposes only and is not meant to be an endorsement or representation by Qualcomm or any other party. This site may also provide links or references to non-Qualcomm sites and resources. Qualcomm makes no representations, warranties, or other commitments whatsoever about any non-Qualcomm sites or third-party resources that may be referenced, accessible from, or linked to this site.