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.

AM335X freq scaling problem

Other Parts Discussed in Thread: TPS65217, AM3352

I am using 3.12 and SDK7 on a custom board. My client need to have cpu frequency scaling function to save power. 

When I enable the  

<*>   Generic CPU0 cpufreq driver 

in kernel config.  The kernel keep printing 

[ 2083.693886] cpufreq_cpu0: failed to scale voltage down: -22

from the debug port. Our PMIC is TPS65217. Do you know how to get rid of this message?

-Eric

  • Biser,

    I did follow the guide that you provided, and still got the same.

    My CPU is using 600Mhz variant and would like to dynamic scale 300Mhz when CPU is not heavy loaded. When using ondemand governor, the "cpufreq_cpu0: failed to scale voltage down: -22" keep prompting out. When using userspace governor, when

    $ echo 300000 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_setspeed

    I got exactly the same message.

    The related device tree setting are as follows.

    cpus {

    cpu@0 {

    cpu0-supply = <&dcdc2_reg>;

                           /*

                            * To consider voltage drop between PMIC and SoC,

                            * tolerance value is reduced to 2% from 4% and

                            * voltage value is increased as a precaution.

                            */

                           operating-points = <

                                   /* kHz    uV */

                                   1000000 1325000

                                   800000  1260000

                                   720000  1200000

                                   600000  1100000

                                   300000   950000

                           >;

    compatible = "arm,cortex-a8";

    voltage-tolerance = <0x2>;

                          platform-opp-modifier = <&mpu_opp_modifier>;

                          clocks = <&dpll_mpu_ck>;

                           clock-names = "cpu";

    clock-latency = <0x493e0>;

    };

    };

    &tps {

    regulators {

    dcdc1_reg: regulator@0 {

    regulator-always-on;

    };

    dcdc2_reg: regulator@1 {

    /* VDD_MPU voltage limits 0.95V - 1.26V with +/-4% tolerance */

    regulator-name = "vdd_mpu";

    regulator-min-microvolt = <925000>;

    regulator-max-microvolt = <1325000>;

    regulator-boot-on;

    regulator-always-on;

    };

    dcdc3_reg: regulator@2 {

    /* VDD_CORE voltage limits 0.95V - 1.1V with +/-4% tolerance */

    regulator-name = "vdd_core";

    regulator-min-microvolt = <925000>;

    regulator-max-microvolt = <1150000>;

    regulator-boot-on;

    regulator-always-on;

    };

    ldo1_reg: regulator@3 {

    regulator-always-on;

    };

    ldo2_reg: regulator@4 {

    regulator-always-on;

    };

    ldo3_reg: regulator@5 {

    regulator-always-on;

    };

    ldo4_reg: regulator@6 {

    regulator-always-on;

    };

    };

    };

    &efuse_sma {

                   compatible = "ti,opp-omap-am3352";

           reg = <0x44e107fc 0x04          /* EFUSE_SMA */

                  0x44e10600 0x04>;        /* DEVICE_ID */

           ti,efuse-bit-enable-low;

           mpu_opp_modifier: mpu_opp_modifier {

                   opp-modifier = <

                   /* kHz   Rev                            offset  mask */

                   1000000  OPP_REV(2,1)                   0       AM33XX_EFUSE_SMA_OPP_NITRO_1GHZ_BIT

                   800000   OPP_REV(2,1)                   0       AM33XX_EFUSE_SMA_OPP_TURBO_800MHZ_BIT

                   720000   OPP_REV(2,1)                   0       AM33XX_EFUSE_SMA_OPP_120_720MHZ_BIT

                   600000   OPP_REV(2,1)                   0       AM33XX_EFUSE_SMA_OPP_100_600MHZ_BIT

                   300000   (OPP_REV(2,0) | OPP_REV(2,1))  0       0

                   1000000  OPP_REV(2,0)                   0       0

                   800000   OPP_REV(2,0)                   0       0

                   720000   (OPP_REV(1,0) | OPP_REV(2,0))  0       0

                   600000   (OPP_REV(1,0) | OPP_REV(2,0))  0       0

                   500000   (OPP_REV(1,0))                 0       0

                   275000   (OPP_REV(1,0))                 0       0

                   >;

           };

    };

    For the last part, if I change "300000   (OPP_REV(2,0) | OPP_REV(2,1))  0       0" to "300000   (OPP_REV(2,0) | OPP_REV(2,1))  0       AM33XX_EFUSE_SMA_OPP_100_300MHZ_BIT", the message will gone. However, I measured the power consumption, there is no change at all. If you change to "300000   (OPP_REV(2,0) | OPP_REV(2,1))  0       AM33XX_EFUSE_SMA_OPP_50_300MHZ_BIT" The message prompting out again.

    Could you help? Did I miss anything? Could AM3352 600Mhz PG2.1 dynamically scale OPP100 to OPP50? Any modification involved in u-boot?

    Thanks.

    -Eric