From patchwork Tue Dec 5 10:52:51 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 13479953 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 711E9C10DCE for ; Tue, 5 Dec 2023 10:54:20 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3A16410E4E8; Tue, 5 Dec 2023 10:54:18 +0000 (UTC) Received: from mail-ej1-x62a.google.com (mail-ej1-x62a.google.com [IPv6:2a00:1450:4864:20::62a]) by gabe.freedesktop.org (Postfix) with ESMTPS id B295B10E4ED for ; Tue, 5 Dec 2023 10:54:09 +0000 (UTC) Received: by mail-ej1-x62a.google.com with SMTP id a640c23a62f3a-a1cdeab6b53so29549666b.1 for ; Tue, 05 Dec 2023 02:54:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1701773648; x=1702378448; darn=lists.freedesktop.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=LRuU/Yf3+WOs2/s3BqHchrpBnPmBNhkaR5Vfu/UBGmU=; b=grRwF/j3oi7lNZGhrBjEe+RawzcMiqpVyqwO5L4jPDiXhEgavgMBQ7sOlpLgvEtlDu DByMbLtsq7z4OouMO4fhBqg23YJHaVD2PQuljce7DXodMx5gnr4TCW50BBw+Ika196G1 Nty7iWeW3Wjq2vwPfJ+KZIWz73diJbwySbaOo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701773648; x=1702378448; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LRuU/Yf3+WOs2/s3BqHchrpBnPmBNhkaR5Vfu/UBGmU=; b=i/EOZoe0mMx/QSnMy9COJi9wv7kBEF55rsdPQL/JQlN6xdE6GVEgOUuyKDjHOiYU/N BoYFdS3N6jpfXy7a26GHxqE+h1RlQ0CW2yT0DeCOHW8zeli1THTxCYpikbfC6qd+3SPd Wz0N15vTgfPoSXn2qpwN54ROu/O2JyIMQpPvkxLwB68RUlRQj4IKQgMQfLbGaeEvZprf 48l8GKo/egIPxvj7rt1LshHDlRfWP6bVQQICSWfEZbE0O5797BUVuP1OEQbyhf/N+/YU LHU7ryBdZrv0A3hDVzAvWNlxO6s9h+2QUIMzGCcG6cSYCz9SfNa5ZpWwBbUYCvTtu5Oz zntg== X-Gm-Message-State: AOJu0YxyaKWvgKvPuzvnnZTrfBS9JPzhh13ydn4AZGqtxJFerQ1BoII8 vQ2bKbmv1RGmPvLmnXuvS46nUA== X-Google-Smtp-Source: AGHT+IHxVNKILJWwVVe+2K09X6bLaUpBNuO+00HbvfAfEFYM3ldPHRUK3hGzcnSOXFtoYiV94HtDHQ== X-Received: by 2002:a17:906:10c:b0:a1c:f04d:8fb2 with SMTP id 12-20020a170906010c00b00a1cf04d8fb2mr103178eje.58.1701773648268; Tue, 05 Dec 2023 02:54:08 -0800 (PST) Received: from dario-ThinkPad-T14s-Gen-2i.homenet.telecomitalia.it (host-82-54-95-129.retail.telecomitalia.it. [82.54.95.129]) by smtp.gmail.com with ESMTPSA id n23-20020a170906089700b0099297782aa9sm6413491eje.49.2023.12.05.02.54.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 02:54:07 -0800 (PST) From: Dario Binacchi To: linux-kernel@vger.kernel.org Subject: [PATCH v4 04/10] drm: bridge: samsung-dsim: complete the CLKLANE_STOP setting Date: Tue, 5 Dec 2023 11:52:51 +0100 Message-ID: <20231205105341.4100896-5-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231205105341.4100896-1-dario.binacchi@amarulasolutions.com> References: <20231205105341.4100896-1-dario.binacchi@amarulasolutions.com> 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: Maxime Ripard , Neil Armstrong , Dario Binacchi , Robert Foss , Andrzej Hajda , Thomas Zimmermann , Jonas Karlman , Amarula patchwork , dri-devel@lists.freedesktop.org, Jernej Skrabec , Jagan Teki , Marek Szyprowski , michael@amarulasolutions.com, Laurent Pinchart Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" The patch completes the setting of CLKLANE_STOP for the imx8mn and imx8mp platforms (i. e. not exynos). Co-developed-by: Michael Trimarchi Signed-off-by: Michael Trimarchi Signed-off-by: Dario Binacchi --- (no changes since v1) drivers/gpu/drm/bridge/samsung-dsim.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/bridge/samsung-dsim.c b/drivers/gpu/drm/bridge/samsung-dsim.c index 15bf05b2bbe4..13f181c99d7e 100644 --- a/drivers/gpu/drm/bridge/samsung-dsim.c +++ b/drivers/gpu/drm/bridge/samsung-dsim.c @@ -96,6 +96,7 @@ #define DSIM_MFLUSH_VS BIT(29) /* This flag is valid only for exynos3250/3472/5260/5430 */ #define DSIM_CLKLANE_STOP BIT(30) +#define DSIM_NON_CONTINUOUS_CLKLANE BIT(31) /* DSIM_ESCMODE */ #define DSIM_TX_TRIGGER_RST BIT(4) @@ -945,8 +946,12 @@ static int samsung_dsim_init_link(struct samsung_dsim *dsi) * power consumption. */ if (driver_data->has_clklane_stop && - dsi->mode_flags & MIPI_DSI_CLOCK_NON_CONTINUOUS) + dsi->mode_flags & MIPI_DSI_CLOCK_NON_CONTINUOUS) { + if (!samsung_dsim_hw_is_exynos(dsi->plat_data->hw_type)) + reg |= DSIM_NON_CONTINUOUS_CLKLANE; + reg |= DSIM_CLKLANE_STOP; + } samsung_dsim_write(dsi, DSIM_CONFIG_REG, reg); lanes_mask = BIT(dsi->lanes) - 1;