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.

omapl138通过syslink和ipc进行双核通信,notify模块出现问题?



我按照syslink安装包里面的ex03_notify创建了一个 norify工程,然后在板子下加载运行

root@tl:~/notify_code/run# ./slaveloader startup DSP ../dsp/Debug/syslink_ipc.ou
t
Attached to slave procId 0.
Loading procId 0.
[ 93.076539] Assertion at Line no: 356 in /home/tarena/ti/syslink_2_21_01_05/packages/ti/syslink/utils/hlos/knl/Linux/../../../../../../ti/syslink/utils/hlos/knl/osal/Linux/OsalKfile.c: ((bytesRead / size) == (UInt32) count) : failed
Loaded file ../dsp/Debug/syslink_ipc.out on slave procId 0.
Started slave procId 0.

请问下这是什么原因造成的,谢谢,不知道如何解决

  • 可能还是用法的问题。

    先跑TI的DEMO,看看有没有问题

  • 跑TI的demo是没有问题的,我看了下OsalKfile.c文件, 是在OsalKfile_read函数中出现问题

    Int OsalKfile_read(OsalKfile_Handle fileHandle, Char *buffer, UInt32 size,UInt32 count, UInt32 *numBytes)

    {

         /* read from file */
        fs = get_fs ();
        set_fs (KERNEL_DS);

        bytesRead = fileObject->fileDesc->f_op->read(fileObject->fileDesc,
        buffer, (size * count), &(fileObject->fileDesc->f_pos));
        set_fs(fs);

        *numBytes = bytesRead;

        if (bytesRead >= 0) {
        fileObject->curPos += bytesRead;
        GT_assert (curTrace, ((bytesRead / size) == (UInt32) count));    //在这里断言提示了错误,

       }

    }

    我怀疑是不是我的可执行文件太大导致的,所以我就把我之前写的dsp功能代码都删除了

    然后重新编译,在运行就可以了,但是我看了两个.out文件的大小并没有多大差别:

    错误的大小: 5.25 MB (5,515,924 字节)

    正确的大小:4.59 MB (4,820,732 字节)

    两者差别不是太大,所以现在不知道什么原因了

  • 应该不是, 我增加了我代码的栈,还是不行,出现这个问题应该是 slaveloader 那边读取DSP程序时的问题,

    请问下,我要理解syslink库中OsalKfile_read函数的代码,是否有相关的数据手册,找了好久,一点没有结果

  • 您好,我在编译syslink的example时出现以下错误:

    # Making bin/debug/server_dsp.xe674 ...
    /home/lrz/program/ti/ccsv6/tools/compiler/c6000_7.4.7/bin/lnk6x --abi=eabi -w -q -c -m bin/debug/obj/server_dsp.xe674.map -o bin/debug/server_dsp.xe674 bin/debug/obj/main_dsp.oe674 bin/debug/obj/Server.oe674 configuro/linker.cmd -l /home/lrz/program/ti/ccsv6/tools/compiler/c6000_7.4.7/lib/rts6740_elf.lib

     undefined                                   first referenced                                                                                                   
      symbol                                         in file                                                                                                        
     ---------                                   ----------------                                                                                                   
     ti_sdo_ipc_gates_GateMPSupportNull_query__E /home/lrz/program/ti/mcsdk_1_01/syslink_2_21_01_05/examples/ex02_messageq/dsp/configuro/package/cfg/Dsp_pe674.oe674
     ti_sdo_ipc_gates_GatePeterson_query__E      /home/lrz/program/ti/mcsdk_1_01/syslink_2_21_01_05/examples/ex02_messageq/dsp/configuro/package/cfg/Dsp_pe674.oe674
     ti_sdo_ipc_heaps_HeapMemMP_isBlocking__E    /home/lrz/program/ti/mcsdk_1_01/syslink_2_21_01_05/examples/ex02_messageq/dsp/configuro/package/cfg/Dsp_pe674.oe674

    error: unresolved symbols remain
    error: errors encountered during linking; "bin/debug/server_dsp.xe674" not
       built
    makefile:50: recipe for target 'bin/debug/server_dsp.xe674' failed
    make[4]: *** [bin/debug/server_dsp.xe674] Error 1

    就是跟ipc相关的几个函数出现链接错误,请问是什么问题?

  • 你好,请问下对于案例中,你有修改products.mak吗, 方便的话,把你的修改发给我