Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp585399pxb; Mon, 8 Nov 2021 19:09:35 -0800 (PST) X-Google-Smtp-Source: ABdhPJys5vLkgVYh5v+iDkk2qABASFyBO33QhIsLT5tykf8wqDqhMZV7xh4X/v06iF7PMliYmfgz X-Received: by 2002:a05:6402:350f:: with SMTP id b15mr5660747edd.25.1636427374844; Mon, 08 Nov 2021 19:09:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1636427374; cv=none; d=google.com; s=arc-20160816; b=TktR0vkcyLfs9qYlPWadQi8eW++d0WyAWgR6vYWJ2lca0wpYxSX9V4eOPfZeqFWQ8u l5AvunjPrPy3WIV5j6PUjfhbt+gS9aAxnOXJsVbCTTuPy1LodLPd8ib6TbHcf+GKqyDk nKu2Dn5HSFFECSNExhslQPy8L4dPVsW11h97TgRPDGTym7seeQeP/t+A4mdoy0oqymI7 FzyUTfVmUHGOjr2EDM2S+LtQLLvQnbtMrdqjoxTrGOAL7cUqFZRGRQNfer8XcnE9Qctb t35qxMNoi5meTrVo//hX+FtyL6ZwXeuiK8nJL4kVEpAL92eZnVbsEcqZ3+xgq7ZOJZ+b mhoA== 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:cc:to:subject:from:date; bh=X9Aoq2UEcDsknB17ZIQ7/URyZvXbEP3utFv0ntqs1TE=; b=LWl9yXAgt5nFJMjLn2BgRHJVNGEzujL5ituenDNWh0Ih7I7Ju5Xbn4I3b4pGG7p4Qx rMGo8FK27Rd7b/QYz247OdGsU29YhG6IyNCAovgcXPRX8gl8xTxR0FkMgDDy4iMQHJ4L HT5ibc1dqMGpiTL9FlFuNf6YdTSJIWO34ey/ud9/8TMdvZsogDeLrHMVjhk2Vw5YvixO 8eDgi9maqxgEUMrHBebpgT3gB8DBLl+1HjljAag7RGSPd2XihgoIZNSNDm/vZ2nx8dt4 w2fw9uooB8kr+rmN+xVtSDj5/AzSpZPmMaEg61+zculeLgmuDDKpLS+BQ0KsVNKOVcoG U5xQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=crapouillou.net Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v23si23232201edq.229.2021.11.08.19.09.07; Mon, 08 Nov 2021 19:09:34 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=crapouillou.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236218AbhKHS42 convert rfc822-to-8bit (ORCPT + 99 others); Mon, 8 Nov 2021 13:56:28 -0500 Received: from aposti.net ([89.234.176.197]:33428 "EHLO aposti.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236093AbhKHS42 (ORCPT ); Mon, 8 Nov 2021 13:56:28 -0500 Date: Mon, 08 Nov 2021 18:53:24 +0000 From: Paul Cercueil Subject: Re: [PATCH v5 2/7] drm/ingenic: Add support for JZ4780 and HDMI output To: "H. Nikolaus Schaller" Cc: Rob Herring , Mark Rutland , Thomas Bogendoerfer , Geert Uytterhoeven , Kees Cook , "Eric W. Biederman" , Miquel Raynal , David Airlie , Daniel Vetter , Neil Armstrong , Robert Foss , Laurent Pinchart , Jernej Skrabec , Harry Wentland , Sam Ravnborg , Maxime Ripard , Hans Verkuil , Liam Girdwood , Mark Brown , Paul Boddie , OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS , linux-mips , linux-kernel , Discussions about the Letux Kernel , Jonas Karlman , dri-devel Message-Id: <0HO92R.RF221XL59J3I1@crapouillou.net> In-Reply-To: References: <2c7d0aa7d3ef480ebb996d37c27cbaa6f722728b.1633436959.git.hns@goldelico.com> <7CEBB741-2218-40A7-9800-B3A154895274@goldelico.com> <229EBE4C-6555-41DE-962F-D82798AEC650@goldelico.com> <2E32F572-72D0-44E7-A700-AF8A2D37BFDA@goldelico.com> <2F8A88BC-2696-491B-9C01-7D07A3B3670A@goldelico.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: 8BIT Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Nikolaus, Le lun., nov. 8 2021 at 19:33:48 +0100, H. Nikolaus Schaller a ?crit : > Hi Paul, > >> Am 08.11.2021 um 18:49 schrieb Paul Cercueil : >> >>>> Variant 4: the variant #2 without the changes to the DTSI files. >>> Hm. If there is no cache and we can safely remove tight boundary >>> checking (by JZ_REG_LCD_SIZE1) for jz4725/40/70 (by not fixing >>> DTSI) why do we still need the max_register calculation from DTSI >>> specifically for jz4780 and at all? >> >> It's better to have the .max_register actually set to the proper >> value. Then reading the registers from debugfs >> (/sys/kernel/debug/regmap/) will print the actual list of registers >> without bogus values. If .max_register is set too high, it will end >> up reading outside the registers area. > > Ok, that is a good reason to convince me. > >> On Ingenic SoCs such reads just return 0, but on some other SoCs it >> can lock up the system. > > Yes, I know some of these... > >> So the best way forward is to have .max_register computed from the >> register area's size, and fix the DTSI with the proper sizes. Since >> your JZ4780 code needs to update .max_register anyway it's a good >> moment to add this patch, and the DTSI files can be fixed later (by >> me or whoever is up to the task). > > Well, it would already be part of my Variant #2 (untested). So I > could simply split it up further and you can test the pure dtsi > changes and apply them later or modify if that makes problems. Saves > you a little work. BTW: the jz4740 seems to have even less registers > (last register seems to be LCDCMD1 @ 0x1305005C). Sure, if you want. Send the DTSI patch(es) separate from this patchset then. >> >> Fixing the DTS is not a problem in any way, btw. We just need to >> ensure that the drivers still work with old DTB files, which will be >> the case here. > > Yes, that is right since the new values are smaller than the > originals. > > Ok, then let's do it that way. Great. Waiting for your v6 then. Cheers, -Paul