From patchwork Thu Nov 2 13:41:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Jonker X-Patchwork-Id: 160883 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:8f47:0:b0:403:3b70:6f57 with SMTP id j7csp362451vqu; Thu, 2 Nov 2023 06:43:00 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEdIUnrGoJoltfiyqvUnqbyMoNGGmm5sF8wQAByUMBi2+eEI1vqtbmUqdK5i3SMVJMvhQR5 X-Received: by 2002:a05:6a20:1587:b0:15d:b243:6131 with SMTP id h7-20020a056a20158700b0015db2436131mr22747669pzj.44.1698932580588; Thu, 02 Nov 2023 06:43:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698932580; cv=none; d=google.com; s=arc-20160816; b=aNtRfmuqQlEZsdOKlE4ItHXwILqY1l3mPOrzM+/m4cPitByzmXaJStM6l8cZjmbYg9 9e0qA5zK4nDX8lbZZJomJsLDQ+cpy5dqlNWGAljPZIjCuF2pNMYauSw4O8HHBKC61Ind Yi41NQd+H+PEmvo85I9xUSch4Gmw+M6+Jwuo7Tb1OjOiZuAkOV4nJ9+6O/d552CzBNAF bdR1PEBEGGlaYUtf5BWPsEb3Iqu6xohImiQp7GLStEeq/ACc0LAOmOrGkR2gAW3A63ZU d2zm+G3ZxcEwQxYhzlAxhog0tuDKO5pZKJ463gP6zRVWfc8hbkTPLmF0ixuLBPhnWDgT Bglw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :content-language:references:cc:to:subject:from:user-agent :mime-version:date:message-id:dkim-signature; bh=525ntZUU9IDbVV4Jw2CWfdlqQxiLo8Ec66BuDOeD0GA=; fh=v9EK/ZpF7mC7HytCEN1dwHNmJmndcYWW0//5MYgVSx0=; b=NFH89lVOovDd96nYqC/ycaJtZJDTZJIfO5bix/iBeR4aJmEJA8NB5v+hxH9Cu26g7K wgClELmcevcOroXruyKqmmMljb9vAw3kCatZjXLQ2QaH3Oe63I1fBeIeMHyucNNe0OC3 LrnXL3dGGEy+s4hGIIshfv9ssaEZcfq8H5URPJz/EbHUYaVKEOWKmu/ZQTUzvvSJjDET +D1jObSsrn1oTLIR7sAFi/B2f5+w9E6XIIc8i/yFIGlupZzLWcV+ymhkFJvalZ/+kTCl s6pmV7G7OdXI2Ek+vx92onBh4ZPG5LayuccUoyPv/hau2D3L8MZP3V2VgqZtNXBcw1Tu 3DZg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=HOPp+UT1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id u186-20020a6379c3000000b005b22561c968si1778426pgc.499.2023.11.02.06.42.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 Nov 2023 06:43:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=HOPp+UT1; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 6117A808FBD6; Thu, 2 Nov 2023 06:42:36 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229513AbjKBNl4 (ORCPT + 36 others); Thu, 2 Nov 2023 09:41:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54500 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1376595AbjKBNly (ORCPT ); Thu, 2 Nov 2023 09:41:54 -0400 Received: from mail-ej1-x634.google.com (mail-ej1-x634.google.com [IPv6:2a00:1450:4864:20::634]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BB989A6 for ; Thu, 2 Nov 2023 06:41:51 -0700 (PDT) Received: by mail-ej1-x634.google.com with SMTP id a640c23a62f3a-9d2e6c8b542so140217266b.0 for ; Thu, 02 Nov 2023 06:41:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1698932510; x=1699537310; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=525ntZUU9IDbVV4Jw2CWfdlqQxiLo8Ec66BuDOeD0GA=; b=HOPp+UT1mZycwWWMFCveZaaACVEW6VvvEe1EdoJjjwOCm149DGB60L54q8m+JvKAb2 EP8UVQ0NWre/HRbQnfYfMeWRPPzmSJOcdf2TbYEK1kwtJ6v/hsoemS9KZ2+AhrZt2bzu D5zKZk1MiHJniuWAuST3kAlOtwCnlEbfA+Hn/lJd5iIu4Wr6yc/VapXjl7c9XGK+UiIM MmpFHGpSgsas9f6A4vGSHKdWhO1+qca0S7e8t3Gj+3zoK0/HwANz3CX3tJ0Uw2NlDzZz DBH83t3YLKoZzLHygs1KETxpjffTzQfWLZw815CwSheSlNVJQ6/fazqx+PbQ6E6hWXdy ozXA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698932510; x=1699537310; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=525ntZUU9IDbVV4Jw2CWfdlqQxiLo8Ec66BuDOeD0GA=; b=Ypn9ZWSAl4XOJe9wmCsOJBcZZmFswwMC9yA5pyh1CJMAJ5Efs3izEvmUufkXWHGByy dX4wr4pmEadFjsBODl6zOEnXi8qqKH3mf9QTnFYw2OvgJ2dbBAli6twf/YWecVPzx9aP /kUj4wN0yxZmEgvugUlxpaaR/6lOOsyBwI4EjdyMMOcjouvw4oCR3wJNrW386kqOKlMu 08PCeDFNt9sUdvBEzZcuRMq9k/FUrwgFCrp97UZXuJSW5ywpOC2fBarQSQMCFAvJt/lN 29wJkteIVUwL1KCxD8mApJSonDgHgmcJ6DnMRzE7tdWEZdI9F1amAttAiXXSvsvWqyi2 ZdqA== X-Gm-Message-State: AOJu0YwxrDpXaR+RtCSn3vWyUty3E9Wg64ctFlT/1/eRXsYLlwaLsKNm 89axOQ3kQo8xIhnpBiBXSUz/ubYKjVA= X-Received: by 2002:a17:906:eec3:b0:9b2:b153:925 with SMTP id wu3-20020a170906eec300b009b2b1530925mr3895676ejb.21.1698932509891; Thu, 02 Nov 2023 06:41:49 -0700 (PDT) Received: from [192.168.2.1] (81-204-249-205.fixed.kpn.net. [81.204.249.205]) by smtp.gmail.com with ESMTPSA id hb9-20020a170906b88900b009adcb6c0f0esm1157638ejb.193.2023.11.02.06.41.49 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 02 Nov 2023 06:41:49 -0700 (PDT) Message-ID: <5649ac03-db92-42a9-d86a-76dfa1af7c64@gmail.com> Date: Thu, 2 Nov 2023 14:41:48 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 From: Johan Jonker Subject: [PATCH v1 1/4] drm/rockchip: rk3066_hdmi: Remove useless mode_fixup To: hjc@rock-chips.com, heiko@sntech.de Cc: airlied@gmail.com, daniel@ffwll.ch, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org References: Content-Language: en-US In-Reply-To: X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 02 Nov 2023 06:42:36 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1781459929432922623 X-GMAIL-MSGID: 1781459929432922623 The mode_fixup implementation doesn't do anything, so we can simply remove it. Signed-off-by: Johan Jonker --- drivers/gpu/drm/rockchip/rk3066_hdmi.c | 9 --------- 1 file changed, 9 deletions(-) -- 2.39.2 diff --git a/drivers/gpu/drm/rockchip/rk3066_hdmi.c b/drivers/gpu/drm/rockchip/rk3066_hdmi.c index fa6e592e0276..5c269081c691 100644 --- a/drivers/gpu/drm/rockchip/rk3066_hdmi.c +++ b/drivers/gpu/drm/rockchip/rk3066_hdmi.c @@ -434,14 +434,6 @@ static void rk3066_hdmi_encoder_disable(struct drm_encoder *encoder) rk3066_hdmi_set_power_mode(hdmi, HDMI_SYS_POWER_MODE_A); } -static bool -rk3066_hdmi_encoder_mode_fixup(struct drm_encoder *encoder, - const struct drm_display_mode *mode, - struct drm_display_mode *adj_mode) -{ - return true; -} - static int rk3066_hdmi_encoder_atomic_check(struct drm_encoder *encoder, struct drm_crtc_state *crtc_state, @@ -459,7 +451,6 @@ static const struct drm_encoder_helper_funcs rk3066_hdmi_encoder_helper_funcs = { .enable = rk3066_hdmi_encoder_enable, .disable = rk3066_hdmi_encoder_disable, - .mode_fixup = rk3066_hdmi_encoder_mode_fixup, .mode_set = rk3066_hdmi_encoder_mode_set, .atomic_check = rk3066_hdmi_encoder_atomic_check, }; From patchwork Thu Nov 2 13:42:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Jonker X-Patchwork-Id: 160882 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:8f47:0:b0:403:3b70:6f57 with SMTP id j7csp362398vqu; Thu, 2 Nov 2023 06:42:56 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGt5b94Hh0OqkS38YhB2wtgUgkqgQKzzewgRZ1GyBlPqcg2UgElRQ+5Y4lNClN6uMijFeEU X-Received: by 2002:a05:6a00:1356:b0:6bd:705b:56fb with SMTP id k22-20020a056a00135600b006bd705b56fbmr17719344pfu.6.1698932575810; Thu, 02 Nov 2023 06:42:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698932575; cv=none; d=google.com; s=arc-20160816; b=fjn/fXN+VTHU0dYrUFY5I8tQRzgfmyR3XLveRkdv36R576drpXnAZ4A/BSUMS5zDzZ EZdt+Rhwhl1YNbvo97ojLAG85Hoy2hsy0kYOzGeta2IN6sNYCKB3OyO9Mxte0glJfg8t H3g/XurIvOI9DQzcqgwz1cs6FgG5xsGSjDa8cOnJiMvpZEXhc4s0qrF/UM2a+wHpRILj pE4gXFqJBecqUNOFA60ujcUjBCmgicx/juZCZWyGXZQxa72UlZM6aLZEm4dpDonP1gke FhAFk+Fp+2soxjWuQ7M15oi7sPgzb4cASaMLMV5ESeEYgqfIyqBoGx2Zj8qYq1Gb0AGp AT1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :content-language:references:cc:to:subject:from:user-agent :mime-version:date:message-id:dkim-signature; bh=lK/vWnmM0KVaM6vCg3VvvClqSJH14OWzepShm2ndJ8I=; fh=v9EK/ZpF7mC7HytCEN1dwHNmJmndcYWW0//5MYgVSx0=; b=Zeu6BudBh8K4Zu/RCgHrBuStSzSkxFjhDzL2WEZPHrIfdL8NPm6GECQTch1td7+C3J s+M070sMjYSdzcFkdPOw3NxVZYRjvlkCBK+PyaDOjAA+xi1zLFAdUlTLsd4x6pEVBPW+ nTtYwe9jRdEchoSDvAvPxL++4PrRuR77c+HxWxxxhjVxfRlOYcQPvR1PoXmxo6G8W1Bw j83x29qN4SkjR+qIeMEXtSpK8iyYxsvumX/V36+sWQgj1RCuhnj6WfRfW8Yajjtd7Huh WRzm0CkDBeubwnaevT3Hpzfbr0z1qrygyU0kvZH685w2sdnYq2CFAqOZBi/kATTS4c4P YHew== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=A6mE6ntv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from fry.vger.email (fry.vger.email. [23.128.96.38]) by mx.google.com with ESMTPS id b1-20020a056a00114100b0069100706960si3627963pfm.116.2023.11.02.06.42.55 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 Nov 2023 06:42:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) client-ip=23.128.96.38; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=A6mE6ntv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.38 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id 28B91807649F; Thu, 2 Nov 2023 06:42:53 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376641AbjKBNmQ (ORCPT + 36 others); Thu, 2 Nov 2023 09:42:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55018 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1376635AbjKBNmO (ORCPT ); Thu, 2 Nov 2023 09:42:14 -0400 Received: from mail-ed1-x531.google.com (mail-ed1-x531.google.com [IPv6:2a00:1450:4864:20::531]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D0F70188 for ; Thu, 2 Nov 2023 06:42:07 -0700 (PDT) Received: by mail-ed1-x531.google.com with SMTP id 4fb4d7f45d1cf-5230a22cfd1so1580958a12.1 for ; Thu, 02 Nov 2023 06:42:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1698932526; x=1699537326; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=lK/vWnmM0KVaM6vCg3VvvClqSJH14OWzepShm2ndJ8I=; b=A6mE6ntvC9vlzZR47HhVci31Isma4vrFimhXY7SYGw2wBqrmN8y54wQ2U4J3L9jtFU uCPbXvUmYMhV8tAYPtv41H5MzvXnBv1t2c0f43P0Ekg9wP6iHNkiMhjnBlTShoW5J+2t zejFycYglfYZYJpoeSVMxs5WKlANe5Ui6mqUJKwY5+O/4W6G2osA0uoxFX8mQ4q0S6sG f3mtqHroQqhQ/cH4UXgW0NQbijJi/pCGvs/ciOoZTFN4TWgFHytjBPpGX5fBuuz/HrDw rk/tCi4g+qYS0/FXBzq5wzC5T3SFzv1olvIds9Beq6z1/Z5jO5a0SkFrHf3r06r89rUW Ilow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698932526; x=1699537326; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=lK/vWnmM0KVaM6vCg3VvvClqSJH14OWzepShm2ndJ8I=; b=FL0wx2oy+NxImGbiHkHaaumLb754dn/Ffdjd7kEDeYSdsgVZdGEnZuGpDy7HEHfWQn A5EBcKISkmwqNMzqK4zF5IMETS+TKBLsKj7dokdv6dQ4RCYJyp4J5w76hfURNo7byLZO 0VppvMi7VOvKCCndYmbHF2Ux+gi1+wP/rlKwcJ52LZ0qucI0CosYnCqNJDMxEGOVebr0 PUvtXBoLiyCRqGHTuij/8ZUyz37cLLqpqKZvDBcuUxEKxsIcEBzV86ILfiJoYlkVBvPz OiB861sMpkLrcAkKzW0j4ZH9slgxtubTIKL37CObNF5sSqkj8UNlp4Xpb1wz4LgvBRnG sSpw== X-Gm-Message-State: AOJu0YxmBH0nBlfu+Ldvqtw0ho6zhK2C9Oud6UQWZS6veD/Iy0bJ3BES ejBkt0y3mKEfVIB+Q4REzqg= X-Received: by 2002:a50:9544:0:b0:543:595a:8280 with SMTP id v4-20020a509544000000b00543595a8280mr7749934eda.37.1698932526017; Thu, 02 Nov 2023 06:42:06 -0700 (PDT) Received: from [192.168.2.1] (81-204-249-205.fixed.kpn.net. [81.204.249.205]) by smtp.gmail.com with ESMTPSA id q32-20020a05640224a000b0054130b1bc77sm2347915eda.51.2023.11.02.06.42.05 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 02 Nov 2023 06:42:05 -0700 (PDT) Message-ID: <034c3446-d619-f4c3-3aaa-ab51dc19d07f@gmail.com> Date: Thu, 2 Nov 2023 14:42:04 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 From: Johan Jonker Subject: [PATCH v1 2/4] drm/rockchip: rk3066_hdmi: Switch encoder hooks to atomic To: hjc@rock-chips.com, heiko@sntech.de Cc: airlied@gmail.com, daniel@ffwll.ch, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org References: Content-Language: en-US In-Reply-To: X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Thu, 02 Nov 2023 06:42:53 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1781459925057399218 X-GMAIL-MSGID: 1781459925057399218 The rk3066_hdmi encoder still uses the non atomic variants of enable and disable. Convert to their atomic equivalents. In atomic mode there is no need to save the adjusted mode, so remove the mode_set function. Signed-off-by: Johan Jonker --- drivers/gpu/drm/rockchip/rk3066_hdmi.c | 35 +++++++++++++------------- 1 file changed, 17 insertions(+), 18 deletions(-) -- 2.39.2 diff --git a/drivers/gpu/drm/rockchip/rk3066_hdmi.c b/drivers/gpu/drm/rockchip/rk3066_hdmi.c index 5c269081c691..0e7aae341960 100644 --- a/drivers/gpu/drm/rockchip/rk3066_hdmi.c +++ b/drivers/gpu/drm/rockchip/rk3066_hdmi.c @@ -55,7 +55,6 @@ struct rk3066_hdmi { unsigned int tmdsclk; struct hdmi_data_info hdmi_data; - struct drm_display_mode previous_mode; }; static struct rk3066_hdmi *encoder_to_rk3066_hdmi(struct drm_encoder *encoder) @@ -387,21 +386,21 @@ static int rk3066_hdmi_setup(struct rk3066_hdmi *hdmi, return 0; } -static void -rk3066_hdmi_encoder_mode_set(struct drm_encoder *encoder, - struct drm_display_mode *mode, - struct drm_display_mode *adj_mode) +static void rk3066_hdmi_encoder_enable(struct drm_encoder *encoder, + struct drm_atomic_state *state) { struct rk3066_hdmi *hdmi = encoder_to_rk3066_hdmi(encoder); + struct drm_connector_state *conn_state; + struct drm_crtc_state *crtc_state; + int mux, val; - /* Store the display mode for plugin/DPMS poweron events. */ - drm_mode_copy(&hdmi->previous_mode, adj_mode); -} + conn_state = drm_atomic_get_new_connector_state(state, &hdmi->connector); + if (WARN_ON(!conn_state)) + return; -static void rk3066_hdmi_encoder_enable(struct drm_encoder *encoder) -{ - struct rk3066_hdmi *hdmi = encoder_to_rk3066_hdmi(encoder); - int mux, val; + crtc_state = drm_atomic_get_new_crtc_state(state, conn_state->crtc); + if (WARN_ON(!crtc_state)) + return; mux = drm_of_encoder_active_endpoint_id(hdmi->dev->of_node, encoder); if (mux) @@ -414,10 +413,11 @@ static void rk3066_hdmi_encoder_enable(struct drm_encoder *encoder) DRM_DEV_DEBUG(hdmi->dev, "hdmi encoder enable select: vop%s\n", (mux) ? "1" : "0"); - rk3066_hdmi_setup(hdmi, &hdmi->previous_mode); + rk3066_hdmi_setup(hdmi, &crtc_state->adjusted_mode); } -static void rk3066_hdmi_encoder_disable(struct drm_encoder *encoder) +static void rk3066_hdmi_encoder_disable(struct drm_encoder *encoder, + struct drm_atomic_state *state) { struct rk3066_hdmi *hdmi = encoder_to_rk3066_hdmi(encoder); @@ -449,10 +449,9 @@ rk3066_hdmi_encoder_atomic_check(struct drm_encoder *encoder, static const struct drm_encoder_helper_funcs rk3066_hdmi_encoder_helper_funcs = { - .enable = rk3066_hdmi_encoder_enable, - .disable = rk3066_hdmi_encoder_disable, - .mode_set = rk3066_hdmi_encoder_mode_set, - .atomic_check = rk3066_hdmi_encoder_atomic_check, + .atomic_check = rk3066_hdmi_encoder_atomic_check, + .atomic_enable = rk3066_hdmi_encoder_enable, + .atomic_disable = rk3066_hdmi_encoder_disable, }; static enum drm_connector_status From patchwork Thu Nov 2 13:42:19 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Jonker X-Patchwork-Id: 160885 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:8f47:0:b0:403:3b70:6f57 with SMTP id j7csp362532vqu; Thu, 2 Nov 2023 06:43:06 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGlxWsGfmqsm8qZixTbj+bpgAIqWEJVhi2tFZM/Ez3vr+zif5hdSGkoPeB7MVBRmM3KRpwP X-Received: by 2002:a17:90b:1909:b0:280:a69e:45ec with SMTP id mp9-20020a17090b190900b00280a69e45ecmr9911775pjb.5.1698932586379; Thu, 02 Nov 2023 06:43:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698932586; cv=none; d=google.com; s=arc-20160816; b=kB6CogbfeDmfNYuoje+KyeBnH3gRcfWXQDBdUmEkyIuyCRlHerQqXsG+3bbUN4kRxI rIoi1qbwF/Xe+wLhDVAbgep2MGlkFUYCNnt6L+2gGHHgbLI26B33GjOZnvLHdvLHTMY/ ryv1xfvI5pf6Tl7osc1R/if1AdIgjJJe6Wv9y8xhtfasGzaUrH177pxELKcfGuM4yk5O v+ijHR+r59n6AWw8DITrvs8E56wLlS9OJCRxaUWu6IVNLbmFbswCddkhxoQZ+9/cAkIM JoK5sla/BZ/sMoGUAw5JIctY+SQTt4CHUxZFH9/eX/EuiSKmSOWmD2QN24KB3ShT6xqp VVYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :content-language:references:cc:to:subject:from:user-agent :mime-version:date:message-id:dkim-signature; bh=5ij4W2R7Rk89TAWTRo2Z11H1sJFKrF9K18A1hdSCONQ=; fh=v9EK/ZpF7mC7HytCEN1dwHNmJmndcYWW0//5MYgVSx0=; b=Jk8KRwdJ5JotzWGl4EsbM4Br9vuLhvC8szFkV0HUn8UHqZ3kAy895iuyAbpG7mSJXC jiQwnNFZMRISLBfqI/m+g5r+t0QwvJqGNxP7yVCi9qIsduRf3iqOWfGHUZOAsN//++5H qgvOQCKf7fNRltOQR2uqAx5qATH3yG3DQjq9YXN7I6jXcgM+1vRDuTk1/CTcbx8XJKh6 CPkcVJ1A6wC6uDeMdyZEXwPS1BL1JPlwegW/8rBD9C3Oo5psT7cEhknRGUA99l/9AP+d KHNqJMhgmk1tL5M3SEh7llz5AZcMpLB+AAIx/xHzh+ViOUIPslzdTdKXa7CTtZeMA4hL i+/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=fvelpO8V; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id kk15-20020a17090b4a0f00b002805dcadebasi3163405pjb.115.2023.11.02.06.42.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 Nov 2023 06:43:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=fvelpO8V; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id 798F48069F9F; Thu, 2 Nov 2023 06:42:41 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376655AbjKBNm2 (ORCPT + 36 others); Thu, 2 Nov 2023 09:42:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41946 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1376646AbjKBNm1 (ORCPT ); Thu, 2 Nov 2023 09:42:27 -0400 Received: from mail-ej1-x636.google.com (mail-ej1-x636.google.com [IPv6:2a00:1450:4864:20::636]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 28EF0197 for ; Thu, 2 Nov 2023 06:42:22 -0700 (PDT) Received: by mail-ej1-x636.google.com with SMTP id a640c23a62f3a-9d274222b5dso152100766b.3 for ; Thu, 02 Nov 2023 06:42:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1698932540; x=1699537340; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=5ij4W2R7Rk89TAWTRo2Z11H1sJFKrF9K18A1hdSCONQ=; b=fvelpO8V8Ce+Mv5BzLn5w/uMDmuAJBXgew3vs3uqw2uVNDpcV+PhUXg10eZEfD1CWA wu4AQg3IIoqU1riYwu1+R7waP6vrNFjDy3X7arws6xSUcQyao35psA0hWWG6X+Q8xFAm G/y/97Z+f1M3ya6Wi9chCm9mR9IfoR6f2uNYlGSrpf3unVPO6jKcf/B+mCCN2TjMB5UB EBXv1vciDRWygrhgfgS/o6GK+iqT5Pnb1wSnLoitk0pRwjcl4b1S2Q0GOhdquVgfBWuV BLsmkNLw1nTPnVnVYvoKd8PBKabBrjD4AxSNrpQnEEtIygb2GhIifLViKA4U15O1o0oF gzcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698932540; x=1699537340; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=5ij4W2R7Rk89TAWTRo2Z11H1sJFKrF9K18A1hdSCONQ=; b=p/6UV4A5KBf72EAhohWm1ub89V86inE+Yqdobcq7Z7uotFGb8HGWCiwh29zikcKyff IzoOiz4RN6Sq65vTkSfhN6ghEwEhtE4QZvdE+NLDXjby+mKL9bTj67gpQPnv+jJ0Ql23 tcNxNYU/u9oz8QzIwvcBlKbcPshYAICP4QFjZG5Qt7cy6QpZmVVSM6W7EQXiP5S+hNR+ 5ysA/yOiNOSkH1rZ6ID+hX3YrZ0ArtXWeFwIpvAX10c7JeSjCcx1aZRP1Jn06cP7R2T3 TBS3t+wMo5JLpAWFea9Vt1Q27pYLhT7HpwadeZyZr+IxtsLLhHMnEZjykNBF72oSWSvh 4/NQ== X-Gm-Message-State: AOJu0YzPyiCmT5suV3zm660rqVclnBdkz5ynGlQ26DCP4lnxQxLFANsN gDbNt1lri5Qjgdwrg4OJ7+Q= X-Received: by 2002:a17:907:60ca:b0:9c7:4d51:af08 with SMTP id hv10-20020a17090760ca00b009c74d51af08mr4508255ejc.43.1698932540595; Thu, 02 Nov 2023 06:42:20 -0700 (PDT) Received: from [192.168.2.1] (81-204-249-205.fixed.kpn.net. [81.204.249.205]) by smtp.gmail.com with ESMTPSA id j8-20020a170906278800b009be14e5cd54sm1153220ejc.57.2023.11.02.06.42.19 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 02 Nov 2023 06:42:20 -0700 (PDT) Message-ID: Date: Thu, 2 Nov 2023 14:42:19 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 From: Johan Jonker Subject: [PATCH v1 3/4] drm/rockchip: rk3066_hdmi: Remove useless output format To: hjc@rock-chips.com, heiko@sntech.de Cc: airlied@gmail.com, daniel@ffwll.ch, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org References: Content-Language: en-US In-Reply-To: X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Thu, 02 Nov 2023 06:42:41 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1781459935326322613 X-GMAIL-MSGID: 1781459935326322613 The Rk3066 hdmi output format is hard coded to RGB. Remove all useless code related to colorimetry and enc_out_format. Signed-off-by: Johan Jonker --- drivers/gpu/drm/rockchip/rk3066_hdmi.c | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) -- 2.39.2 diff --git a/drivers/gpu/drm/rockchip/rk3066_hdmi.c b/drivers/gpu/drm/rockchip/rk3066_hdmi.c index 0e7aae341960..f2b1b2faa096 100644 --- a/drivers/gpu/drm/rockchip/rk3066_hdmi.c +++ b/drivers/gpu/drm/rockchip/rk3066_hdmi.c @@ -23,8 +23,6 @@ struct hdmi_data_info { int vic; /* The CEA Video ID (VIC) of the current drm display mode. */ - unsigned int enc_out_format; - unsigned int colorimetry; }; struct rk3066_hdmi_i2c { @@ -200,14 +198,7 @@ static int rk3066_hdmi_config_avi(struct rk3066_hdmi *hdmi, rc = drm_hdmi_avi_infoframe_from_display_mode(&frame.avi, &hdmi->connector, mode); - if (hdmi->hdmi_data.enc_out_format == HDMI_COLORSPACE_YUV444) - frame.avi.colorspace = HDMI_COLORSPACE_YUV444; - else if (hdmi->hdmi_data.enc_out_format == HDMI_COLORSPACE_YUV422) - frame.avi.colorspace = HDMI_COLORSPACE_YUV422; - else - frame.avi.colorspace = HDMI_COLORSPACE_RGB; - - frame.avi.colorimetry = hdmi->hdmi_data.colorimetry; + frame.avi.colorspace = HDMI_COLORSPACE_RGB; frame.avi.scan_mode = HDMI_SCAN_MODE_NONE; return rk3066_hdmi_upload_frame(hdmi, rc, &frame, @@ -329,15 +320,6 @@ static int rk3066_hdmi_setup(struct rk3066_hdmi *hdmi, struct drm_display_info *display = &hdmi->connector.display_info; hdmi->hdmi_data.vic = drm_match_cea_mode(mode); - hdmi->hdmi_data.enc_out_format = HDMI_COLORSPACE_RGB; - - if (hdmi->hdmi_data.vic == 6 || hdmi->hdmi_data.vic == 7 || - hdmi->hdmi_data.vic == 21 || hdmi->hdmi_data.vic == 22 || - hdmi->hdmi_data.vic == 2 || hdmi->hdmi_data.vic == 3 || - hdmi->hdmi_data.vic == 17 || hdmi->hdmi_data.vic == 18) - hdmi->hdmi_data.colorimetry = HDMI_COLORIMETRY_ITU_601; - else - hdmi->hdmi_data.colorimetry = HDMI_COLORIMETRY_ITU_709; hdmi->tmdsclk = mode->clock * 1000; From patchwork Thu Nov 2 13:42:32 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Jonker X-Patchwork-Id: 160884 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:8f47:0:b0:403:3b70:6f57 with SMTP id j7csp362488vqu; Thu, 2 Nov 2023 06:43:03 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFJxkJOm8uv+Yy3jbz3IYRrDTovuzzzFgyujiEBW6s+M+wehpTUkVBZGidRK4/cspMo+0GL X-Received: by 2002:a05:6a00:1387:b0:6bd:2c0a:e7d with SMTP id t7-20020a056a00138700b006bd2c0a0e7dmr22297348pfg.19.1698932582910; Thu, 02 Nov 2023 06:43:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698932582; cv=none; d=google.com; s=arc-20160816; b=f43RrQQcdYnTPvy71umav1kXPIKnAYDnrEdIngN/qdRnhHOPKljiO1olgJuNaCrhhU URMp5lwKn3W97MKRSdDTEIZsDXkb7zkwA0cEdfYSq14tjfUPbFctps7tGsoWFyKpzL37 iYVWBzn+MB8gaQEgbwRr5KxBwWyk8hfaHUywMD3SjMAW1QNjH3QdOjkEv/P8ZOLk9R88 ozfyEkorgecUkSnZ9NLn779X/34s5pAgxX7cUkkwukxkQfRFE3UmINiQxafVXmo3PoT1 pMCF5dNLy9ZkLhvTW2Xa0qpIysCzQllzxzOn35RLP7utOCQbVtCsq0S83wIBr2LKCzUz SYIg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :content-language:references:cc:to:subject:from:user-agent :mime-version:date:message-id:dkim-signature; bh=mtT6nxgsYYS4sdsaY7t86FYZfBLOlduBaZpsVAIl6mA=; fh=v9EK/ZpF7mC7HytCEN1dwHNmJmndcYWW0//5MYgVSx0=; b=QeUdAOVm169avvPRNlKvHSPYhQtjGtiu1iRP5b3Ug+OhKSpak9c8vrSXBxxbdXQ3Mc gU13imZVsooaHkbSvp6S5SsHNUfL7YfBua2XfKT9IsY7yZymsehRJCiN2j3OAb66+PQO 641yUZvD6RokqH9MzrgdVAjU+bONRQBBOi3fa50Xn3ZCtErDyAAWBJzFMd2+XGlfeZTf wkJ/3MOK9DNc2arm1orVqPRAvCnjY1FwtT1FFjIgagzwNjm9fL9ZfOoJgdmXbkGd2Efh dZEmKrmyw6jUI8/xOsJEiaqgDK3yFBsmDLFp88F5qROwenJJKNcL8ASEMdasMDWE39Nf xhvA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=c4qBMrA9; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id a189-20020a624dc6000000b00690ba709d02si3466366pfb.381.2023.11.02.06.43.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 Nov 2023 06:43:02 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=c4qBMrA9; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id B5F108074069; Thu, 2 Nov 2023 06:43:00 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376637AbjKBNmm (ORCPT + 36 others); Thu, 2 Nov 2023 09:42:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36954 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235127AbjKBNmk (ORCPT ); Thu, 2 Nov 2023 09:42:40 -0400 Received: from mail-ed1-x52d.google.com (mail-ed1-x52d.google.com [IPv6:2a00:1450:4864:20::52d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B5A87197 for ; Thu, 2 Nov 2023 06:42:35 -0700 (PDT) Received: by mail-ed1-x52d.google.com with SMTP id 4fb4d7f45d1cf-52bd9ddb741so1601702a12.0 for ; Thu, 02 Nov 2023 06:42:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1698932554; x=1699537354; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id:from:to :cc:subject:date:message-id:reply-to; bh=mtT6nxgsYYS4sdsaY7t86FYZfBLOlduBaZpsVAIl6mA=; b=c4qBMrA93TzGOmeAeaF2jkZGTwC7vfOxIsxOHtAU2zMyx2tdkDr/uNVMgjYYiPoX4n RsMbzkxVHl2eoGzkWp8OYB8UERx9LgH1aXi9U9+jddHRtYn1OIEafg81+GfsZF/jW9mu 6cEQuMjwVQ78uvhHOBf50dGDql7dZKZu/JuHec70ZH53C0w5C/kEL5KKqzJ9uFkb4f2y 8sRpkKKoPH7emoAFZGqHU5x+jfpVVst9JWAJhNazCJAqKzYQ0zbmzOyUrHtrX9nLvhOg DiWjRVTixpg3EyS1YzvHyuINITTU+QJb/QWSp/g9Fh4IG16vxN8dGAY1LhfZuwwSkv+d Mj2Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1698932554; x=1699537354; h=content-transfer-encoding:in-reply-to:content-language:references :cc:to:subject:from:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=mtT6nxgsYYS4sdsaY7t86FYZfBLOlduBaZpsVAIl6mA=; b=IDciT2hxCfk+f1Yfj4DTI81sHEe6a4uCUdZzZx972dSXRo5NKbCYd1e9NzJU+qyYR4 /NIiN8hiUbIYYW5CglQMwgOijbPLCIyroCCI4b4IB6SVg7Bs1c0TYsS7Ty+9rTSqUZbi yxFO6x2aQSvmL6uDXzLX48jgLk+Vfpmtn6svFz+/OJs49gk8+g504mTlcZaXwaOJrLwR xDWhFr49Ev0/Y5g/znb/E8xMnaLcVCKYcrDlfTG7OufRCr+Nsri4izBcvxTpOUGLbhJ4 mCfbVP2uOEKB/2smYRc7YGhlx3e2BRPxu2XuxEjwRCz/8c7vEiGSL42y55jiGbMgYlls nJ6Q== X-Gm-Message-State: AOJu0YyTrnVjlMhRlMdJTYwC1XMzQZ54+Y01sKaM0PHifvzjjWBzntFM guNhOmCzDLo2ILjOtTlp9xM= X-Received: by 2002:a05:6402:2029:b0:53d:a7d9:5149 with SMTP id ay9-20020a056402202900b0053da7d95149mr14483614edb.6.1698932554131; Thu, 02 Nov 2023 06:42:34 -0700 (PDT) Received: from [192.168.2.1] (81-204-249-205.fixed.kpn.net. [81.204.249.205]) by smtp.gmail.com with ESMTPSA id v3-20020a50d583000000b0053e89721d4esm2378618edi.68.2023.11.02.06.42.33 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 02 Nov 2023 06:42:33 -0700 (PDT) Message-ID: <813a0e30-a61d-7fc9-9ca6-11bf9c6fbe52@gmail.com> Date: Thu, 2 Nov 2023 14:42:32 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.13.0 From: Johan Jonker Subject: [PATCH v1 4/4] drm/rockchip: rk3066_hdmi: Remove unused drm device pointer To: hjc@rock-chips.com, heiko@sntech.de Cc: airlied@gmail.com, daniel@ffwll.ch, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org References: Content-Language: en-US In-Reply-To: X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Thu, 02 Nov 2023 06:43:00 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1781459932041962415 X-GMAIL-MSGID: 1781459932041962415 The drm_dev field in the rk3066_hdmi struct stores a pointer to the DRM device but is never used anywhere in the driver. Let's remove it. Signed-off-by: Johan Jonker --- drivers/gpu/drm/rockchip/rk3066_hdmi.c | 2 -- 1 file changed, 2 deletions(-) -- 2.39.2 diff --git a/drivers/gpu/drm/rockchip/rk3066_hdmi.c b/drivers/gpu/drm/rockchip/rk3066_hdmi.c index f2b1b2faa096..c51520ec58d2 100644 --- a/drivers/gpu/drm/rockchip/rk3066_hdmi.c +++ b/drivers/gpu/drm/rockchip/rk3066_hdmi.c @@ -38,7 +38,6 @@ struct rk3066_hdmi_i2c { struct rk3066_hdmi { struct device *dev; - struct drm_device *drm_dev; struct regmap *grf_regmap; int irq; struct clk *hclk; @@ -734,7 +733,6 @@ static int rk3066_hdmi_bind(struct device *dev, struct device *master, return -ENOMEM; hdmi->dev = dev; - hdmi->drm_dev = drm; hdmi->regs = devm_platform_ioremap_resource(pdev, 0); if (IS_ERR(hdmi->regs)) return PTR_ERR(hdmi->regs);