CPU freq only 720 MHz OSD335x

57 views
Skip to first unread message

Filip Kotouček

unread,
Mar 23, 2018, 10:01:43 AM3/23/18
to BeagleBoard
Hello,

I have problem with setting cpu freq to 1 GHz. I'm using OSD335x RED board. I downloaded latest Beaglebone image and installed different kernel. I need to use UIO driver which is not present in latest kernel.
root@beaglebone:/# cat /etc/dogtag 
BeagleBoard.org Debian Image 2018-03-09
root@beaglebone:/# uname -a
Linux beaglebone 4.4.120-bone22 #1 Tue Mar 6 23:59:09 UTC 2018 armv7l GNU/Linux
root@beaglebone:/# cpufreq-info 
cpufrequtils 008: cpufreq-info (C) Dominik Brodowski 2004-2009
Report errors and bugs to cpu...@vger.kernel.org, please.
analyzing CPU 0:
  driver: cpufreq-dt
  CPUs which run at the same hardware frequency: 0
  CPUs which need to have their frequency coordinated by software: 0
  maximum transition latency: 300 us.
  hardware limits: 275 MHz - 720 MHz
  available frequency steps: 275 MHz, 500 MHz, 600 MHz, 720 MHz
  available cpufreq governors: conservative, ondemand, userspace, powersave, performance
  current policy: frequency should be within 275 MHz and 720 MHz.
                  The governor "ondemand" may decide which speed to use
                  within this range.
  current CPU frequency is 275 MHz (asserted by call to hardware).
  cpufreq stats: 275 MHz:98.68%, 500 MHz:0.07%, 600 MHz:0.07%, 720 MHz:1.18%  (18)
Setting frequency via cpufreq-set -f has no effect. I already tried to use DC power supply, but same result. I found that different kernels has different settings. Is it possible to change dts to fix it and force cpu to run @1 GHz?

Thanks

Robert Nelson

unread,
Mar 23, 2018, 10:06:16 AM3/23/18
to Beagle Board, koty....@gmail.com
On Fri, Mar 23, 2018 at 9:01 AM, Filip Kotouček <koty....@gmail.com> wrote:
> Hello,
>
> I have problem with setting cpu freq to 1 GHz. I'm using OSD335x RED board.
> I downloaded latest Beaglebone image and installed different kernel. I need
> to use UIO driver which is not present in latest kernel.

So this is fixed as of yesterday...


> Setting frequency via cpufreq-set -f has no effect. I already tried to use
> DC power supply, but same result. I found that different kernels has
> different settings. Is it possible to change dts to fix it and force cpu to
> run @1 GHz?

add this node:

&cpu0_opp_table {
oppnitro@1000000000 {
opp-supported-hw = <0x06 0x0100>;
};
};

Regards,

--
Robert Nelson
https://rcn-ee.com/

Filip Kotouček

unread,
Mar 23, 2018, 10:31:37 AM3/23/18
to BeagleBoard
Thanks for fast reply. I did similar change before. I decompiled am335-boneblack.dtb and changed following section to:

oppnitro@1000000000 {
                        opp-hz = <0x0 0x3b9aca00>;
                        opp-microvolt = <0x1437c8 0x13d044 0x149f4c>;
                        opp-supported-hw = <0x06 0x0100>;
};

But after reboot nothing changed. Obviously you meant to do it some other way.


Dne pátek 23. března 2018 15:06:16 UTC+1 RobertCNelson napsal(a):

Robert Nelson

unread,
Mar 23, 2018, 10:38:56 AM3/23/18
to Beagle Board, koty....@gmail.com
On Fri, Mar 23, 2018 at 9:31 AM, Filip Kotouček <koty....@gmail.com> wrote:
> Thanks for fast reply. I did similar change before. I decompiled
> am335-boneblack.dtb and changed following section to:
>
> oppnitro@1000000000 {
> opp-hz = <0x0 0x3b9aca00>;
> opp-microvolt = <0x1437c8 0x13d044 0x149f4c>;
> opp-supported-hw = <0x06 0x0100>;
> };
>
> But after reboot nothing changed. Obviously you meant to do it some other
> way.

With the move to "u-boot" overlays, that's no longer the "base" dtb in
100% case of the situations.

If you have a usb-serial adapter, plug it in and we can take a look at
what u-boot is doing.

Or randomly patch:

am335x-boneblack-uboot.dtb

the "red" can also be:

am335x-osd3358-sm-red.dtb

Filip Kotouček

unread,
Mar 23, 2018, 10:40:03 AM3/23/18
to BeagleBoard
Now I tried to modify am335x-boneblack.dtx in your dtb-rebuilder (4.4.x checkedout) and it ended with error
root@beaglebone:/home/debian/dtb-rebuilder# make all
  DTC     src/arm/am335x-boneblack.dtb
Error: src/arm/am335x-boneblack.dts:39.1-16 Label or path cpu0_opp_table not found
FATAL ERROR: Syntax error parsing input tree
Makefile:133: recipe for target 'src/arm/am335x-boneblack.dtb' failed
make[1]: *** [src/arm/am335x-boneblack.dtb] Error 1
Makefile:81: recipe for target 'all_arm' failed
make: *** [all_arm] Error 2


Dne pátek 23. března 2018 15:31:37 UTC+1 Filip Kotouček napsal(a):

Robert Nelson

unread,
Mar 23, 2018, 10:57:37 AM3/23/18
to Beagle Board, koty....@gmail.com
On Fri, Mar 23, 2018 at 9:40 AM, Filip Kotouček <koty....@gmail.com> wrote:
> Now I tried to modify am335x-boneblack.dtx in your dtb-rebuilder (4.4.x
> checkedout) and it ended with error
> root@beaglebone:/home/debian/dtb-rebuilder# make all
> DTC src/arm/am335x-boneblack.dtb
> Error: src/arm/am335x-boneblack.dts:39.1-16 Label or path cpu0_opp_table not
> found
> FATAL ERROR: Syntax error parsing input tree
> Makefile:133: recipe for target 'src/arm/am335x-boneblack.dtb' failed
> make[1]: *** [src/arm/am335x-boneblack.dtb] Error 1
> Makefile:81: recipe for target 'all_arm' failed
> make: *** [all_arm] Error 2

Not sure what you did: but it builds here..

https://github.com/RobertCNelson/dtb-rebuilder/commit/645f9ea8b2b89f9494c4474a5908a2094a126279

Regards

Filip Kotouček

unread,
Mar 23, 2018, 11:22:58 AM3/23/18
to BeagleBoard
Thanks a lot. I pulled it, install new dtbs, set the dtb in uEnv.txt and it works. 


Dne pátek 23. března 2018 15:57:37 UTC+1 RobertCNelson napsal(a):
Reply all
Reply to author
Forward
0 new messages