From patchwork Tue Nov 19 07:42:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Ekenberg X-Patchwork-Id: 13879478 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 31690D60079 for ; Tue, 19 Nov 2024 08:09:31 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 37ABC10E5DE; Tue, 19 Nov 2024 08:09:26 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (1024-bit key; unprotected) header.d=axis.com header.i=@axis.com header.b="HmQI+mW2"; dkim-atps=neutral Received: from EUR05-DB8-obe.outbound.protection.outlook.com (mail-db8eur05on2049.outbound.protection.outlook.com [40.107.20.49]) by gabe.freedesktop.org (Postfix) with ESMTPS id E2F1210E5DC for ; Tue, 19 Nov 2024 07:42:44 +0000 (UTC) ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=B8POy62pUby1sz3yKF1vdQZ7sBMkisIrRF4y/08UGTFBdq8CPNU6xG/6WiBwG6ndp6akHJ6Jwq6XT5Sup4E5o13LoMNJdejhHu6wRHzZ+pAFVhEeVGUlSXqIwWVxggTfA5Ecfhyj2uoweyErfKfz+Ouj1OKM6IocPB8ebcv6hjRP9wwTMQuyRsJ1hKJ0EOI6SmRVHHmr1bPEV4jNz+o4PKaTZwDolN2rJ8CMO4GFE027yy/IMKuUhVXJgr+MyIVmxuCNfqutZT39NGAzUp/aZIpj9owsKZwD7WV5ECki8DGhUaOxQBBYMbcLKfYquZUFkn8eNHwE4yTalJ5nc8bScw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Bg2pMooZYIJFh0qVk5P30bCSVapPaOWC/bwtE4dpeLU=; b=rkH1/3F+Ljhe2EE0Ls4oIDr8uun2YLpjTN1a3zS5GzdykzI4gIB774XttDkLYbsCJcFc8a8JZrb2e+LYaXojLNZb2xY3BO4m2s0b9k3DiinGFtgJ48G7OhOp05x6zwsJU9TFEPgomQ72WttWf3nxB3h2j/EFY+1pprwliZkeXf8IJ72QQycYgOdvWb3dx2+klzUoaK1Ld0H7COQxaaYQ6MY3wU+LUWEjoWgROw6L+Tvaq30Ocp1ecgdh/6fM0YSShqRXUnhArw5VW1G4l3jsQhjJzAH0ccK33EEnHHRvSZYXU6HCSOOlZ3gyqjpsszEbyWu6xXdEsN7jiKLxsXa34g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 195.60.68.100) smtp.rcpttodomain=bp.renesas.com smtp.mailfrom=axis.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=axis.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=axis.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Bg2pMooZYIJFh0qVk5P30bCSVapPaOWC/bwtE4dpeLU=; b=HmQI+mW2Xui/DEtyG1DeNlLwHvkx08YjOczH57WKiRO++yPcH1yqRa8brxEgC5DEAeH0auBHI0kdpPXcKKSfvTsMABseSwdUDX7xuB92MH5gzEhfL/4zP+COSKdFSxFjdBIMd2/xnO7gidMaKcxNtlr1QQLuzcJWMjPZgTqDAoA= Received: from DU2PR04CA0304.eurprd04.prod.outlook.com (2603:10a6:10:2b5::9) by GVXPR02MB10666.eurprd02.prod.outlook.com (2603:10a6:150:151::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8158.22; Tue, 19 Nov 2024 07:42:41 +0000 Received: from DB5PEPF00014B94.eurprd02.prod.outlook.com (2603:10a6:10:2b5:cafe::ee) by DU2PR04CA0304.outlook.office365.com (2603:10a6:10:2b5::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.8158.23 via Frontend Transport; Tue, 19 Nov 2024 07:42:41 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 195.60.68.100) smtp.mailfrom=axis.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=axis.com; Received-SPF: Pass (protection.outlook.com: domain of axis.com designates 195.60.68.100 as permitted sender) receiver=protection.outlook.com; client-ip=195.60.68.100; helo=mail.axis.com; pr=C Received: from mail.axis.com (195.60.68.100) by DB5PEPF00014B94.mail.protection.outlook.com (10.167.8.232) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.8158.14 via Frontend Transport; Tue, 19 Nov 2024 07:42:40 +0000 Received: from se-mail02w.axis.com (10.20.40.8) by se-mail02w.axis.com (10.20.40.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.39; Tue, 19 Nov 2024 08:42:39 +0100 Received: from se-intmail01x.se.axis.com (10.4.0.28) by se-mail02w.axis.com (10.20.40.8) with Microsoft SMTP Server id 15.1.2507.39 via Frontend Transport; Tue, 19 Nov 2024 08:42:39 +0100 Received: from pc39391-2017.se.axis.com (pc39391-2017.se.axis.com [10.92.82.2]) by se-intmail01x.se.axis.com (Postfix) with ESMTP id BE4064F0; Tue, 19 Nov 2024 08:42:39 +0100 (CET) Received: by pc39391-2017.se.axis.com (Postfix, from userid 10612) id BB2994462505; Tue, 19 Nov 2024 08:42:39 +0100 (CET) From: Stefan Ekenberg Date: Tue, 19 Nov 2024 08:42:36 +0100 Subject: [PATCH v2] drm/bridge: adv7533: Reset DSI receiver logic MIME-Version: 1.0 Message-ID: <20241119-adv7533-dsi-reset-v2-1-e12cce42e25a@axis.com> X-B4-Tracking: v=1; b=H4sIAGtBPGcC/22NQQ6CMBBFr0Jm7RimBURX3sOwgHaQWQikQxoM4 e5W4tLle8l/fwPlIKxwyzYIHEVlGhOYUwZuaMcno/jEYHJTEOU1tj5eSmvRq2Bg5QWLunZV33U lFwbSbg7cy3o0H03iQXSZwvu4iPS1vxrZP7VISFg5yqsr27L39t6uomc3vaDZ9/0DexQ6jbEAA AA= X-Change-ID: 20241108-adv7533-dsi-reset-488c6fbb5e42 To: Andrzej Hajda , Neil Armstrong , Robert Foss , Laurent Pinchart , Jonas Karlman , "Jernej Skrabec" , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter CC: , , , Biju Das , Stefan Ekenberg X-Mailer: b4 0.14.2 X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: DB5PEPF00014B94:EE_|GVXPR02MB10666:EE_ X-MS-Office365-Filtering-Correlation-Id: 7c18e039-03c6-49a0-c031-08dd086dbf37 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|7416014|376014|1800799024|36860700013|82310400026|921020; X-Microsoft-Antispam-Message-Info: =?utf-8?q?VNXMF9eu6365ylYrI1jALqJahDBLqf5?= =?utf-8?q?/NH1o/rr6TNf0i1Ew8SYe0B6StYrl3r3oNk/WIWCekSOpI7A0Ebn8jX1igVb/y5DD?= =?utf-8?q?Cr5ou4Hxf8BDtjUCDKUHLnsxBJUnSY3chO31ga+msvsKDM9r77Jt2lST4/eDIWxYf?= =?utf-8?q?k9M0Vg7gfNRciD5t1SyKN6lrGcTaK/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ohIOC6hmCQAQaZ0fUv81oBmP8LW4YfMmtpMg9a?= =?utf-8?q?GexDh1nmz4Ymc88kGvBmCegnklTizbtdxMyTSWwN2CFPkFbo4CPE+//WxxVstq+sL?= =?utf-8?q?zetGmuUMNwTD0TzdowIco+HD6stQ+cHZpwXdl8WV5MOMC+bCbWWJn42R7stx4L9vh?= =?utf-8?q?aymHwFc2n4IGhgHI2y6oRV0DReXofjNPICZ7zTg1pWkFyDey2rxQC3IbypJ+GckII?= =?utf-8?q?P2cdJhygH9ywy87iVGrsmezHIa3aURM0nNsgmA0Wl9S1UHmds4tdBId6eR7aqD1MA?= =?utf-8?q?+FrwSsXPjnUbh5ue2mCwvtVw8hfPOqZyfpOiNUJZ3su1HOvkDjOi9Ls=3D?= X-Forefront-Antispam-Report: CIP:195.60.68.100; CTRY:SE; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.axis.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230040)(7416014)(376014)(1800799024)(36860700013)(82310400026)(921020); DIR:OUT; SFP:1101; X-OriginatorOrg: axis.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Nov 2024 07:42:40.8412 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 7c18e039-03c6-49a0-c031-08dd086dbf37 X-MS-Exchange-CrossTenant-Id: 78703d3c-b907-432f-b066-88f7af9ca3af X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=78703d3c-b907-432f-b066-88f7af9ca3af; Ip=[195.60.68.100]; Helo=[mail.axis.com] X-MS-Exchange-CrossTenant-AuthSource: DB5PEPF00014B94.eurprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: GVXPR02MB10666 X-Mailman-Approved-At: Tue, 19 Nov 2024 08:09:25 +0000 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Reset DSI receiver logic during power on. The need for this change was discovered when investigating issue with ADV7535. The symptom of the problem was that ADV7535 continuously outputs a black image. This happened for about 10% of the times that ADV7535 was powered on. The rest of the times the image was as expected. The solution in this patch (placement of reset and sleep time of 200ms) is implemented as outlined by the Analog Devices support team. Tested-by: Biju Das Signed-off-by: Stefan Ekenberg --- Changes in v2: - Add Tested-by tag - Link to v1: https://lore.kernel.org/r/20241113-adv7533-dsi-reset-v1-1-6c1069e35fd3@axis.com --- drivers/gpu/drm/bridge/adv7511/adv7533.c | 9 +++++++++ 1 file changed, 9 insertions(+) --- base-commit: 59b723cd2adbac2a34fc8e12c74ae26ae45bf230 change-id: 20241108-adv7533-dsi-reset-488c6fbb5e42 Best regards, diff --git a/drivers/gpu/drm/bridge/adv7511/adv7533.c b/drivers/gpu/drm/bridge/adv7511/adv7533.c index 4481489aaf5ebf164313c86cbf3447d2d7914ab9..93085c2b872ed98f4ee394236dc66c568c0e5ccf 100644 --- a/drivers/gpu/drm/bridge/adv7511/adv7533.c +++ b/drivers/gpu/drm/bridge/adv7511/adv7533.c @@ -67,6 +67,15 @@ void adv7533_dsi_power_on(struct adv7511 *adv) { struct mipi_dsi_device *dsi = adv->dsi; + /* + * Reset DSI receiver block logic to avoid ADV7535 startup problem. + * Without this reset it sometimes continuously fails to receive + * incoming DSI packets and outputs black image. + */ + regmap_write(adv->regmap_cec, 0x26, 0x18); + msleep(200); + regmap_write(adv->regmap_cec, 0x26, 0x38); + if (adv->use_timing_gen) adv7511_dsi_config_timing_gen(adv);