提交 5c8d7171 编写于 作者: A Alex Deucher 提交者: Dave Airlie

drm/kms: add crtc disable function

More explicit than dpms. Same as the encoder disable function.

Need this to explicity disconnect plls from crtcs for reuse when you
plls:crtcs ratio isn't 1:1.
Signed-off-by: NAlex Deucher <alexdeucher@gmail.com>
Signed-off-by: NDave Airlie <airlied@redhat.com>
上级 a907a2e7
...@@ -241,7 +241,10 @@ void drm_helper_disable_unused_functions(struct drm_device *dev) ...@@ -241,7 +241,10 @@ void drm_helper_disable_unused_functions(struct drm_device *dev)
struct drm_crtc_helper_funcs *crtc_funcs = crtc->helper_private; struct drm_crtc_helper_funcs *crtc_funcs = crtc->helper_private;
crtc->enabled = drm_helper_crtc_in_use(crtc); crtc->enabled = drm_helper_crtc_in_use(crtc);
if (!crtc->enabled) { if (!crtc->enabled) {
crtc_funcs->dpms(crtc, DRM_MODE_DPMS_OFF); if (crtc_funcs->disable)
(*crtc_funcs->disable)(crtc);
else
(*crtc_funcs->dpms)(crtc, DRM_MODE_DPMS_OFF);
crtc->fb = NULL; crtc->fb = NULL;
} }
} }
......
...@@ -63,6 +63,9 @@ struct drm_crtc_helper_funcs { ...@@ -63,6 +63,9 @@ struct drm_crtc_helper_funcs {
/* reload the current crtc LUT */ /* reload the current crtc LUT */
void (*load_lut)(struct drm_crtc *crtc); void (*load_lut)(struct drm_crtc *crtc);
/* disable crtc when not in use - more explicit than dpms off */
void (*disable)(struct drm_crtc *crtc);
}; };
struct drm_encoder_helper_funcs { struct drm_encoder_helper_funcs {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册