Local Power Manager device driver unable to load on 2.6.28-omap1

Hi,

Using the OpenEmbedded dev sources, I was able to build the Codec
Engine (2.21) sources to generate the cmemk.ko, dsplinkk.ko, and
lpm_omap3530.ko drivers using the 2.6.28-omap1 kernel. The
dsplinkk.ko and cmemk.ko loaded fine without any issues but
lpm_omap3530.ko failed to load due to a few error messages of the form
" lpm_omap3530 : no symbol version for ...". Since lpm_omap3530.ko is
unable to load, the /dev/lpm0 device used to turn on and off the DSP,
is not created. So when I go to run the CE sanity test
(codec_engine_2_21\examples\apps\sanity_test\evm3530), I get the
following error:

[root@OMAP3EVM ce]# ./app.out
App-> Application started.
@0x0001390b:[T:0x40964490] ti.sdo.ce.ipc.Power - Power_on> Opening
Local Power Manager for the DSP on /dev/lpm0 FAILED
@0x000139ff:[T:0x40964490] OP - Processor_create_d> Power_on failed.
@0x00013a5a:[T:0x4001cfb0] CE - rserverOpen: can't start
'video_copy.x64P'; Processor_create failed
CEapp-> ERROR: can't open engine video_copy
App-> Application FAILED.

I believe I need to turn on the DSP by using the lpmON.xv5T utility
but since I'm unable to load the lpm driver, I'm unable to turn on the
DSP and hence, the sanity check failed to open the code engine. I
tried the other CE examples and the same problem occurs.

Does anyone know what needs to be done to the local_power_manager_1_22
source to get it work with 2.6.28-omap1 kernel? If not, is there a
way I can turn on the DSP without using lpm? Thanks.

Regards,
Andy

The lpm buildsystem is a bit quirky, you need to modprobe -f the module. TI knows about this and is looking for a solution, but lpm releases seem to be few and far iin between :frowning:

regards,

Koen

The lpm buildsystem is a bit quirky, you need to modprobe -f the
module. TI knows about this and is looking for a solution, but lpm
releases seem to be few and far iin between :frowning:

Koen, thanks, that did the job. I also had to modify lpm_driver.c so
that it would work with 2.6.28-omap1 without crashing:

changed in lpm_init

        device_create(lpm->lpm_class, NULL,
            MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
            "lpm%d", lpm->inst[i].minor);

to

        char temp_str[50];
        ...

        sprintf(temp_str, "lpm%d", lpm->inst[i].minor);
        device_create(lpm->lpm_class, NULL,
            MKDEV(lpm->inst[i].major, lpm->inst[i].minor),
            NULL, temp_str);

Regards,
Andy

Hi Andy,

I Suggest change your modification by this:

Suggested change: