From patchwork Thu Nov 14 09:39:47 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 179382 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp10810185ilf; Thu, 14 Nov 2019 01:40:09 -0800 (PST) X-Google-Smtp-Source: APXvYqzn0BWCvnFIIGhylTWrY2xWXQrdwo6oZfSW9pKvgdo2MDsxIVlj7MJFMMIvy/8FSTFxYTCe X-Received: by 2002:a50:a9e3:: with SMTP id n90mr110308edc.52.1573724408307; Thu, 14 Nov 2019 01:40:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573724408; cv=none; d=google.com; s=arc-20160816; b=vxguu8ikMYXm7LCfvxt3zPrQAMW9jzS6Hc70DYS2p2aJeHJuKaEBpOT0wsolVE83GP cUwZrrpJoitzw46oHOrrv33MrC+OswOrV4jQ3l1ay1UpbnhfF1p9IBOPCD9dEkqx6dQY iCLZODgLpNnUlLuuTjzx9F3Z10ywrZH0BJvntqML7vfF5SFfgh861ehOYvHeUtA9Huoh CGK5I3DLMapYY8GWznwgFAYk4MW0D/gmY8jpbJUsqQuDBkXdevWMNVjj8SdDZiJWINgl ct0bqScGF0EgwPRChlRjjtolxIbDuWyGqkGZDOU3OmMNhOeaclUxIEXJVZfz6R71BOI1 Xi3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from:dkim-signature; bh=eR1yIrg2X8EeWm9KCPcT2Lr4/cMCf/WphmqdpoQ3zsE=; b=zoSFT1MP6k+Ml2961nrhpHuvtirZyL40bF4LoKvNArCYJHpt3V0OSWMhcMAranlLZl wsFsCShbHWWiW0BDaXZChjLhwpI9tbAm6wqLI0aMkIxKUaz6hXOhdMlhx/pDCdQYyLfx stTtFBGluFhXtd96QLfuShj47eY+qQv5moFxDuZPkc0uoDocHzGZGZI8RW+YTWuRUUZB TvWDwSMErTIYTAwgTFxKcqtYq6Iv36utI9RPPpbaCj+agmIfOLplQIYeBrqm0l8+RkVR 73Tk+CQRfblC+yQfgH5lUaA0H7BVCXDOmIFJauwqqMzQCExTuv+XjraU5WVNcRzEScIo Ejdg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=Y6MS4nhF; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o5si776110edd.445.2019.11.14.01.40.08; Thu, 14 Nov 2019 01:40:08 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=Y6MS4nhF; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726202AbfKNJkH (ORCPT + 8 others); Thu, 14 Nov 2019 04:40:07 -0500 Received: from fllv0016.ext.ti.com ([198.47.19.142]:44436 "EHLO fllv0016.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726010AbfKNJkH (ORCPT ); Thu, 14 Nov 2019 04:40:07 -0500 Received: from fllv0034.itg.ti.com ([10.64.40.246]) by fllv0016.ext.ti.com (8.15.2/8.15.2) with ESMTP id xAE9dwct060060; Thu, 14 Nov 2019 03:39:58 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1573724398; bh=eR1yIrg2X8EeWm9KCPcT2Lr4/cMCf/WphmqdpoQ3zsE=; h=From:To:CC:Subject:Date; b=Y6MS4nhFWAgNDGvua5dmwrshnfV3YvzMpOHfCxccYAIPWvYXkp360vVqRbbDMUib4 6z2SzubaeypK/V5OGTTvC1yHvN1UlXvO4VWO0nWMnABCfVT4Na0s+KpSxgvXrVp4m3 edVYNvymCgV7kN9hyjrXBK7Ax3650U2X7o2H5wnk= Received: from DFLE114.ent.ti.com (dfle114.ent.ti.com [10.64.6.35]) by fllv0034.itg.ti.com (8.15.2/8.15.2) with ESMTPS id xAE9dwMV035445 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Thu, 14 Nov 2019 03:39:58 -0600 Received: from DFLE112.ent.ti.com (10.64.6.33) by DFLE114.ent.ti.com (10.64.6.35) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1847.3; Thu, 14 Nov 2019 03:39:58 -0600 Received: from fllv0040.itg.ti.com (10.64.41.20) by DFLE112.ent.ti.com (10.64.6.33) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1847.3 via Frontend Transport; Thu, 14 Nov 2019 03:39:58 -0600 Received: from deskari.lan (ileax41-snat.itg.ti.com [10.172.224.153]) by fllv0040.itg.ti.com (8.15.2/8.15.2) with ESMTP id xAE9dtjn085959; Thu, 14 Nov 2019 03:39:56 -0600 From: Tomi Valkeinen To: , , Thierry Reding , Tony Lindgren , Laurent Pinchart CC: Jyri Sarha , Peter Ujfalusi , Tomi Valkeinen Subject: [PATCH 0/3] drm/omap: fix am4 evm lcd Date: Thu, 14 Nov 2019 11:39:47 +0200 Message-ID: <20191114093950.4101-1-tomi.valkeinen@ti.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Hi Tony, Thierry, Laurent, After the recent change of moving from omapdrm specific panel-dpi driver to the DRM simple panel, AM4 EVM/ePOS's panel is not working quite right. This series has fixes for it, but I'm not sure if these are the right ways to fix the issues, so comments welcome. 1) Panel driver is not probed. With omapdrm's panel-dpi, the match happened with "panel-dpi" compatible string. Now with panel-simple, the match should happen with the panel model compatible string, which is "osddisplays,osd057T0559-34ts" in the DT file. However, no such compatible exists in panel-simple. Interestingly, the actual panel at least on my EVMs and ePOSes is not osd057T0559-34ts, but osd070t1718-19ts. Also, I was unable to find any information about osd057T0559-34ts. I don't know the history with this, so it is possible that the early versions of the boards did have osd057T0559-34ts, but was later changed to osd070t1718-19ts. As osd070t1718-19ts is supported by panel-simple, changing the compatible string to osd070t1718-19ts in the DT file solves this one. 2) Timings in DT file cause a kernel warning. Omapdrm's panel-dpi used video timings from the DT file, so they are present in all the DT files. panel-simple uses timings from a table in the panel-simple driver, but gives a kernel warning if the DT file contains timings. This can be solved by removing the timings from the DT file. 3) Sync drive edge is not right. This one might have been present also with panel-dpi, I didn't verify. The problem is that the panel-simple data for osddisplays_osd070t1718_19ts defines bus_flags for DE polarity and pixdata edge, but not for sync edge. The datasheet for the panel does not give any hint on what the edge should be. Omapdrm defaults to driving syncs on falling edge, which caused the image to be shifted one pixel to the right. Adding DRM_BUS_FLAG_SYNC_DRIVE_POSEDGE bus_flag solves the problem. AM5 EVM also has the same panel with the same behavior. ==== The reason I'm not sure if the 1) and 2) fixes are correct is that they're breaking DT compatibility. Should we instead make changes to panel-simple to keep the same DT files working? This would mean adding a new entry for the osd057T0559-34ts panel, but as we don't have datasheet for it, I think we could just append the compatible string to osd070t1718-19t's data. It would also mean doing some change to the panel-simple code that gives the warning about timings in DT data. This might make sense, as I think we have other DT files with video timings too. For 3), I think the patch is fine, but I'm not sure if the display controller driver should be able to deduce the sync drive edge from the pixdata drive edge. Are they usually the same? I have no idea... Tomi Tomi Valkeinen (3): ARM: dts: am437x-gp/epos-evm: fix panel compatible ARM: dts: am437x-gp/epos-evm: drop unused panel timings drm/panel: simple: fix osd070t1718_19ts sync drive edge arch/arm/boot/dts/am437x-gp-evm.dts | 18 +----------------- arch/arm/boot/dts/am43x-epos-evm.dts | 18 +----------------- drivers/gpu/drm/panel/panel-simple.c | 3 ++- 3 files changed, 4 insertions(+), 35 deletions(-) -- Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki Acked-by: Laurent Pinchart