From patchwork Thu Jul 6 12:20:45 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Rosin X-Patchwork-Id: 9829269 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 9AA6460317 for ; Fri, 7 Jul 2017 00:43:35 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8909C2852B for ; Fri, 7 Jul 2017 00:43:35 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 77E3528544; Fri, 7 Jul 2017 00:43:35 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id C5CCD1FF82 for ; Fri, 7 Jul 2017 00:43:34 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 79DEA6E6CD; Fri, 7 Jul 2017 00:43:12 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0093.outbound.protection.outlook.com [104.47.2.93]) by gabe.freedesktop.org (Postfix) with ESMTPS id EC8826E2B6; Thu, 6 Jul 2017 12:52:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axentiatech.onmicrosoft.com; s=selector1-axentia-se; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=QMp09DKM9po8bz0tXZ01H+Fn0oP8k1R/fOCnL0wKD+E=; b=iHi6JvG7I/EJAYuz1EGPBraHA92yvwMwmS57jm5PXarmPUoQfyaRoC2erxmcZAqF3ChpisKLTNUzP0sB9b6ywTd7qmkvBGMTZUMqktH2RqBqOru2YHOcwirawoS1Ieky/Z4fXohJwnnQfg6WNwNV6r3ZgKjiyUxKe+zzVTpn04w= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none; vger.kernel.org; dmarc=none action=none header.from=axentia.se; Received: from orc.lan (81.224.171.159) by AM5PR0202MB2548.eurprd02.prod.outlook.com (2603:10a6:203:6d::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1220.11; Thu, 6 Jul 2017 12:19:56 +0000 From: Peter Rosin To: linux-kernel@vger.kernel.org Subject: [PATCH v4 11/14] drm: nouveau: remove dead code and pointless local lut storage Date: Thu, 6 Jul 2017 14:20:45 +0200 Message-Id: <1499343648-29695-12-git-send-email-peda@axentia.se> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1499343648-29695-1-git-send-email-peda@axentia.se> References: <1499343648-29695-1-git-send-email-peda@axentia.se> MIME-Version: 1.0 X-Originating-IP: [81.224.171.159] X-ClientProxiedBy: VI1PR0801CA0084.eurprd08.prod.outlook.com (2603:10a6:800:7d::28) To AM5PR0202MB2548.eurprd02.prod.outlook.com (2603:10a6:203:6d::9) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: fe24830b-ad07-4789-b74d-08d4c4695157 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(300000503095)(300135400095)(201703131423075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); S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V0cnM9FnDM+iJ7wMkW99X0rAI1JFf2kngdOAi2BYJr2Ky+NxvjnYR9s+kS5SaniUo+sPQJEvlEx1+5ihx/ZhAKdD15ZdqdNKkh64+tqUqBKIuct9B1u0NPMW9dPRffA/2mjyW0LznCFBP5pQKExv6LOhijLmXCSTtFv4WfZgvKmkjpILunl6kvp1/YkoTu+ftvGGPBpEPYAjFIYOuxbnwAYlVgMpmdnNJaObWMpvFVjn6KNzYzawnymlCFFcf2pvpgp70ee3fxuMGcf5sO9WAobEMicDZs/8hypKIuNqg1x1wDoyiRJ5Hej0Z16dVPxFZOnz2Xj/Fia/i8gI6EtwlGikZZGU/XrzXgqz3e3Z+E5UU= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(236129657087228); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(2017060910047)(93006095)(93001095)(3002001)(10201501046)(100000703101)(100105400095)(6041248)(20161123564025)(20161123560025)(20161123562025)(20161123558100)(2016111802025)(20161123555025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(6072148)(6043046)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:AM5PR0202MB2548; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:AM5PR0202MB2548; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; AM5PR0202MB2548; 4:26bPMzNt9SCOxMx4zivYCVNNj0J8aLt7r+bfndE8?= =?us-ascii?Q?zUWmotlx2EDaq/V6Tobd1gwqvDZ7HttHHxBYZuzMvtSqOiFOk4iQDONO2Jdy?= =?us-ascii?Q?IIDkwx6tYDlFe9dMrEBaKfWmg/WWUobGuI4Ex+fGxZMGxgxbVTeyF8leCNAk?= =?us-ascii?Q?/GKP/28lWp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Y?= =?us-ascii?Q?TpQ3AybyLJyfE6aIrAvAYAX9aRFbueJerIJdT7Z7DjtHh9SHYNfIYCVgKMND?= =?us-ascii?Q?wUHsrjtDM8d1tH+UhQYuycS4oW4Flqhw6ulURqM1fR+F5L9yC0u0k/0MjkFx?= =?us-ascii?Q?ic3GKNXGwm01q3IMVCOI8A7ngLt1ZIKDxWgzT3CoHFRXVlA3uBBjBim66aLA?= =?us-ascii?Q?AzUQ0dELtOA2mMvLJJCFPKZDGmD6YsGJTGtAtRWX?= X-Forefront-PRVS: 03607C04F0 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(4630300001)(6009001)(39840400002)(39410400002)(39400400002)(39450400003)(6512007)(66066001)(33646002)(5660300001)(2361001)(6916009)(2351001)(478600001)(2950100002)(6666003)(54906002)(5003940100001)(38730400002)(42186005)(50226002)(47776003)(110136004)(6486002)(305945005)(50466002)(189998001)(81166006)(3846002)(76176999)(8676002)(6116002)(575784001)(2906002)(48376002)(50986999)(36756003)(4326008)(7736002)(53936002)(86362001)(6506006)(74482002)(25786009)(42262002); DIR:OUT; SFP:1102; SCL:1; SRVR:AM5PR0202MB2548; H:orc.lan; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; AM5PR0202MB2548; 23:welMcV4g4W4hGu63YpabAsevKPORWgaNe6xmNw1?= =?us-ascii?Q?NQe05jUhvBUqTcbQzl7WWjw96yyc8HZMKfWMPlAKsUoqkSPRfUDi80ExnJ0u?= =?us-ascii?Q?4jz8Tar8z160NcWZgmqjU9jOZ1LPDYcCG6KH+MidbHh9shzGRIpaSBfbJ/c0?= =?us-ascii?Q?7RbWbFkQzYDNT7V9F23fiJ+obqdo6qWe9MPA6P6X3ojoCqodzAPYl6Kl/Egm?= =?us-ascii?Q?NS1rKFjWbqrihfSPrGLG94H1jnfKqxv/w6cWzQ8qUYtS6j3q7XszHiVigQWA?= =?us-ascii?Q?pkcwe7yx/v6KEEGzukQ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DuNoP9m0HibjvH7JxsKKD2ZgtH2BCRZuiDRWcF1+h8KyY/G4yv1n9N2n2GrFINHuCkCa9LtmGqedFQNLmfdEAFLRH0ZJ9oFoSo7KWz2J0XxgzUtoph0qnr4f2AepIaXr8TQPZrD5jmMuUVDwVwfgsBy+N0WZVyaYzM3SSLGPKvV9RiduEBFFoanI9nexVMSkGl+zKaWGEET23QHMieeShx1ZhfWo/PnmrYhvYYZJCPRWDJ0Y0NmDTqr7hrHHed5XsPcnQA8tCSv5wC4k/AkSY3O+qvEe7F3kGaw0ZJLGqLG8/rKGJ5h7PwoQWLKWNrGzLryLGVy16TRWgUwS9Mwwcto73XoQd9WluBGrCWmqb4kpK6+4xFuL7Auh1FZfRiGaOWzKbnmLid20agiFauf9TsoZniMbuRjm3g9YWSecZQMG+BiIleZBtTvgPrJTkFRvZyN64wxBw6YAAgYLLKWe4xWHVuaiApEMisfKAli2g6tfchNiQpuCLCHDCAVgaUwOVZmCaBUG+D3WK5rIIBTR7VHfZ48Pvwkwz6PFsV2iMBcx6SGPGM3kTWJ28E7uZE+HipWCvH4kvzKwa/vIqpJA9ZZOD0lMbXyU59IqnLlCm1KaWs+35G4CLaMoYnizCd6rkUHu4QG1d8/NZ2ffAhDrNhA= X-OriginatorOrg: axentia.se X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Jul 2017 12:19:56.9364 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM5PR0202MB2548 X-Mailman-Approved-At: Fri, 07 Jul 2017 00:43:09 +0000 Cc: Boris Brezillon , nouveau@lists.freedesktop.org, dri-devel@lists.freedesktop.org, Ben Skeggs , Daniel Vetter , Peter Rosin X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP The redundant fb helpers .load_lut, .gamma_set and .gamma_get are no longer used. Remove the dead code and hook up the crtc .gamma_set to use the crtc gamma_store directly instead of duplicating that info locally. Signed-off-by: Peter Rosin --- drivers/gpu/drm/nouveau/dispnv04/crtc.c | 26 ++++++++------------- drivers/gpu/drm/nouveau/nouveau_crtc.h | 3 --- drivers/gpu/drm/nouveau/nouveau_fbcon.c | 22 ------------------ drivers/gpu/drm/nouveau/nv50_display.c | 40 +++++++++++---------------------- 4 files changed, 22 insertions(+), 69 deletions(-) diff --git a/drivers/gpu/drm/nouveau/dispnv04/crtc.c b/drivers/gpu/drm/nouveau/dispnv04/crtc.c index 4b4b0b4..8f689f1 100644 --- a/drivers/gpu/drm/nouveau/dispnv04/crtc.c +++ b/drivers/gpu/drm/nouveau/dispnv04/crtc.c @@ -764,13 +764,18 @@ nv_crtc_gamma_load(struct drm_crtc *crtc) struct nouveau_crtc *nv_crtc = nouveau_crtc(crtc); struct drm_device *dev = nv_crtc->base.dev; struct rgb { uint8_t r, g, b; } __attribute__((packed)) *rgbs; + u16 *r, *g, *b; int i; rgbs = (struct rgb *)nv04_display(dev)->mode_reg.crtc_reg[nv_crtc->index].DAC; + r = crtc->gamma_store; + g = r + crtc->gamma_size; + b = g + crtc->gamma_size; + for (i = 0; i < 256; i++) { - rgbs[i].r = nv_crtc->lut.r[i] >> 8; - rgbs[i].g = nv_crtc->lut.g[i] >> 8; - rgbs[i].b = nv_crtc->lut.b[i] >> 8; + rgbs[i].r = *r++ >> 8; + rgbs[i].g = *g++ >> 8; + rgbs[i].b = *b++ >> 8; } nouveau_hw_load_state_palette(dev, nv_crtc->index, &nv04_display(dev)->mode_reg); @@ -792,13 +797,6 @@ nv_crtc_gamma_set(struct drm_crtc *crtc, u16 *r, u16 *g, u16 *b, struct drm_modeset_acquire_ctx *ctx) { struct nouveau_crtc *nv_crtc = nouveau_crtc(crtc); - int i; - - for (i = 0; i < size; i++) { - nv_crtc->lut.r[i] = r[i]; - nv_crtc->lut.g[i] = g[i]; - nv_crtc->lut.b[i] = b[i]; - } /* We need to know the depth before we upload, but it's possible to * get called before a framebuffer is bound. If this is the case, @@ -1095,7 +1093,6 @@ static const struct drm_crtc_helper_funcs nv04_crtc_helper_funcs = { .mode_set = nv_crtc_mode_set, .mode_set_base = nv04_crtc_mode_set_base, .mode_set_base_atomic = nv04_crtc_mode_set_base_atomic, - .load_lut = nv_crtc_gamma_load, .disable = nv_crtc_disable, }; @@ -1103,17 +1100,12 @@ int nv04_crtc_create(struct drm_device *dev, int crtc_num) { struct nouveau_crtc *nv_crtc; - int ret, i; + int ret; nv_crtc = kzalloc(sizeof(*nv_crtc), GFP_KERNEL); if (!nv_crtc) return -ENOMEM; - for (i = 0; i < 256; i++) { - nv_crtc->lut.r[i] = i << 8; - nv_crtc->lut.g[i] = i << 8; - nv_crtc->lut.b[i] = i << 8; - } nv_crtc->lut.depth = 0; nv_crtc->index = crtc_num; diff --git a/drivers/gpu/drm/nouveau/nouveau_crtc.h b/drivers/gpu/drm/nouveau/nouveau_crtc.h index 050fcf3..b7a18fb 100644 --- a/drivers/gpu/drm/nouveau/nouveau_crtc.h +++ b/drivers/gpu/drm/nouveau/nouveau_crtc.h @@ -61,9 +61,6 @@ struct nouveau_crtc { struct { struct nouveau_bo *nvbo; - uint16_t r[256]; - uint16_t g[256]; - uint16_t b[256]; int depth; } lut; diff --git a/drivers/gpu/drm/nouveau/nouveau_fbcon.c b/drivers/gpu/drm/nouveau/nouveau_fbcon.c index 2665a07..f770784 100644 --- a/drivers/gpu/drm/nouveau/nouveau_fbcon.c +++ b/drivers/gpu/drm/nouveau/nouveau_fbcon.c @@ -278,26 +278,6 @@ nouveau_fbcon_accel_init(struct drm_device *dev) info->fbops = &nouveau_fbcon_ops; } -static void nouveau_fbcon_gamma_set(struct drm_crtc *crtc, u16 red, u16 green, - u16 blue, int regno) -{ - struct nouveau_crtc *nv_crtc = nouveau_crtc(crtc); - - nv_crtc->lut.r[regno] = red; - nv_crtc->lut.g[regno] = green; - nv_crtc->lut.b[regno] = blue; -} - -static void nouveau_fbcon_gamma_get(struct drm_crtc *crtc, u16 *red, u16 *green, - u16 *blue, int regno) -{ - struct nouveau_crtc *nv_crtc = nouveau_crtc(crtc); - - *red = nv_crtc->lut.r[regno]; - *green = nv_crtc->lut.g[regno]; - *blue = nv_crtc->lut.b[regno]; -} - static void nouveau_fbcon_zfill(struct drm_device *dev, struct nouveau_fbdev *fbcon) { @@ -467,8 +447,6 @@ void nouveau_fbcon_gpu_lockup(struct fb_info *info) } static const struct drm_fb_helper_funcs nouveau_fbcon_helper_funcs = { - .gamma_set = nouveau_fbcon_gamma_set, - .gamma_get = nouveau_fbcon_gamma_get, .fb_probe = nouveau_fbcon_create, }; diff --git a/drivers/gpu/drm/nouveau/nv50_display.c b/drivers/gpu/drm/nouveau/nv50_display.c index 42a85c1..2ef03ed 100644 --- a/drivers/gpu/drm/nouveau/nv50_display.c +++ b/drivers/gpu/drm/nouveau/nv50_display.c @@ -2204,28 +2204,29 @@ nv50_head_lut_load(struct drm_crtc *crtc) struct nv50_disp *disp = nv50_disp(crtc->dev); struct nouveau_crtc *nv_crtc = nouveau_crtc(crtc); void __iomem *lut = nvbo_kmap_obj_iovirtual(nv_crtc->lut.nvbo); + u16 *r, *g, *b; int i; - for (i = 0; i < 256; i++) { - u16 r = nv_crtc->lut.r[i] >> 2; - u16 g = nv_crtc->lut.g[i] >> 2; - u16 b = nv_crtc->lut.b[i] >> 2; + r = crtc->gamma_store; + g = r + crtc->gamma_size; + b = g + crtc->gamma_size; + for (i = 0; i < 256; i++) { if (disp->disp->oclass < GF110_DISP) { - writew(r + 0x0000, lut + (i * 0x08) + 0); - writew(g + 0x0000, lut + (i * 0x08) + 2); - writew(b + 0x0000, lut + (i * 0x08) + 4); + writew((*r++ >> 2) + 0x0000, lut + (i * 0x08) + 0); + writew((*g++ >> 2) + 0x0000, lut + (i * 0x08) + 2); + writew((*b++ >> 2) + 0x0000, lut + (i * 0x08) + 4); } else { - writew(r + 0x6000, lut + (i * 0x20) + 0); - writew(g + 0x6000, lut + (i * 0x20) + 2); - writew(b + 0x6000, lut + (i * 0x20) + 4); + /* 0x6000 interferes with the 14-bit color??? */ + writew((*r++ >> 2) + 0x6000, lut + (i * 0x20) + 0); + writew((*g++ >> 2) + 0x6000, lut + (i * 0x20) + 2); + writew((*b++ >> 2) + 0x6000, lut + (i * 0x20) + 4); } } } static const struct drm_crtc_helper_funcs nv50_head_help = { - .load_lut = nv50_head_lut_load, .atomic_check = nv50_head_atomic_check, }; @@ -2234,15 +2235,6 @@ nv50_head_gamma_set(struct drm_crtc *crtc, u16 *r, u16 *g, u16 *b, uint32_t size, struct drm_modeset_acquire_ctx *ctx) { - struct nouveau_crtc *nv_crtc = nouveau_crtc(crtc); - u32 i; - - for (i = 0; i < size; i++) { - nv_crtc->lut.r[i] = r[i]; - nv_crtc->lut.g[i] = g[i]; - nv_crtc->lut.b[i] = b[i]; - } - nv50_head_lut_load(crtc); return 0; } @@ -2340,19 +2332,13 @@ nv50_head_create(struct drm_device *dev, int index) struct nv50_base *base; struct nv50_curs *curs; struct drm_crtc *crtc; - int ret, i; + int ret; head = kzalloc(sizeof(*head), GFP_KERNEL); if (!head) return -ENOMEM; head->base.index = index; - for (i = 0; i < 256; i++) { - head->base.lut.r[i] = i << 8; - head->base.lut.g[i] = i << 8; - head->base.lut.b[i] = i << 8; - } - ret = nv50_base_new(drm, head, &base); if (ret == 0) ret = nv50_curs_new(drm, head, &curs);