From patchwork Thu Jul 13 16:25:35 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Rosin X-Patchwork-Id: 9839749 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 C8AE0602A0 for ; Fri, 14 Jul 2017 01:04:07 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D41F727F4B for ; Fri, 14 Jul 2017 01:04:07 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C8D4E28789; Fri, 14 Jul 2017 01:04:07 +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 2C27427F4B for ; Fri, 14 Jul 2017 01:04:07 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 613086E733; Fri, 14 Jul 2017 01:03:11 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on0114.outbound.protection.outlook.com [104.47.1.114]) by gabe.freedesktop.org (Postfix) with ESMTPS id 028B06E16B; Thu, 13 Jul 2017 18:57:08 +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=he8bQy24iOAVlo+R2nstSjS+MgqJra3JnJCONkJsB5o=; b=KWssieMIrS7FkAtAyrfVw+quZQbvzWDLaXTqPmgCvi76O2TwPN8+wctNsz9gu985bX6sbmg+vEIwsHLovHBD2nRf3U2rH0l+unO/Prx0mweUdk7+uNS1NWSOUlX0vkPJRCh9hc/7V6hxHRyzFGE5n+JMD7F6yAd234/XH+ukXbA= 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:36 +0000 From: Peter Rosin To: linux-kernel@vger.kernel.org Subject: [PATCH v5 11/14] drm: nouveau: remove dead code and pointless local lut storage Date: Thu, 13 Jul 2017 18:25:35 +0200 Message-Id: <20170713162538.22788-12-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: a9b05f69-5d46-4807-8e23-08d4ca0ba7f4 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-Microso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7NZpRiJNj1XCj2Me9T2zvQonpIegvsFyueUbkctwvyGn5aBFyXQbinj3aVfK8h9CifxBRWn2i17RnNuzoJnYac7/MpcBXY3y+c2kxFUx1Lk6unvBaTBYKvx80MQjmyLAsGykWOgfhXQN+xafY6k4eN9EQiHD4bjqmCjeSzlZvVEQmsUsLQh/b+ISBKm3w1dNEhy5Q6NQynhRDzhPFNRHVG2NH7SiHIOHf56rBKxajc3ofRI042NB+0WBcT58FjcisfMs4xuGwXAbTT/B8lyiETNh89PqCXX9QGCJ6A1w4iWy9tcoCo+EZwiNCP3DDFnRUCjSZWunv/tTNLX+plZD7/cvUoTXO1B8hcjgk/1KM8iLRnRyYNM2ec= 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:JUDFzJTvBNItc+0xc7EYJ9IBZDd3sQLfiOWirloC?= =?us-ascii?Q?yDaRDVbUYGLgqbr3kBQkrhOBD+y/cW1pnFt051DTxw48zxB5xt1U0GtGrPi5?= =?us-ascii?Q?p5zzdWUtz34QECiu2RDXRXYHU7+AUqH5HXt047BJiTs0ed3rsNxczippWeqm?= =?us-ascii?Q?KnKleRZEMNCPhzO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us-ascii?Q?9WGHQfjnC/Y9UIZTkr8Y1C9iyWQgpBtjul6l4ogK950b+RhgnhOKNNHVHEED?= =?us-ascii?Q?1zqQcBtFm6HJBCjX0Rb/HpIyuUQxpBdUg+aAswPhL5hDXOEOQHOdi2MNFfyl?= =?us-ascii?Q?uwoyBNqLdg/mwuAFnMRLKWoPfqGUwKcxP65RqXlXR0ECMdyNDk9PEL/mpgZT?= =?us-ascii?Q?vdZzX7/lmVnt0ts+NTv3SclH+fegbg6TkBgMThzS?= X-Forefront-PRVS: 0367A50BB1 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10019020)(7370300001)(4630300001)(6009001)(39840400002)(39400400002)(39410400002)(39450400003)(54906002)(8676002)(81166006)(5003940100001)(50226002)(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:R386FdtHjuOup1ZSAe/llqA5+H8YNw6jovq9Qkk?= =?us-ascii?Q?bvx3kJkWuqNlxSJkomqtLBl5vmg0WsH8Btxvs64r40KiUo7sV+Cc/04gd3tn?= =?us-ascii?Q?YI5gzgHyN4V5m007rq5lHzOOGMmJa2mgavRRk38D4feNt9rrJzBAwVICUH14?= =?us-ascii?Q?8Zpa2i5h6dlUske/MVgBKG+tXM75QyeB89Xp/BZQv6t1EeZdFmmQ9fHDhukC?= =?us-ascii?Q?NEtCl3KWWpdIbkw0g7GS4yT8/xarzY5rq6b3RfpXXCkLbeqpXpcfUZaJKIdr?= =?us-ascii?Q?cf7JD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13B7qJEFfCfbDjlykhMomWZr/nf+bbQ?= =?us-ascii?Q?lN2DRBTZfCfSfnK5oz8aVfhVKtyunDVHgUwd5SGajIvdkVXd7EzJACc4iXRH?= =?us-ascii?Q?r0rnsJhlDsAdFBSD0q4+Te8izmy04s/rL35k1Q/BL2eDGjndHCO/t6o2N8NO?= =?us-ascii?Q?RN5HBeQ1k41Uc2ntfdyByFVpBq0KU/ZRtEwbcGak7KO4R4epW3xUMT9k/YqC?= =?us-ascii?Q?5pY=3D?= X-Microsoft-Exchange-Diagnostics: 1; HE1PR0202MB2556; 5:tlRw5Fh2L2LTXpz3tzFBqWwenQKcr3DyfexFOeH6iVWOAdHIWQLQboY/AGShoAlrBsndVCyE/+BCJL++npdBtkMe9XQz1S/j5iBdeoTta3pGSLKdWTv7bVQsh1a6F3jvjYapRO9BjvdO2ukTle0vCBT+RyoYjxjGPSbvZLnLHRkQuDkGA1uVcSgJUo5DaQdIAEzd+zawpWJN8yrMBViPtAL//u+5clW+prpOhezzZQx0UXNTpWloIqxovNxuTrBGpxC1F5wDIgNSn8EPtuezxsuo8kY4G5dIWJwN+RbF+lls/rfNnMIdumasykwh4HsJYqXxtnzMPzOEGNoyjhN6An6VkWnbjTPDpX3aoZLjY+Tr3pgYFvmtrLBqZW5ydp5DoQlhNdmV22WxOEJeFhlDhK05q8icBl0+IdiRUtUhsl8oUgdYoOK3mqUseC3RCxuKgSJFL1emrF5LSLXeChF0wfN5vpNvTKfnhvQAXpCbPpFuTFfJYa5moqbQdOYAgoRF; 24:4TWp/a+mXUTy0gaxhc2lUtOcpfgoII0EEm0de0hAfRlr0TyqpuDG2iDqr8kGxuBtqiOCYHe8U/dU/pzi5jm6WRKY3th6Cbp9tdx+sdUxCMk= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; HE1PR0202MB2556; 7:FXUgE5apkbCegrdP5Y/8nGK0oTVV29z4WT2k4fSuBMR9gv3WfswQK4BBhgerObvIgkZVpfvtsR+LjkM+ZeC7hLaPTMuofSnGdwlR/yqtRVzTBZDrcI6eF9qkrpylZNRkPmZr3xATMccQeXpEc4u0rnNCqUr5qIaNrasbw1Pp5kWISZva3W7+ZyUxXEFT4/5A3dJzsQ04e7/X6OCRHTktOIEBEVV6RTQ7WyTN8WOR5D+IDNrUZM8s2jGxgexxNDO4LrCapaQTySmO0vI5V2V60XqlX4mAW46fjk5dkEg8Mbr+K+1yUi06+pMBOfUOMf7WH4WZ6LaBiH3xSz1WnqQFLwUhscDu+Fv8Cqhlk0cVYRvjyEnagUIjG/W0UryewvgOg0JOFOm5i/W8VdB1V3C4fjGgnQijXZ+3q71idacPxeT2pzxS3qJn29PMkNWVxy26Mkm3KcKuyeZitbmr+jQ+HAYW7Rz4idv+pFvhqUyXlQH4KjbNPmnvOGyxeXlulj9C78RIEWAIrbLv86Cn1IJwIG9qZVvRwzeyrj9wCzaRvEZOi7TgGm2MWAjGZWR8yGbtmlJIV0B36TArRYOKXPZKF1evQEe08Wn36Qbl8CyWrgmboPxJRXsiL3TSKw0DvdVD5u40L9rQDbeldgdlmMHlJzbDOiVU5zBWMPiWAbb1CjjVXF2/ZuSellhjwy3fT1/tCBjr8Scjg4FPCg+I97qTaWqUBrkNYR8ASC7kt7nlm90br3XhncTtykO26abTgyPatU/dyP7ZRsleBp041cXzu0X2SWUZdmlt9KtptQToaqs= X-OriginatorOrg: axentia.se X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Jul 2017 16:24:36.9230 (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 , dri-devel@lists.freedesktop.org, Ben Skeggs , nouveau@lists.freedesktop.org, 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 --- 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 4b4b0b496262..8f689f1f6122 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 050fcf30a0d2..b7a18fbee6dc 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 2665a078b6da..f7707849bb53 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 42a85c14aea0..2ef03ed82baa 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);