FreeBSD Bugzilla – Attachment 149319 Details for
Bug 194966
Radeon KMS driver lack power and clocks management support
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch /sys/dev/drm2/. radeonkms driver change device sclk and mclk when initializing according to drm.force_sclk and drm.force_mclk loader.conf tuneables
radeon_kms.patch (text/plain), 1.86 KB, created by
zuborg
on 2014-11-12 12:35:07 UTC
(
hide
)
Description:
Patch /sys/dev/drm2/. radeonkms driver change device sclk and mclk when initializing according to drm.force_sclk and drm.force_mclk loader.conf tuneables
Filename:
MIME Type:
Creator:
zuborg
Created:
2014-11-12 12:35:07 UTC
Size:
1.86 KB
patch
obsolete
>Index: drmP.h >=================================================================== >--- drmP.h (revision 274286) >+++ drmP.h (working copy) >@@ -1070,6 +1070,9 @@ > extern unsigned int drm_timestamp_precision; > extern unsigned int drm_timestamp_monotonic; > >+extern unsigned int drm_force_sclk; >+extern unsigned int drm_force_mclk; >+ > /* Device setup support (drm_drv.c) */ > int drm_probe(device_t kdev, drm_pci_id_list_t *idlist); > int drm_attach(device_t kdev, drm_pci_id_list_t *idlist); >Index: drm_drv.c >=================================================================== >--- drm_drv.c (revision 274286) >+++ drm_drv.c (working copy) >@@ -56,6 +56,9 @@ > unsigned int drm_vblank_offdelay = 5000; /* Default to 5000 msecs. */ > unsigned int drm_timestamp_precision = 20; /* Default to 20 usecs. */ > >+unsigned int drm_force_sclk = 0; /* MHz units */ >+unsigned int drm_force_mclk = 0; /* MHz units */ >+ > /* > * Default to use monotonic timestamps for wait-for-vblank and page-flip > * complete events. >@@ -77,6 +80,8 @@ > case MOD_LOAD: > TUNABLE_INT_FETCH("drm.debug", &drm_debug_flag); > TUNABLE_INT_FETCH("drm.notyet", &drm_notyet_flag); >+ TUNABLE_INT_FETCH("drm.force_sclk", &drm_force_sclk); >+ TUNABLE_INT_FETCH("drm.force_mclk", &drm_force_mclk); > break; > } > return (0); >Index: radeon/radeon_device.c >=================================================================== >--- radeon/radeon_device.c (revision 274286) >+++ radeon/radeon_device.c (working copy) >@@ -1138,6 +1138,15 @@ > if (r) > return r; > >+ if (drm_force_sclk > 0) { >+ rdev->pm.default_sclk = drm_force_sclk * 100; >+ radeon_set_engine_clock(rdev, rdev->pm.default_sclk); >+ } >+ if (drm_force_mclk > 0) { >+ rdev->pm.default_mclk = drm_force_mclk * 100; >+ radeon_set_memory_clock(rdev, rdev->pm.default_mclk); >+ } >+ > r = radeon_ib_ring_tests(rdev); > if (r) > DRM_ERROR("ib ring test failed (%d).\n", r);
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 194966
: 149319