Announcement

Collapse
No announcement yet.

New AMD P-State Driver Headlines The Power Management Updates For Linux 5.17

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #21
    Originally posted by agd5f View Post

    If you are working a document in a word processor or doing some web browsing, there no need to ramp the the CPU to the max frequency constantly every time that task schedules. The user experience of working with that document will be the same whether or not the CPU is at the max frequency or not. As I said, the tricky part is deciding what the right algorithm is in the governor. These patches just provide the knobs. The governors still dictate the performance.
    Maybe my question was misplaced, let me rephrase it. In theory I have nothing against being able to select more frequencies, but I think it's an overly difficult task for the governor being able to select the right one depending on your workload. In real world scenarios it fails to ramp up sustained workloads which definitely need the maximum power, like encoding. In real world usage pstate equals crippling your cpu in most scenarios, effectively making a 600$ CPU worth like a 100$ one. I would like to say that I'm not against the concept but rather against the execution, but reality is that deciding the right frequency is an impossible task for the governor.
    ## VGA ##
    AMD: X1950XTX, HD3870, HD5870
    Intel: GMA45, HD3000 (Core i5 2500K)

    Comment


    • #22
      Originally posted by darkbasic View Post

      Maybe my question was misplaced, let me rephrase it. In theory I have nothing against being able to select more frequencies, but I think it's an overly difficult task for the governor being able to select the right one depending on your workload. In real world scenarios it fails to ramp up sustained workloads which definitely need the maximum power, like encoding. In real world usage pstate equals crippling your cpu in most scenarios, effectively making a 600$ CPU worth like a 100$ one. I would like to say that I'm not against the concept but rather against the execution, but reality is that deciding the right frequency is an impossible task for the governor.
      Why even offer multiple speeds? Everyone should just use CPUs with fixed clocks. Is this actually crippling in practice or are you just concerned that benchmarks are lower so it must mean that it is? The idea is that the system should have good responsiveness and usability, not the absolute maximum performance. If you want max performance, use a performance governor.

      Comment


      • #23
        Originally posted by agd5f View Post

        Why even offer multiple speeds? Everyone should just use CPUs with fixed clocks. Is this actually crippling in practice or are you just concerned that benchmarks are lower so it must mean that it is? The idea is that the system should have good responsiveness and usability, not the absolute maximum performance. If you want max performance, use a performance governor.
        My CPU is just a Zen1 so I have not been able to test P-State, but from my past experience with Intel CPUs yes, it was crippling in practice. What I mean with crippling is that it failed to ramp all the way up with some sustained workloads, while acpi-cpufreq didn't. That means I had to manually select the performance governor each time I wanted to run these workloads if I didn't want them to take longer. Hopefully these issues are solved now, but my experience with p-state has never been good.
        ## VGA ##
        AMD: X1950XTX, HD3870, HD5870
        Intel: GMA45, HD3000 (Core i5 2500K)

        Comment


        • #24
          I got it working too on a 4800H yet I cant manipulate the settings. Changing the governour via terminal doesnt work, it always goes back to ondemand. What could I be missing here?
          The min available frequency got down to 400 Mhz now, yet the cpu stays at 1,4 Ghz min frequency, never goes below that.

          PS.: I take everything back, was my own dumbness. I had a service running i nthe background that strangely kept the cpu on ondemand. Now the governour is working. Yet there are no more frequency states than before, CPU does only use the old C-States with 1,4 Ghz being the lowest. So there is no real difference in power consumption, yet.
          Last edited by ntropy; 26 January 2022, 02:45 PM.

          Comment


          • #25
            Originally posted by ntropy View Post
            I got it working too on a 4800H yet I cant manipulate the settings. Changing the governour via terminal doesnt work, it always goes back to ondemand. What could I be missing here?
            The min available frequency got down to 400 Mhz now, yet the cpu stays at 1,4 Ghz min frequency, never goes below that.

            PS.: I take everything back, was my own dumbness. I had a service running i nthe background that strangely kept the cpu on ondemand. Now the governour is working. Yet there are no more frequency states than before, CPU does only use the old C-States with 1,4 Ghz being the lowest. So there is no real difference in power consumption, yet.
            Hello there. I have Huawei Matebook laptop with AMD Ryzen 5 4600h Processor (SoC). I couldn't change scaling driver on this processor. I tried to add string in kernel console (GRUB) and then "sudo update-grub" but this doesn't take effect. So I am still using acpi-cpufreq scaling driver. Can you please give instruction of how to turn amd-pstate scaling driver. We have almost the same processors. So I think you know how to do this
            Thank you!

            Comment


            • #26
              Originally posted by ntropy View Post
              I got it working too on a 4800H yet I cant manipulate the settings
              forgot to mention that i'm using Manjaro Linux with 5.17-rc1 kernel.

              Comment


              • #27
                Originally posted by sibwase View Post

                Hello there. I have Huawei Matebook laptop with AMD Ryzen 5 4600h Processor (SoC). I couldn't change scaling driver on this processor. I tried to add string in kernel console (GRUB) and then "sudo update-grub" but this doesn't take effect. So I am still using acpi-cpufreq scaling driver. Can you please give instruction of how to turn amd-pstate scaling driver. We have almost the same processors. So I think you know how to do this
                Thank you!
                I am on arch and use paru as a package manager. I downloaded linux-mainline from the AUR with paru -G linux-mainline . This will only get you the PKGBUILD file in the directory of your choice. In that directory I opened up the PKGBUILD and changed make all to make CONFIG_X86_AMD_PSTATE=y . Then in the directory I run makepkg -si to build and install the kernel. After that you have to update grub ( grub-mkconfig -o /boot/grub/grub.cfg ) and the new kernel is installed, with amd_pstate switched on. You can just boot it then and if cpupower says you using amd_pstate its working with your processor.

                I figured that the 1,4 Ghz lowest frequency in my case is the efficiency minimum for the processor. So the nonlinear_lowest_frequency is that, when the cpu can boost most efficiently without a loss on performance. But it can effectively go down to 0,4 Ghz what would be good for sole office work. Yet the pstate driver is configured for now, to use the nonlinear freq as the set lowest. Havent found a way to change that so far but it shall be changeable with upcoming versions of the pstate driver.

                Comment


                • #28
                  Hello,
                  I'm trying this kernel https://kernel.ubuntu.com/~kernel-pp....17-rc2/amd64/

                  I can see the module in
                  Code:
                  /lib/modules/5.17.0-051700rc2-generic/kernel/drivers/cpufreq/amd_pstate.ko
                  Code:
                  #> modprobe amd_pstate --first-time
                  modprobe: ERROR: could not insert 'amd_pstate': Module already in kernel

                  cppc is present in CPUinfo:
                  Code:
                  processor : 15
                  vendor_id : AuthenticAMD
                  cpu family : 25
                  model : 80
                  model name : AMD Ryzen 9 5900HX with Radeon Graphics
                  stepping : 0
                  microcode : 0xa50000c
                  cpu MHz : 1200.000
                  cache size : 512 KB
                  physical id : 0
                  siblings : 16
                  core id : 7
                  cpu cores : 8
                  apicid : 15
                  initial apicid : 15
                  fpu : yes
                  fpu_exception : yes
                  cpuid level : 16
                  wp : yes
                  flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_tsc rep_good nopl nonstop_tsc cpuid extd_apicid aperfmperf rapl pni pclmulqdq monitor ssse3 fma cx16 sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrand lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt tce topoext perfctr_core perfctr_nb bpext perfctr_llc mwaitx cpb cat_l3 cdp_l3 hw_pstate ssbd mba ibrs ibpb stibp vmmcall fsgsbase bmi1 avx2 smep bmi2 erms invpcid cqm rdt_a rdseed adx smap clflushopt clwb sha_ni xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local clzero irperf xsaveerptr rdpru wbnoinvd cppc arat npt lbrv svm_lock nrip_save tsc_scale vmcb_clean flushbyasid decodeassists pausefilter pfthreshold avic v_vmsave_vmload vgif v_spec_ctrl umip pku ospke vaes vpclmulqdq rdpid overflow_recov succor smca fsrm
                  bugs : sysret_ss_attrs spectre_v1 spectre_v2 spec_store_bypass
                  bogomips : 6587.55
                  TLB size : 2560 4K pages
                  clflush size : 64
                  cache_alignment : 64
                  address sizes : 48 bits physical, 48 bits virtual
                  power management: ts ttp tm hwpstate cpb eff_freq_ro [13] [14]
                  BUT:

                  Code:
                  #> cat /sys/devices/system/cpu/cpufreq/policy0/scaling_driver
                  acpi-cpufreq
                  Any hint?

                  Thanks!

                  Comment


                  • #29
                    Originally posted by tbenr View Post
                    Hello,
                    I'm trying this kernel https://kernel.ubuntu.com/~kernel-pp....17-rc2/amd64/

                    I can see the module in
                    Code:
                    /lib/modules/5.17.0-051700rc2-generic/kernel/drivers/cpufreq/amd_pstate.ko
                    Code:
                    #> modprobe amd_pstate --first-time
                    modprobe: ERROR: could not insert 'amd_pstate': Module already in kernel

                    cppc is present in CPUinfo:
                    Code:
                    processor : 15
                    vendor_id : AuthenticAMD
                    cpu family : 25
                    model : 80
                    model name : AMD Ryzen 9 5900HX with Radeon Graphics
                    stepping : 0
                    microcode : 0xa50000c
                    cpu MHz : 1200.000
                    cache size : 512 KB
                    physical id : 0
                    siblings : 16
                    core id : 7
                    cpu cores : 8
                    apicid : 15
                    initial apicid : 15
                    fpu : yes
                    fpu_exception : yes
                    cpuid level : 16
                    wp : yes
                    flags : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_tsc rep_good nopl nonstop_tsc cpuid extd_apicid aperfmperf rapl pni pclmulqdq monitor ssse3 fma cx16 sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrand lahf_lm cmp_legacy svm extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw ibs skinit wdt tce topoext perfctr_core perfctr_nb bpext perfctr_llc mwaitx cpb cat_l3 cdp_l3 hw_pstate ssbd mba ibrs ibpb stibp vmmcall fsgsbase bmi1 avx2 smep bmi2 erms invpcid cqm rdt_a rdseed adx smap clflushopt clwb sha_ni xsaveopt xsavec xgetbv1 xsaves cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local clzero irperf xsaveerptr rdpru wbnoinvd cppc arat npt lbrv svm_lock nrip_save tsc_scale vmcb_clean flushbyasid decodeassists pausefilter pfthreshold avic v_vmsave_vmload vgif v_spec_ctrl umip pku ospke vaes vpclmulqdq rdpid overflow_recov succor smca fsrm
                    bugs : sysret_ss_attrs spectre_v1 spectre_v2 spec_store_bypass
                    bogomips : 6587.55
                    TLB size : 2560 4K pages
                    clflush size : 64
                    cache_alignment : 64
                    address sizes : 48 bits physical, 48 bits virtual
                    power management: ts ttp tm hwpstate cpb eff_freq_ro [13] [14]
                    BUT:

                    Code:
                    #> cat /sys/devices/system/cpu/cpufreq/policy0/scaling_driver
                    acpi-cpufreq
                    Any hint?

                    Thanks!
                    I am having the exact same issue here but with Linux tkg kernel instead

                    Comment


                    • #30
                      I recompiled the kernel (now 5.17 rc6) and set amd_pstate to y (not as Module) and it worked. I have now `amd-pstate` as a driver.
                      but unfortunately it seems that it gives me some instability on docker networking.
                      At least I know now that it will work

                      Comment

                      Working...
                      X