Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp3832433rwb; Sun, 9 Oct 2022 11:56:29 -0700 (PDT) X-Google-Smtp-Source: AMsMyM7XlHESQ1y/UCNetxmN86cyfYWlwIOBYBdo4RzgxwG2EbwikeF7YZloozb9Inv949teG7yo X-Received: by 2002:a63:5a0b:0:b0:434:4748:4e7a with SMTP id o11-20020a635a0b000000b0043447484e7amr13500196pgb.561.1665341789544; Sun, 09 Oct 2022 11:56:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1665341789; cv=none; d=google.com; s=arc-20160816; b=THRc02k56TGh/r1IPBhyssu/jC8dH8WfLzA68sTGfoHbmo9Q7yEMesOcWwtJ3/OLAk fF5TpagoqG61NMX1Bz4PI02jJQ7cZgvnL+q9j0gemySWhG5jO4Vvxk1oaBIq8UhsVnuB iTJwM9VLUxBKJSFiH2GLGHCVzUDoeAdu+pkXkV9qxf7VE2tn3J4QuAtbDUbfokq2MUHP 7oubn1/kXNmhBgkKGg48s4pw5Ts3CFScjtSE1uv3sSZW3Tieec5Sdd4eluyhSYBo6yqi Gqp/dR5FnKwKHgZbjZkgwROnWx2x1nWqA0SnlRK0k9lwzzTct59dxeNsTMcHCBhRRdz8 2Jdg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=X0V6zbiUPCKYB6AXbk9gkx7A9sMByH3RV/kf+9qstuQ=; b=b+abz76PLTLcyeLABgKzcqzQnrHJMOR/JQw46qXo+e5bagLOHCeMyNDZqg2psN0FUX HAa5jKaqGMill462m+RFcUuxjlZVMU2lHPfMxoTc8bqULJMTQIPuU6s3n2Ezq1sfEuaB kxseKVf+Hy1JHg7zr6VYQ/7Tf2jygLO9WNu9eC+2lGygAjoWq0TtXquHmlCJ5GWyHqzs IKOlSlkR+CMDMPMJqH3beJzpG8KTl2gdtyhnKWFL4VKAvDOm0+na2mAGMObM1HmIWjmj 2xbvGzKJEsaZ5iRAON7svlVbKbZ0tcOtQ/Y26om7FMeQ/RB1TY8oAmjyMpv1ZqlDUVbX Oe2w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e15-20020a63ee0f000000b004403d4f1f70si9175290pgi.455.2022.10.09.11.56.17; Sun, 09 Oct 2022 11:56:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230305AbiJISvx (ORCPT + 99 others); Sun, 9 Oct 2022 14:51:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51678 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229590AbiJISvt (ORCPT ); Sun, 9 Oct 2022 14:51:49 -0400 Received: from relay01.th.seeweb.it (relay01.th.seeweb.it [5.144.164.162]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 96C4429835; Sun, 9 Oct 2022 11:51:48 -0700 (PDT) Received: from localhost.localdomain (94-209-172-39.cable.dynamic.v4.ziggo.nl [94.209.172.39]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by m-r1.th.seeweb.it (Postfix) with ESMTPSA id B9CBA1F986; Sun, 9 Oct 2022 20:51:30 +0200 (CEST) From: Marijn Suijten To: phone-devel@vger.kernel.org Cc: ~postmarketos/upstreaming@lists.sr.ht, AngeloGioacchino Del Regno , Konrad Dybcio , Martin Botka , Jami Kettunen , Marijn Suijten , Rob Clark , Abhinav Kumar , Dmitry Baryshkov , Sean Paul , David Airlie , Daniel Vetter , Vinod Koul , Douglas Anderson , Vladimir Lypak , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 06/10] drm/msm/dsi: Migrate to drm_dsc_compute_rc_parameters() Date: Sun, 9 Oct 2022 20:50:54 +0200 Message-Id: <20221009185058.460688-1-marijn.suijten@somainline.org> X-Mailer: git-send-email 2.38.0 In-Reply-To: <20221009184824.457416-1-marijn.suijten@somainline.org> References: <20221009184824.457416-1-marijn.suijten@somainline.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org As per the FIXME this code is entirely duplicate with what is already provided inside drm_dsc_compute_rc_parameters(), and it is yet unknown why this comment was put in place instead of resolved from the get-go. Not only does it save on duplication, it would have also spared certain issues. For example, this code from downstream assumed dsc->bits_per_pixel to contain an integer value, whereas the upstream drm_dsc_config struct has it with 4 fractional bits. drm_dsc_compute_rc_parameters() already accounts for this feat, and the sole remaining use of dsc->bits_per_pixel inside dsi_populate_dsc_params() will be addressed in a separate patch. Fixes: b9080324d6ca ("drm/msm/dsi: add support for dsc data") Signed-off-by: Marijn Suijten --- drivers/gpu/drm/msm/dsi/dsi_host.c | 64 +++--------------------------- 1 file changed, 6 insertions(+), 58 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi_host.c b/drivers/gpu/drm/msm/dsi/dsi_host.c index 83cde4d62b68..68c39debc22f 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_host.c +++ b/drivers/gpu/drm/msm/dsi/dsi_host.c @@ -21,6 +21,7 @@ #include