FreeBSD Bugzilla – Attachment 185570 Details for
Bug 219213
powerd causing problems with ryzen
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
x86/cpufreq/hwpstate.c patch for powerd++ (not tested)
patch.txt (text/plain), 1.35 KB, created by
mailsed
on 2017-08-19 09:32:06 UTC
(
hide
)
Description:
x86/cpufreq/hwpstate.c patch for powerd++ (not tested)
Filename:
MIME Type:
Creator:
mailsed
Created:
2017-08-19 09:32:06 UTC
Size:
1.35 KB
patch
obsolete
>--- hwpstate.c.orig 2017-08-19 16:58:51.997734000 +0900 >+++ hwpstate.c 2017-08-19 17:29:43.363170000 +0900 >@@ -156,7 +156,6 @@ > static int > hwpstate_goto_pstate(device_t dev, int pstate) > { >- int i; > uint64_t msr; > int j; > int limit; >@@ -169,26 +168,11 @@ > if(limit > id) > id = limit; > >- /* >- * We are going to the same Px-state on all cpus. >- * Probably should take _PSD into account. >- */ > error = 0; >- CPU_FOREACH(i) { >- /* Bind to each cpu. */ >- thread_lock(curthread); >- sched_bind(curthread, i); >- thread_unlock(curthread); > HWPSTATE_DEBUG(dev, "setting P%d-state on cpu%d\n", > id, PCPU_GET(cpuid)); > /* Go To Px-state */ > wrmsr(MSR_AMD_10H_11H_CONTROL, id); >- } >- CPU_FOREACH(i) { >- /* Bind to each cpu. */ >- thread_lock(curthread); >- sched_bind(curthread, i); >- thread_unlock(curthread); > /* wait loop (100*100 usec is enough ?) */ > for(j = 0; j < 100; j++){ > /* get the result. not assure msr=id */ >@@ -204,10 +188,6 @@ > HWPSTATE_DEBUG(dev, "error: loop is not enough.\n"); > error = ENXIO; > } >- } >- thread_lock(curthread); >- sched_unbind(curthread); >- thread_unlock(curthread); > return (error); > } > >@@ -323,13 +303,6 @@ > uint64_t msr; > int error, type; > >- /* >- * Only hwpstate0. >- * It goes well with acpi_throttle. >- */ >- if (device_get_unit(dev) != 0) >- return (ENXIO); >- > sc = device_get_softc(dev); > sc->dev = dev; >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 219213
: 185570