diff options
author | Laurent Pinchart <laurent.pinchart@ideasonboard.com> | 2012-07-17 11:56:50 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2012-07-19 21:52:38 -0400 |
commit | e811f5ae19043b2ac2c28e147a4274038e655598 (patch) | |
tree | ca2e6a30df60d0f53042df78934f406383e839bc /drivers/gpu/drm/nouveau | |
parent | 59fd415ded4aa9ac2f80ca3ac36e3a014c7e552e (diff) |
drm: Make the .mode_fixup() operations mode argument a const pointer
The passed mode must not be modified by the operation, make it const.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/nouveau')
-rw-r--r-- | drivers/gpu/drm/nouveau/nv04_crtc.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nv04_dac.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nv04_dfp.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nv17_tv.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nv50_crtc.c | 2 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nv50_dac.c | 3 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nv50_sor.c | 3 | ||||
-rw-r--r-- | drivers/gpu/drm/nouveau/nvd0_display.c | 8 |
8 files changed, 14 insertions, 10 deletions
diff --git a/drivers/gpu/drm/nouveau/nv04_crtc.c b/drivers/gpu/drm/nouveau/nv04_crtc.c index 4c31c63e5528..43accc11102f 100644 --- a/drivers/gpu/drm/nouveau/nv04_crtc.c +++ b/drivers/gpu/drm/nouveau/nv04_crtc.c | |||
@@ -215,7 +215,7 @@ nv_crtc_dpms(struct drm_crtc *crtc, int mode) | |||
215 | } | 215 | } |
216 | 216 | ||
217 | static bool | 217 | static bool |
218 | nv_crtc_mode_fixup(struct drm_crtc *crtc, struct drm_display_mode *mode, | 218 | nv_crtc_mode_fixup(struct drm_crtc *crtc, const struct drm_display_mode *mode, |
219 | struct drm_display_mode *adjusted_mode) | 219 | struct drm_display_mode *adjusted_mode) |
220 | { | 220 | { |
221 | return true; | 221 | return true; |
diff --git a/drivers/gpu/drm/nouveau/nv04_dac.c b/drivers/gpu/drm/nouveau/nv04_dac.c index 8300266ffaea..38f19479417c 100644 --- a/drivers/gpu/drm/nouveau/nv04_dac.c +++ b/drivers/gpu/drm/nouveau/nv04_dac.c | |||
@@ -332,7 +332,7 @@ nv17_dac_detect(struct drm_encoder *encoder, struct drm_connector *connector) | |||
332 | } | 332 | } |
333 | 333 | ||
334 | static bool nv04_dac_mode_fixup(struct drm_encoder *encoder, | 334 | static bool nv04_dac_mode_fixup(struct drm_encoder *encoder, |
335 | struct drm_display_mode *mode, | 335 | const struct drm_display_mode *mode, |
336 | struct drm_display_mode *adjusted_mode) | 336 | struct drm_display_mode *adjusted_mode) |
337 | { | 337 | { |
338 | if (nv04_dac_in_use(encoder)) | 338 | if (nv04_dac_in_use(encoder)) |
diff --git a/drivers/gpu/drm/nouveau/nv04_dfp.c b/drivers/gpu/drm/nouveau/nv04_dfp.c index 2258746016f8..c2675623b7cd 100644 --- a/drivers/gpu/drm/nouveau/nv04_dfp.c +++ b/drivers/gpu/drm/nouveau/nv04_dfp.c | |||
@@ -179,7 +179,7 @@ static struct drm_encoder *get_tmds_slave(struct drm_encoder *encoder) | |||
179 | } | 179 | } |
180 | 180 | ||
181 | static bool nv04_dfp_mode_fixup(struct drm_encoder *encoder, | 181 | static bool nv04_dfp_mode_fixup(struct drm_encoder *encoder, |
182 | struct drm_display_mode *mode, | 182 | const struct drm_display_mode *mode, |
183 | struct drm_display_mode *adjusted_mode) | 183 | struct drm_display_mode *adjusted_mode) |
184 | { | 184 | { |
185 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); | 185 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); |
diff --git a/drivers/gpu/drm/nouveau/nv17_tv.c b/drivers/gpu/drm/nouveau/nv17_tv.c index 696d7e7dc2a0..67be5db021f5 100644 --- a/drivers/gpu/drm/nouveau/nv17_tv.c +++ b/drivers/gpu/drm/nouveau/nv17_tv.c | |||
@@ -338,7 +338,7 @@ static int nv17_tv_mode_valid(struct drm_encoder *encoder, | |||
338 | } | 338 | } |
339 | 339 | ||
340 | static bool nv17_tv_mode_fixup(struct drm_encoder *encoder, | 340 | static bool nv17_tv_mode_fixup(struct drm_encoder *encoder, |
341 | struct drm_display_mode *mode, | 341 | const struct drm_display_mode *mode, |
342 | struct drm_display_mode *adjusted_mode) | 342 | struct drm_display_mode *adjusted_mode) |
343 | { | 343 | { |
344 | struct nv17_tv_norm_params *tv_norm = get_tv_norm(encoder); | 344 | struct nv17_tv_norm_params *tv_norm = get_tv_norm(encoder); |
diff --git a/drivers/gpu/drm/nouveau/nv50_crtc.c b/drivers/gpu/drm/nouveau/nv50_crtc.c index 97a477b3d52d..22cebd5dd694 100644 --- a/drivers/gpu/drm/nouveau/nv50_crtc.c +++ b/drivers/gpu/drm/nouveau/nv50_crtc.c | |||
@@ -527,7 +527,7 @@ nv50_crtc_commit(struct drm_crtc *crtc) | |||
527 | } | 527 | } |
528 | 528 | ||
529 | static bool | 529 | static bool |
530 | nv50_crtc_mode_fixup(struct drm_crtc *crtc, struct drm_display_mode *mode, | 530 | nv50_crtc_mode_fixup(struct drm_crtc *crtc, const struct drm_display_mode *mode, |
531 | struct drm_display_mode *adjusted_mode) | 531 | struct drm_display_mode *adjusted_mode) |
532 | { | 532 | { |
533 | return true; | 533 | return true; |
diff --git a/drivers/gpu/drm/nouveau/nv50_dac.c b/drivers/gpu/drm/nouveau/nv50_dac.c index eb216a446b89..2c36a6b92c53 100644 --- a/drivers/gpu/drm/nouveau/nv50_dac.c +++ b/drivers/gpu/drm/nouveau/nv50_dac.c | |||
@@ -175,7 +175,8 @@ nv50_dac_restore(struct drm_encoder *encoder) | |||
175 | } | 175 | } |
176 | 176 | ||
177 | static bool | 177 | static bool |
178 | nv50_dac_mode_fixup(struct drm_encoder *encoder, struct drm_display_mode *mode, | 178 | nv50_dac_mode_fixup(struct drm_encoder *encoder, |
179 | const struct drm_display_mode *mode, | ||
179 | struct drm_display_mode *adjusted_mode) | 180 | struct drm_display_mode *adjusted_mode) |
180 | { | 181 | { |
181 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); | 182 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); |
diff --git a/drivers/gpu/drm/nouveau/nv50_sor.c b/drivers/gpu/drm/nouveau/nv50_sor.c index a9514eaa74c1..93240bde891b 100644 --- a/drivers/gpu/drm/nouveau/nv50_sor.c +++ b/drivers/gpu/drm/nouveau/nv50_sor.c | |||
@@ -327,7 +327,8 @@ nv50_sor_restore(struct drm_encoder *encoder) | |||
327 | } | 327 | } |
328 | 328 | ||
329 | static bool | 329 | static bool |
330 | nv50_sor_mode_fixup(struct drm_encoder *encoder, struct drm_display_mode *mode, | 330 | nv50_sor_mode_fixup(struct drm_encoder *encoder, |
331 | const struct drm_display_mode *mode, | ||
331 | struct drm_display_mode *adjusted_mode) | 332 | struct drm_display_mode *adjusted_mode) |
332 | { | 333 | { |
333 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); | 334 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); |
diff --git a/drivers/gpu/drm/nouveau/nvd0_display.c b/drivers/gpu/drm/nouveau/nvd0_display.c index c486d3ce3c2c..d0d60e1e7f95 100644 --- a/drivers/gpu/drm/nouveau/nvd0_display.c +++ b/drivers/gpu/drm/nouveau/nvd0_display.c | |||
@@ -607,7 +607,7 @@ nvd0_crtc_commit(struct drm_crtc *crtc) | |||
607 | } | 607 | } |
608 | 608 | ||
609 | static bool | 609 | static bool |
610 | nvd0_crtc_mode_fixup(struct drm_crtc *crtc, struct drm_display_mode *mode, | 610 | nvd0_crtc_mode_fixup(struct drm_crtc *crtc, const struct drm_display_mode *mode, |
611 | struct drm_display_mode *adjusted_mode) | 611 | struct drm_display_mode *adjusted_mode) |
612 | { | 612 | { |
613 | return true; | 613 | return true; |
@@ -938,7 +938,8 @@ nvd0_dac_dpms(struct drm_encoder *encoder, int mode) | |||
938 | } | 938 | } |
939 | 939 | ||
940 | static bool | 940 | static bool |
941 | nvd0_dac_mode_fixup(struct drm_encoder *encoder, struct drm_display_mode *mode, | 941 | nvd0_dac_mode_fixup(struct drm_encoder *encoder, |
942 | const struct drm_display_mode *mode, | ||
942 | struct drm_display_mode *adjusted_mode) | 943 | struct drm_display_mode *adjusted_mode) |
943 | { | 944 | { |
944 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); | 945 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); |
@@ -1377,7 +1378,8 @@ nvd0_sor_dpms(struct drm_encoder *encoder, int mode) | |||
1377 | } | 1378 | } |
1378 | 1379 | ||
1379 | static bool | 1380 | static bool |
1380 | nvd0_sor_mode_fixup(struct drm_encoder *encoder, struct drm_display_mode *mode, | 1381 | nvd0_sor_mode_fixup(struct drm_encoder *encoder, |
1382 | const struct drm_display_mode *mode, | ||
1381 | struct drm_display_mode *adjusted_mode) | 1383 | struct drm_display_mode *adjusted_mode) |
1382 | { | 1384 | { |
1383 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); | 1385 | struct nouveau_encoder *nv_encoder = nouveau_encoder(encoder); |