From patchwork Thu Jul 13 16:25:28 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Rosin X-Patchwork-Id: 9839761 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 9A98A602A0 for ; Fri, 14 Jul 2017 01:05:39 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A5D8B2878A for ; Fri, 14 Jul 2017 01:05:39 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9A46A28774; Fri, 14 Jul 2017 01:05:39 +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 9D19C2877F for ; Fri, 14 Jul 2017 01:05:38 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 682F66E724; Fri, 14 Jul 2017 01:03:26 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from EUR01-HE1-obe.outbound.protection.outlook.com (mail-he1eur01on0121.outbound.protection.outlook.com [104.47.0.121]) by gabe.freedesktop.org (Postfix) with ESMTPS id 06E3B6E66C for ; Thu, 13 Jul 2017 16:24:33 +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=Oh4JqSpZbkpMlunn8ws9NAljBs8HEj1ZQEqvULxQsow=; b=D6Llv7GiA3R3uMhDnGVtMY5OI9WMNVwoc7q/aaooenvmRfblIOxJ/1poTUkUXHFP/WMd2kybNJYZP6Yq4EXgiVKJRD4kJLUQBbq/zvomfH2kdsAxqTluogiRH7cDVnd6NS1feHYa1cO1UYx/TYr7cmWLauG5c4Ozuc0LvF0uVdM= 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.pedanet (81.224.168.30) by HE1PR0202MB2556.eurprd02.prod.outlook.com (2603:10a6:3:90::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1261.13; Thu, 13 Jul 2017 16:24:28 +0000 From: Peter Rosin To: linux-kernel@vger.kernel.org Subject: [PATCH v5 04/14] drm: amd: remove dead code and pointless local lut storage Date: Thu, 13 Jul 2017 18:25:28 +0200 Message-Id: <20170713162538.22788-5-peda@axentia.se> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170713162538.22788-1-peda@axentia.se> References: <20170713162538.22788-1-peda@axentia.se> MIME-Version: 1.0 X-Originating-IP: [81.224.168.30] X-ClientProxiedBy: HE1PR09CA0048.eurprd09.prod.outlook.com (2603:10a6:7:3c::16) To HE1PR0202MB2556.eurprd02.prod.outlook.com (2603:10a6:3:90::9) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 74c5d4a2-0832-42c4-61af-08d4ca0ba2fb 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); SRVR:HE1PR0202MB2556; X-Microsoft-Exchange-Diagnostics: 1; HE1PR0202MB2556; 3:l9B/Y3yXCN4ED+nxrT26LO1XnH5lMhpYD7lbFua3+vLsvAQ2aroNsqit/cDQ/CaqnzfNxad9eKM1rVvaG+YF4/6htzdT3tO2Ui/v66ex9LGjJyVL5TJWWXztB6zbTF3yFqwLXhKIfuX+T31R51Z3TdqgVT6WqM+buk0y8YYcUaHCtfqToBHITKU5TdHR4QSd3el/mOlC5c5WCozK9MU7CSgVPpYxKSVOSoDS49mvQ2sUX0QqzmNms5MeP+vgjK2Oht/AZLMqnM19Pm/v7DRW1bnsHILgnuCvk2s4kUJvdv7LGVtkGYIHay84m2Ge+AXEUM9PGioXxO7es2VkpaE8zZu1rwyvJACFQ4gUg2JB0XqvXizJ2hyhMpGO2tT334ltcsQzwT/ynp1VP6FaPPPxprjzFyDMenqzWbyx7FP5H5/E3QGUDKifbk2ufs/iUgqdQinnodNc7V4rp7X6wrGaLdgVSI3goF2A6wLEz7ASR/aUhN65oVWJjy4DV14sAxjYw56H6fvStGBBOrmF6CHlBb476ujLpjSqEJ1m7WLbXvS8uk0WfYCLLidQw6GZyUzoOnHCP5shOGp98+V7vdVFMhmyRWYEwvqfS6IVP1j+tqGAXTgmiBACHHE1BvPeRIqkBPk5yvG39sQynSMqCsyY/YKGXx2DZL0bYBqGYxcwKfr5/RU2ShxgxpyK1PZWXS5OFA+Q2WzFk8ZwUKXzkJ/9lA== X-MS-TrafficTypeDiagnostic: HE1PR0202MB2556: X-Microsoft-Exchange-Diagnostics: 1; HE1PR0202MB2556; 25:wOXP5SYg/4sAhv9ZhEknbP5E1OWynoiNX/4HGkiixeiwqBxKKR1wBAxHTVTe5Fb3vPREnPal8C5ea011wH63mnGPRHdsbUay1popz08ETQw/y8xE8PN2Pj1p8WvDT+BnB70u++U73JZ7kKM8XBxn87sAU81/bAUkV+QlY5NTicH01MNRko3loTahWJcECnuogBCsLpc/WDlpvVDMGDGOnfu16s6wcGs85N33SGUMJkzZOx69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o4T+Z7OsPON2HclH9ib7XTtzbMfDg107OUcgKkfYO+toX70TJLo7ktg6LEWQNgt2BGZO0PthmSMVSaUt330F3jkZavuIxdzFVHw0/cO3SrPNDvek8rQJSz3xj4oV9OilRu5SzBbvNQAczAVITAvo+SzM3o2CxQ/POdxhAxUmOui7PJEzLom9jf1NvAs6yHcHHn4xLd723jZfLIrcR5u5lx4+q5U9zPuxbJLSEITfl2GFbNa9gQ0gBLfKKaD+evObkP8SMT6c/nt1CUyxr8JU2p857Vt86Swk8dLfM3daysvzmrqSN+OJxHaYwPDdRQ+SyTdC2dMPRjRww7NDL8MZMGOdxufxTXurD0= X-Exchange-Antispam-Report-Test: UriScan:(236129657087228); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(2017060910075)(5005006)(8121501046)(3002001)(100000703101)(100105400095)(93006095)(93001095)(10201501046)(6041248)(20161123560025)(20161123558100)(20161123555025)(20161123564025)(2016111802025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(6043046)(6072148)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:HE1PR0202MB2556; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:HE1PR0202MB2556; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; HE1PR0202MB2556; 4:u4Ny2orkHMf3nrE+YFjQzF+Gnxlky3tbLpToS5/c?= =?us-ascii?Q?2CqgDbquQOSSa6ib7pH2VONo2VlxRdWwfIsZfVuZozz2Blvhw/bcukIYqFA1?= =?us-ascii?Q?8hTOTNWAsvuw7N9nD1+GALQyQbUSIafIJx/3gLpAoeRR3fn/tmaWcuqL4AYL?= =?us-ascii?Q?XoG1BAFdpd5vYihNQf5yz+fZlqDpJw8HEiM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lqzYvzTBjC+o2cDlbmLEkTrV+NltEKuZAwRYFoxXGNXKsGersTRIm04?= =?us-ascii?Q?dXNRwDY4xc09ewtBRCk6/kzsBybKJjOfs52fvwAdxYm04RDWdAevSgXtr/6m?= =?us-ascii?Q?9uvkjEKo0BE02KQ4TKhpEwWFvIfnT85WjuDRFggDmM1jRqTrbiqEwzlecjs1?= =?us-ascii?Q?4M8Z5OXG8L4QpFvbuFQzbDUDLKEOR8aVMkZqAKnh?= X-Forefront-PRVS: 0367A50BB1 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(7370300001)(4630300001)(6009001)(39830400002)(39400400002)(39410400002)(39450400003)(54906002)(8676002)(81166006)(5003940100001)(50226002)(8666007)(6512007)(6506006)(38730400002)(110136004)(7350300001)(53936002)(6486002)(7736002)(189998001)(5660300001)(305945005)(4326008)(25786009)(2361001)(2351001)(33646002)(3846002)(6116002)(7416002)(74482002)(48376002)(50466002)(36756003)(575784001)(86362001)(76176999)(50986999)(1076002)(42186005)(2950100002)(6916009)(478600001)(66066001)(47776003)(2906002)(42262002); DIR:OUT; SFP:1102; SCL:1; SRVR:HE1PR0202MB2556; H:orc.pedanet; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; HE1PR0202MB2556; 23:Y15CcB5oapRrLzB/lK2i4G1SBMMJtbN6kVcFSVq?= =?us-ascii?Q?IwaAjZ4D0BVFu/74qWY46CUtRFNpAxDQSlx3FwR/duqRdz4L11gT5sVxRLjw?= =?us-ascii?Q?ZtxzRpCX8/A8telZFNxWKsNlJ1ox3qj98EZJ7s7uwtYCAOF1LW2vl3uE0MxQ?= =?us-ascii?Q?FKQ/OPz3RgwsFDlRME99AeXHiCTTu5cNPakzsKE8jpfi+01FV4QXiHavk8+i?= =?us-ascii?Q?Jpi60TKx+CzPatrNkg66q0/boe8AWX+45P3ZqG3OQhWHbDK7oXMNSD0NUvHt?= =?us-ascii?Q?EKSDgfK8mdp0z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v?= =?us-ascii?Q?OXude8m7Ywk0DN5ootWcb0bed7Nhki0CIsqQY+wILNgA2QRGbGm43YN7Gg7n?= =?us-ascii?Q?wBYvFV4w7sai/+bTKDoAORzAzALaKlqhE/ABtivPdZVxrTSSx7GagwujqM7u?= =?us-ascii?Q?5MWAqfJPH2oAyvAfGgJt/MsuY8QNyla7OPHN87FfRDXuxKqqEetk6vVNypRE?= =?us-ascii?Q?by5Ph/8zF7ghiT8CntGWNckGBdEHYSIFYsXf+zdfFbieAKKnOlFmpB09hKHL?= =?us-ascii?Q?KYg=3D?= X-Microsoft-Exchange-Diagnostics: 1; HE1PR0202MB2556; 5:zVrdRMLrNJhNdqL3DaC0MqbhErcr8gKim1a8Vig20h0rbzqjl6idHIkzKzl/vHv//m0UW6vLxc4U7q6gvo/zEH3/mOcn25HXhSkSk8pzsxE5KwDqxP0pUkqUzFY1lupova013xzdtZtcbtBhewXr6iue73UMLG/TrrPt+/BWT4rQ0ROTi/A2z30HH9LMdSDq1xCX/ecBVj208qCDU/rI1hjvhYJp28UyCSv+qFEulXcBVOfd9+GeiITg12TlP1lS4u9MuUhzO+1KFsdjtplH0adbbbn263pkrIDwasBWh9NIO0pSb8Ty+4dcO6Iyehj7/rQRK+re9KWOCokAGlBROA4H+CVMJS6g+99w8P3f+fDinma61z6goL2oXBSQuo7hOo9QPU78GFwopIicjv3n6PfbLWqswZ0hZzeQ8bTd3f29t/dJVdqJOg7Zf0tMyhfhCnjpOX9mCkByyYSVkCOWmex2t39h2q+BkxCHAMwNy0Y40JlZc+t6oVrGkrBLv/2a; 24:fj5xGsNypNNht5AsM1uaerFRuqQOjHUjeGzuUoAHdTMZUx9zYBELAEwxVYZeXxSbYgT9gcCDeXWiNny0r7CkFxNCVkNvboYTEj4LoFmY1os= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; HE1PR0202MB2556; 7:E1OTsUF0kk+mSnpXGNo9v12MYB+G7ZWq+DA7I36VJhkA+OPAbQuKBKGhrf4ncwnWsWzSD3Ok1nblsoxKuHkTjqVl/8GhyGDgm9YlEJwD4rLw95CSH2chBIqqG4qT4YPfVFJuJno0RgJdrIjGeT2FHKPMAoqGz461d6q1hsxHXOpFnS0LMz15DPXyagsIRhqgOlnIXzgbD+y5HXYJvl/OZMS9eG0T/xNDzGrtP7rPceS5G8pR9/xRPIRJ3iLBr2Q1vL5PUtTNd4xYwwcJMUry4OgD7//fJqI28SCXXn9lF3UoS7qDOnt/mJwsOtGLOaqhXf50GAumCscPycZSRDNxJv8cYLvZAuFI18WzKk/XULFAR4waKFQLqEC8eZ/3zWoDqH7/sy7XHYUfkSoqqZyswLRtPdrE5eOAz2m0TC3O1s8zvSG1IHjqBjdubLr30Lt2lJhm6n1f2Wh/6V5iw4+qE87roFPe18oaN1YNs+UOcdB/C2RMI5qJ/QWEm10ZRXXs6uKTr4DJE9M9O6kyGoNKoXg/iLRqR+HXslKXmVPk/J9cv9zeNLj/33SrbrQ3RKecreHnkL/skLuLo9JRPnbNHXA6POQL3Vcnv/EMGwSM/aBawZUy7apNPMA3FBq+4WVE+j0SkI3NHFZktFtEKZxj3iOA8TaUi1o7taf23h6G4Kn8tlkoIrUlwffB1cvEJxebLHt2QLdBYf87h6KTjKW/L5TdZRbkTeELyqfFvQnf3X+SFqmRN1EqXcwlKyYve5d7ngK5snva1TKeWXYVVfCtE9UwkWaMTOpbG1x+kGaojEo= X-OriginatorOrg: axentia.se X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jul 2017 16:24:28.3448 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: HE1PR0202MB2556 X-Mailman-Approved-At: Fri, 14 Jul 2017 01:03:04 +0000 Cc: Boris Brezillon , Daniel Vetter , amd-gfx@lists.freedesktop.org, =?UTF-8?q?Christian=20K=C3=B6nig?= , dri-devel@lists.freedesktop.org, Alex Deucher , 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. Acked-by: Daniel Vetter Signed-off-by: Peter Rosin Acked-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_fb.c | 24 ------------------------ drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 1 - drivers/gpu/drm/amd/amdgpu/dce_v10_0.c | 27 +++++++-------------------- drivers/gpu/drm/amd/amdgpu/dce_v11_0.c | 27 +++++++-------------------- drivers/gpu/drm/amd/amdgpu/dce_v6_0.c | 27 +++++++-------------------- drivers/gpu/drm/amd/amdgpu/dce_v8_0.c | 27 +++++++-------------------- drivers/gpu/drm/amd/amdgpu/dce_virtual.c | 23 ----------------------- 7 files changed, 28 insertions(+), 128 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_fb.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_fb.c index c0d8c6ff6380..7dc378013a42 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_fb.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_fb.c @@ -312,31 +312,7 @@ static int amdgpu_fbdev_destroy(struct drm_device *dev, struct amdgpu_fbdev *rfb return 0; } -/** Sets the color ramps on behalf of fbcon */ -static void amdgpu_crtc_fb_gamma_set(struct drm_crtc *crtc, u16 red, u16 green, - u16 blue, int regno) -{ - struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); - - amdgpu_crtc->lut_r[regno] = red >> 6; - amdgpu_crtc->lut_g[regno] = green >> 6; - amdgpu_crtc->lut_b[regno] = blue >> 6; -} - -/** Gets the color ramps on behalf of fbcon */ -static void amdgpu_crtc_fb_gamma_get(struct drm_crtc *crtc, u16 *red, u16 *green, - u16 *blue, int regno) -{ - struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); - - *red = amdgpu_crtc->lut_r[regno] << 6; - *green = amdgpu_crtc->lut_g[regno] << 6; - *blue = amdgpu_crtc->lut_b[regno] << 6; -} - static const struct drm_fb_helper_funcs amdgpu_fb_helper_funcs = { - .gamma_set = amdgpu_crtc_fb_gamma_set, - .gamma_get = amdgpu_crtc_fb_gamma_get, .fb_probe = amdgpufb_create, }; diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h index 43a9d3aec6c4..39f7eda6091e 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h @@ -369,7 +369,6 @@ struct amdgpu_atom_ss { struct amdgpu_crtc { struct drm_crtc base; int crtc_id; - u16 lut_r[256], lut_g[256], lut_b[256]; bool enabled; bool can_tile; uint32_t crtc_offset; diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c index 9f78c03a2e31..c9580235e35b 100644 --- a/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c +++ b/drivers/gpu/drm/amd/amdgpu/dce_v10_0.c @@ -2267,6 +2267,7 @@ static void dce_v10_0_crtc_load_lut(struct drm_crtc *crtc) struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); struct drm_device *dev = crtc->dev; struct amdgpu_device *adev = dev->dev_private; + u16 *r, *g, *b; int i; u32 tmp; @@ -2304,11 +2305,14 @@ static void dce_v10_0_crtc_load_lut(struct drm_crtc *crtc) WREG32(mmDC_LUT_WRITE_EN_MASK + amdgpu_crtc->crtc_offset, 0x00000007); WREG32(mmDC_LUT_RW_INDEX + amdgpu_crtc->crtc_offset, 0); + r = crtc->gamma_store; + g = r + crtc->gamma_size; + b = g + crtc->gamma_size; for (i = 0; i < 256; i++) { WREG32(mmDC_LUT_30_COLOR + amdgpu_crtc->crtc_offset, - (amdgpu_crtc->lut_r[i] << 20) | - (amdgpu_crtc->lut_g[i] << 10) | - (amdgpu_crtc->lut_b[i] << 0)); + ((*r++ & 0xffc0) << 14) | + ((*g++ & 0xffc0) << 4) | + (*b++ >> 6)); } tmp = RREG32(mmDEGAMMA_CONTROL + amdgpu_crtc->crtc_offset); @@ -2624,15 +2628,6 @@ static int dce_v10_0_crtc_gamma_set(struct drm_crtc *crtc, u16 *red, u16 *green, u16 *blue, uint32_t size, struct drm_modeset_acquire_ctx *ctx) { - struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); - int i; - - /* userspace palettes are always correct as is */ - for (i = 0; i < size; i++) { - amdgpu_crtc->lut_r[i] = red[i] >> 6; - amdgpu_crtc->lut_g[i] = green[i] >> 6; - amdgpu_crtc->lut_b[i] = blue[i] >> 6; - } dce_v10_0_crtc_load_lut(crtc); return 0; @@ -2844,14 +2839,12 @@ static const struct drm_crtc_helper_funcs dce_v10_0_crtc_helper_funcs = { .mode_set_base_atomic = dce_v10_0_crtc_set_base_atomic, .prepare = dce_v10_0_crtc_prepare, .commit = dce_v10_0_crtc_commit, - .load_lut = dce_v10_0_crtc_load_lut, .disable = dce_v10_0_crtc_disable, }; static int dce_v10_0_crtc_init(struct amdgpu_device *adev, int index) { struct amdgpu_crtc *amdgpu_crtc; - int i; amdgpu_crtc = kzalloc(sizeof(struct amdgpu_crtc) + (AMDGPUFB_CONN_LIMIT * sizeof(struct drm_connector *)), GFP_KERNEL); @@ -2869,12 +2862,6 @@ static int dce_v10_0_crtc_init(struct amdgpu_device *adev, int index) adev->ddev->mode_config.cursor_width = amdgpu_crtc->max_cursor_width; adev->ddev->mode_config.cursor_height = amdgpu_crtc->max_cursor_height; - for (i = 0; i < 256; i++) { - amdgpu_crtc->lut_r[i] = i << 2; - amdgpu_crtc->lut_g[i] = i << 2; - amdgpu_crtc->lut_b[i] = i << 2; - } - switch (amdgpu_crtc->crtc_id) { case 0: default: diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c index 4bcf01dc567a..7e14f532df59 100644 --- a/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c +++ b/drivers/gpu/drm/amd/amdgpu/dce_v11_0.c @@ -2251,6 +2251,7 @@ static void dce_v11_0_crtc_load_lut(struct drm_crtc *crtc) struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); struct drm_device *dev = crtc->dev; struct amdgpu_device *adev = dev->dev_private; + u16 *r, *g, *b; int i; u32 tmp; @@ -2282,11 +2283,14 @@ static void dce_v11_0_crtc_load_lut(struct drm_crtc *crtc) WREG32(mmDC_LUT_WRITE_EN_MASK + amdgpu_crtc->crtc_offset, 0x00000007); WREG32(mmDC_LUT_RW_INDEX + amdgpu_crtc->crtc_offset, 0); + r = crtc->gamma_store; + g = r + crtc->gamma_size; + b = g + crtc->gamma_size; for (i = 0; i < 256; i++) { WREG32(mmDC_LUT_30_COLOR + amdgpu_crtc->crtc_offset, - (amdgpu_crtc->lut_r[i] << 20) | - (amdgpu_crtc->lut_g[i] << 10) | - (amdgpu_crtc->lut_b[i] << 0)); + ((*r++ & 0xffc0) << 14) | + ((*g++ & 0xffc0) << 4) | + (*b++ >> 6)); } tmp = RREG32(mmDEGAMMA_CONTROL + amdgpu_crtc->crtc_offset); @@ -2644,15 +2648,6 @@ static int dce_v11_0_crtc_gamma_set(struct drm_crtc *crtc, u16 *red, u16 *green, u16 *blue, uint32_t size, struct drm_modeset_acquire_ctx *ctx) { - struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); - int i; - - /* userspace palettes are always correct as is */ - for (i = 0; i < size; i++) { - amdgpu_crtc->lut_r[i] = red[i] >> 6; - amdgpu_crtc->lut_g[i] = green[i] >> 6; - amdgpu_crtc->lut_b[i] = blue[i] >> 6; - } dce_v11_0_crtc_load_lut(crtc); return 0; @@ -2892,14 +2887,12 @@ static const struct drm_crtc_helper_funcs dce_v11_0_crtc_helper_funcs = { .mode_set_base_atomic = dce_v11_0_crtc_set_base_atomic, .prepare = dce_v11_0_crtc_prepare, .commit = dce_v11_0_crtc_commit, - .load_lut = dce_v11_0_crtc_load_lut, .disable = dce_v11_0_crtc_disable, }; static int dce_v11_0_crtc_init(struct amdgpu_device *adev, int index) { struct amdgpu_crtc *amdgpu_crtc; - int i; amdgpu_crtc = kzalloc(sizeof(struct amdgpu_crtc) + (AMDGPUFB_CONN_LIMIT * sizeof(struct drm_connector *)), GFP_KERNEL); @@ -2917,12 +2910,6 @@ static int dce_v11_0_crtc_init(struct amdgpu_device *adev, int index) adev->ddev->mode_config.cursor_width = amdgpu_crtc->max_cursor_width; adev->ddev->mode_config.cursor_height = amdgpu_crtc->max_cursor_height; - for (i = 0; i < 256; i++) { - amdgpu_crtc->lut_r[i] = i << 2; - amdgpu_crtc->lut_g[i] = i << 2; - amdgpu_crtc->lut_b[i] = i << 2; - } - switch (amdgpu_crtc->crtc_id) { case 0: default: diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v6_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v6_0.c index fd134a4629d7..d773b50afa60 100644 --- a/drivers/gpu/drm/amd/amdgpu/dce_v6_0.c +++ b/drivers/gpu/drm/amd/amdgpu/dce_v6_0.c @@ -2182,6 +2182,7 @@ static void dce_v6_0_crtc_load_lut(struct drm_crtc *crtc) struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); struct drm_device *dev = crtc->dev; struct amdgpu_device *adev = dev->dev_private; + u16 *r, *g, *b; int i; DRM_DEBUG_KMS("%d\n", amdgpu_crtc->crtc_id); @@ -2211,11 +2212,14 @@ static void dce_v6_0_crtc_load_lut(struct drm_crtc *crtc) WREG32(mmDC_LUT_WRITE_EN_MASK + amdgpu_crtc->crtc_offset, 0x00000007); WREG32(mmDC_LUT_RW_INDEX + amdgpu_crtc->crtc_offset, 0); + r = crtc->gamma_store; + g = r + crtc->gamma_size; + b = g + crtc->gamma_size; for (i = 0; i < 256; i++) { WREG32(mmDC_LUT_30_COLOR + amdgpu_crtc->crtc_offset, - (amdgpu_crtc->lut_r[i] << 20) | - (amdgpu_crtc->lut_g[i] << 10) | - (amdgpu_crtc->lut_b[i] << 0)); + ((*r++ & 0xffc0) << 14) | + ((*g++ & 0xffc0) << 4) | + (*b++ >> 6)); } WREG32(mmDEGAMMA_CONTROL + amdgpu_crtc->crtc_offset, @@ -2496,15 +2500,6 @@ static int dce_v6_0_crtc_gamma_set(struct drm_crtc *crtc, u16 *red, u16 *green, u16 *blue, uint32_t size, struct drm_modeset_acquire_ctx *ctx) { - struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); - int i; - - /* userspace palettes are always correct as is */ - for (i = 0; i < size; i++) { - amdgpu_crtc->lut_r[i] = red[i] >> 6; - amdgpu_crtc->lut_g[i] = green[i] >> 6; - amdgpu_crtc->lut_b[i] = blue[i] >> 6; - } dce_v6_0_crtc_load_lut(crtc); return 0; @@ -2712,14 +2707,12 @@ static const struct drm_crtc_helper_funcs dce_v6_0_crtc_helper_funcs = { .mode_set_base_atomic = dce_v6_0_crtc_set_base_atomic, .prepare = dce_v6_0_crtc_prepare, .commit = dce_v6_0_crtc_commit, - .load_lut = dce_v6_0_crtc_load_lut, .disable = dce_v6_0_crtc_disable, }; static int dce_v6_0_crtc_init(struct amdgpu_device *adev, int index) { struct amdgpu_crtc *amdgpu_crtc; - int i; amdgpu_crtc = kzalloc(sizeof(struct amdgpu_crtc) + (AMDGPUFB_CONN_LIMIT * sizeof(struct drm_connector *)), GFP_KERNEL); @@ -2737,12 +2730,6 @@ static int dce_v6_0_crtc_init(struct amdgpu_device *adev, int index) adev->ddev->mode_config.cursor_width = amdgpu_crtc->max_cursor_width; adev->ddev->mode_config.cursor_height = amdgpu_crtc->max_cursor_height; - for (i = 0; i < 256; i++) { - amdgpu_crtc->lut_r[i] = i << 2; - amdgpu_crtc->lut_g[i] = i << 2; - amdgpu_crtc->lut_b[i] = i << 2; - } - amdgpu_crtc->crtc_offset = crtc_offsets[amdgpu_crtc->crtc_id]; amdgpu_crtc->pll_id = ATOM_PPLL_INVALID; diff --git a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c index a9e869554627..4eb63f6a41ab 100644 --- a/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c +++ b/drivers/gpu/drm/amd/amdgpu/dce_v8_0.c @@ -2124,6 +2124,7 @@ static void dce_v8_0_crtc_load_lut(struct drm_crtc *crtc) struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); struct drm_device *dev = crtc->dev; struct amdgpu_device *adev = dev->dev_private; + u16 *r, *g, *b; int i; DRM_DEBUG_KMS("%d\n", amdgpu_crtc->crtc_id); @@ -2153,11 +2154,14 @@ static void dce_v8_0_crtc_load_lut(struct drm_crtc *crtc) WREG32(mmDC_LUT_WRITE_EN_MASK + amdgpu_crtc->crtc_offset, 0x00000007); WREG32(mmDC_LUT_RW_INDEX + amdgpu_crtc->crtc_offset, 0); + r = crtc->gamma_store; + g = r + crtc->gamma_size; + b = g + crtc->gamma_size; for (i = 0; i < 256; i++) { WREG32(mmDC_LUT_30_COLOR + amdgpu_crtc->crtc_offset, - (amdgpu_crtc->lut_r[i] << 20) | - (amdgpu_crtc->lut_g[i] << 10) | - (amdgpu_crtc->lut_b[i] << 0)); + ((*r++ & 0xffc0) << 14) | + ((*g++ & 0xffc0) << 4) | + (*b++ >> 6)); } WREG32(mmDEGAMMA_CONTROL + amdgpu_crtc->crtc_offset, @@ -2475,15 +2479,6 @@ static int dce_v8_0_crtc_gamma_set(struct drm_crtc *crtc, u16 *red, u16 *green, u16 *blue, uint32_t size, struct drm_modeset_acquire_ctx *ctx) { - struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); - int i; - - /* userspace palettes are always correct as is */ - for (i = 0; i < size; i++) { - amdgpu_crtc->lut_r[i] = red[i] >> 6; - amdgpu_crtc->lut_g[i] = green[i] >> 6; - amdgpu_crtc->lut_b[i] = blue[i] >> 6; - } dce_v8_0_crtc_load_lut(crtc); return 0; @@ -2702,14 +2697,12 @@ static const struct drm_crtc_helper_funcs dce_v8_0_crtc_helper_funcs = { .mode_set_base_atomic = dce_v8_0_crtc_set_base_atomic, .prepare = dce_v8_0_crtc_prepare, .commit = dce_v8_0_crtc_commit, - .load_lut = dce_v8_0_crtc_load_lut, .disable = dce_v8_0_crtc_disable, }; static int dce_v8_0_crtc_init(struct amdgpu_device *adev, int index) { struct amdgpu_crtc *amdgpu_crtc; - int i; amdgpu_crtc = kzalloc(sizeof(struct amdgpu_crtc) + (AMDGPUFB_CONN_LIMIT * sizeof(struct drm_connector *)), GFP_KERNEL); @@ -2727,12 +2720,6 @@ static int dce_v8_0_crtc_init(struct amdgpu_device *adev, int index) adev->ddev->mode_config.cursor_width = amdgpu_crtc->max_cursor_width; adev->ddev->mode_config.cursor_height = amdgpu_crtc->max_cursor_height; - for (i = 0; i < 256; i++) { - amdgpu_crtc->lut_r[i] = i << 2; - amdgpu_crtc->lut_g[i] = i << 2; - amdgpu_crtc->lut_b[i] = i << 2; - } - amdgpu_crtc->crtc_offset = crtc_offsets[amdgpu_crtc->crtc_id]; amdgpu_crtc->pll_id = ATOM_PPLL_INVALID; diff --git a/drivers/gpu/drm/amd/amdgpu/dce_virtual.c b/drivers/gpu/drm/amd/amdgpu/dce_virtual.c index 90bb08309a53..ecf34bc77a63 100644 --- a/drivers/gpu/drm/amd/amdgpu/dce_virtual.c +++ b/drivers/gpu/drm/amd/amdgpu/dce_virtual.c @@ -168,16 +168,6 @@ static int dce_virtual_crtc_gamma_set(struct drm_crtc *crtc, u16 *red, u16 *green, u16 *blue, uint32_t size, struct drm_modeset_acquire_ctx *ctx) { - struct amdgpu_crtc *amdgpu_crtc = to_amdgpu_crtc(crtc); - int i; - - /* userspace palettes are always correct as is */ - for (i = 0; i < size; i++) { - amdgpu_crtc->lut_r[i] = red[i] >> 6; - amdgpu_crtc->lut_g[i] = green[i] >> 6; - amdgpu_crtc->lut_b[i] = blue[i] >> 6; - } - return 0; } @@ -289,11 +279,6 @@ static int dce_virtual_crtc_set_base(struct drm_crtc *crtc, int x, int y, return 0; } -static void dce_virtual_crtc_load_lut(struct drm_crtc *crtc) -{ - return; -} - static int dce_virtual_crtc_set_base_atomic(struct drm_crtc *crtc, struct drm_framebuffer *fb, int x, int y, enum mode_set_atomic state) @@ -309,14 +294,12 @@ static const struct drm_crtc_helper_funcs dce_virtual_crtc_helper_funcs = { .mode_set_base_atomic = dce_virtual_crtc_set_base_atomic, .prepare = dce_virtual_crtc_prepare, .commit = dce_virtual_crtc_commit, - .load_lut = dce_virtual_crtc_load_lut, .disable = dce_virtual_crtc_disable, }; static int dce_virtual_crtc_init(struct amdgpu_device *adev, int index) { struct amdgpu_crtc *amdgpu_crtc; - int i; amdgpu_crtc = kzalloc(sizeof(struct amdgpu_crtc) + (AMDGPUFB_CONN_LIMIT * sizeof(struct drm_connector *)), GFP_KERNEL); @@ -329,12 +312,6 @@ static int dce_virtual_crtc_init(struct amdgpu_device *adev, int index) amdgpu_crtc->crtc_id = index; adev->mode_info.crtcs[index] = amdgpu_crtc; - for (i = 0; i < 256; i++) { - amdgpu_crtc->lut_r[i] = i << 2; - amdgpu_crtc->lut_g[i] = i << 2; - amdgpu_crtc->lut_b[i] = i << 2; - } - amdgpu_crtc->pll_id = ATOM_PPLL_INVALID; amdgpu_crtc->encoder = NULL; amdgpu_crtc->connector = NULL;