Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/atomic: Consitfy mode parameter to drm_atomic_set_mode_for_crtc()

drm_atomic_set_mode_for_crtc() doesn't modify the passed mode, so let's
make it const.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170518193837.393-1-ville.syrjala@linux.intel.com
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>

+2 -2
+1 -1
drivers/gpu/drm/drm_atomic.c
··· 328 328 * Zero on success, error code on failure. Cannot return -EDEADLK. 329 329 */ 330 330 int drm_atomic_set_mode_for_crtc(struct drm_crtc_state *state, 331 - struct drm_display_mode *mode) 331 + const struct drm_display_mode *mode) 332 332 { 333 333 struct drm_mode_modeinfo umode; 334 334
+1 -1
include/drm/drm_atomic.h
··· 520 520 521 521 int __must_check 522 522 drm_atomic_set_mode_for_crtc(struct drm_crtc_state *state, 523 - struct drm_display_mode *mode); 523 + const struct drm_display_mode *mode); 524 524 int __must_check 525 525 drm_atomic_set_mode_prop_for_crtc(struct drm_crtc_state *state, 526 526 struct drm_property_blob *blob);