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

drm/nouveau/kms/nv50: remove code to support non-atomic connector properties

Made completely unreachable by atomic commits.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>

+9 -27
+9 -18
drivers/gpu/drm/nouveau/nouveau_connector.c
··· 767 767 struct nouveau_connector *nv_connector = nouveau_connector(connector); 768 768 struct nouveau_encoder *nv_encoder = nv_connector->detected_encoder; 769 769 struct drm_encoder *encoder = to_drm_encoder(nv_encoder); 770 - struct nouveau_crtc *nv_crtc = NULL; 771 770 int ret; 772 771 773 772 if (connector->dev->mode_config.funcs->atomic_commit) ··· 783 784 } 784 785 785 786 nv_connector->scaling_mode = asyc->scaler.mode; 786 - nv_connector->underscan = asyc->scaler.underscan.mode; 787 - nv_connector->underscan_hborder = asyc->scaler.underscan.hborder; 788 - nv_connector->underscan_vborder = asyc->scaler.underscan.vborder; 789 787 nv_connector->dithering_mode = asyc->dither.mode; 790 - nv_connector->dithering_depth = asyc->dither.depth; 791 788 792 - if (connector->encoder && connector->encoder->crtc) 793 - nv_crtc = nouveau_crtc(connector->encoder->crtc); 794 - if (!nv_crtc) 795 - return 0; 796 - 797 - nv_crtc->vibrant_hue = asyc->procamp.vibrant_hue - 90; 798 - nv_crtc->color_vibrance = asyc->procamp.color_vibrance - 100; 799 - 800 - ret = drm_crtc_helper_set_mode(&nv_crtc->base, &nv_crtc->base.mode, 801 - nv_crtc->base.x, nv_crtc->base.y, NULL); 802 - if (!ret) 803 - return -EINVAL; 789 + if (connector->encoder && connector->encoder->crtc) { 790 + ret = drm_crtc_helper_set_mode(connector->encoder->crtc, 791 + &connector->encoder->crtc->mode, 792 + connector->encoder->crtc->x, 793 + connector->encoder->crtc->y, 794 + NULL); 795 + if (!ret) 796 + return -EINVAL; 797 + } 804 798 805 799 return 0; 806 800 } ··· 1346 1354 break; 1347 1355 default: 1348 1356 nv_connector->dithering_mode = DITHERING_MODE_AUTO; 1349 - nv_connector->dithering_depth = DITHERING_DEPTH_AUTO; 1350 1357 break; 1351 1358 } 1352 1359
-5
drivers/gpu/drm/nouveau/nouveau_connector.h
··· 46 46 struct drm_dp_aux aux; 47 47 48 48 int dithering_mode; 49 - int dithering_depth; 50 49 int scaling_mode; 51 - bool scaling_full; 52 - int underscan; 53 - u32 underscan_hborder; 54 - u32 underscan_vborder; 55 50 56 51 struct nouveau_encoder *detected_encoder; 57 52 struct edid *edid;
-2
drivers/gpu/drm/nouveau/nouveau_crtc.h
··· 38 38 uint32_t dpms_saved_fp_control; 39 39 uint32_t fp_users; 40 40 int saturation; 41 - int color_vibrance; 42 - int vibrant_hue; 43 41 int sharpness; 44 42 int last_dpms; 45 43
-2
drivers/gpu/drm/nouveau/nv50_display.c
··· 2595 2595 return -ENOMEM; 2596 2596 2597 2597 head->base.index = index; 2598 - head->base.color_vibrance = 50; 2599 - head->base.vibrant_hue = 0; 2600 2598 for (i = 0; i < 256; i++) { 2601 2599 head->base.lut.r[i] = i << 8; 2602 2600 head->base.lut.g[i] = i << 8;