From patchwork Wed Mar 30 22:30:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12796440 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 28312C433F5 for ; Wed, 30 Mar 2022 22:30:13 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7584310E1AE; Wed, 30 Mar 2022 22:30:12 +0000 (UTC) Received: from mail-lf1-x131.google.com (mail-lf1-x131.google.com [IPv6:2a00:1450:4864:20::131]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8895410E1AE for ; Wed, 30 Mar 2022 22:30:11 +0000 (UTC) Received: by mail-lf1-x131.google.com with SMTP id 5so38290499lfp.1 for ; Wed, 30 Mar 2022 15:30:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=JtbqvUsqEzE2g6uW/TT035ax0kBfyahmOob6FsqwcPY=; b=hQPWu/OIb+Zegy4kT+8Em3QCWjiXaFxFPWp5W2WJaaPEXiGblSSVNAXq8q7uOJtC47 eJ06zbMxbNw0E/hPe5Yjp02P12DRRSmUDfhM+CttqoHsY2JzvzAmyf3wiHVPDeIoKpGw Gq66rgG3yK108wL0ib2j/2l2m9zypCghXh1zONv+9wNSCcx7a7214v2XygnOF3Qhh53D muKngZCaFu3fTimsAwa7EJL10OzYpzB9Et5MUbfTxCCjOrxUViMBWYblP13jvhXdzrc5 a6uFuEzBRgypjI7nBMWTbFx2vY2sel6pPBIfROrWd0A1tkHllnzpARSS2BurI8UK71sO iNsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=JtbqvUsqEzE2g6uW/TT035ax0kBfyahmOob6FsqwcPY=; b=kUg6xeKspjNfRM4NtT5oxmha6rSmBsG/eIvGq275RoOSLE2u6qz0Lakpn7BufvHuJ5 oI93qUFMTKk5cvKwSWWNUdBWDvMpJLV5idJGv8kar4hwc/ew/RXlylDWnD6ks+riX2Cn ZMagEMayDBQAueeqzlo+BvLgvOgVAH98Goz0kc2ClEVcBUGHT5Z+iFwk1KujmVSquzyo pdpAFJ0R5qlLO/5A8kdC1aJ9cENUvzHKi2PkK3Qy8XSpqO8TPg6J3fdZ7ARAtf6UwhSo syt7w0j5SZ3Etb3yKRe1W8LIQ7W9dS9H0DiogP7o/wejjepMM1giaF9Fhuuo/L+YF6zc V+mA== X-Gm-Message-State: AOAM530M5ZvDjc5epH0tGtLdjxvRsd0a63T+xezB/EwpmQLZz5E3S3Tf TRLnvODwZ9QxZ67qlEdv2MhhiA== X-Google-Smtp-Source: ABdhPJzG/f64ACIg2eEZE7Cx4oJHdTia/6Z35v5jnReSD+gy9dIQgwNO9KoopCVhR+hFwGsgSOzuRA== X-Received: by 2002:a05:6512:32c2:b0:44a:700c:4e97 with SMTP id f2-20020a05651232c200b0044a700c4e97mr8590964lfg.224.1648679409820; Wed, 30 Mar 2022 15:30:09 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id a4-20020a2eb164000000b0024988e1cfb6sm2521295ljm.94.2022.03.30.15.30.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 30 Mar 2022 15:30:09 -0700 (PDT) From: Dmitry Baryshkov To: Bjorn Andersson , Rob Clark , Sean Paul , Abhinav Kumar , Kuogee Hsieh , Sankeerth Billakanti Subject: [PATCH v2 0/4] drm/msm/dp: simplify dp_connector_get_modes() Date: Thu, 31 Mar 2022 01:30:04 +0300 Message-Id: <20220330223008.649274-1-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: David Airlie , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, Stephen Boyd , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" As noted by Ville Syrjälä [1] the dp_connector_get_modes() has weird on-stack interim copy of the mode. When reviewing the mentioned patch I noticed that the rest of the code in dp_connector_get_modes() is weird, unused since September of 2020 and can be removed. This series removes dead weird code leaving dp_connector_get_modes() simple enough. [1] https://lore.kernel.org/linux-arm-msm/20220218100403.7028-11-ville.syrjala@linux.intel.com/ Changes since v1: - Remove unsued ret variable from dp_display_get_modes() - Add a patch making dp_connector_mode_valid() return MODE_CLOCK_HIGH (suggested by Stephen) Dmitry Baryshkov (4): drm/msm/dp: drop dp_mode argument from dp_panel_get_modes() drm/msm/dp: simplify dp_connector_get_modes() drm/msm/dp: remove max_pclk_khz field from dp_panel/dp_display drm/msm/dp: make dp_connector_mode_valid() more precise drivers/gpu/drm/msm/dp/dp_debug.c | 2 -- drivers/gpu/drm/msm/dp/dp_display.c | 12 +++------- drivers/gpu/drm/msm/dp/dp_display.h | 5 +---- drivers/gpu/drm/msm/dp/dp_drm.c | 35 +++-------------------------- drivers/gpu/drm/msm/dp/dp_panel.c | 2 +- drivers/gpu/drm/msm/dp/dp_panel.h | 3 +-- 6 files changed, 9 insertions(+), 50 deletions(-)