Received: by 10.223.176.5 with SMTP id f5csp2928633wra; Thu, 1 Feb 2018 08:10:21 -0800 (PST) X-Google-Smtp-Source: AH8x226ac1+UVPCdS0og7Ou81PzSpT8BX/q70LabGJDL40guXIh/S/8QTLInx4FPH8udByngmd5z X-Received: by 10.99.112.25 with SMTP id l25mr29268970pgc.154.1517501421122; Thu, 01 Feb 2018 08:10:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517501421; cv=none; d=google.com; s=arc-20160816; b=PFTqelsMnwvaXRQByE+BxzFoLHP5uRNFb2IpwAGv/tD4n9lEtrHDnDTUFTMaIBBxyH o6cNvTTvTlIPSAI+25iWL5nK2Yex+GL9eHM/wQKXnr7OIxmL000F0lBTM/HfcAKvQWNr Nh1wFcZC2M4WlHcA41amL6W3su/sW2B6sM/JYZNKnJf4hqiUaTlCv9oW0l+J0k/uDXGP LlwlBowfVeA3xtu9gIAWKGejJfYiK+E8TddgoDW3Cw7BaBUIbSEzxz+whlrKHKwyqKJv FMMcksBZm3RAYXs8h7wE1gjmCvZbAEBSzdW4rPoHdKRMPPAQMWckfBySLnuNvYLBaB0h 4SeQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=jKxu5RLE0Kl7KXLTStD5/codykUJSeN6AfFUHSJcfOc=; b=tPvzeGcgDlrE+YtutK6ODJnd8aRWKeK16nMuwN6BKFXWjyTbGyEfMTCnPYJuX6SBcR iAQmRfD1YGPgPXjoIU0oLCmu/GW0TfO9Fs7NmFCsFZK3uBLweEOeUKmS1JBVdr1jhLlW 1onwuk/vAUPMZoAyv528gGE5fpJUsZgc2zVozoM7l+iT50M0WhNBNAJu1MCTNnouHSZD NdMXxUe2CO1Vi13RXBTOIofkluClV7WmpL43Q1SFZEK2uWeGKVC8Dlmlt/e/3BJNCVQ8 YyYkD3XKChdCerkvRZ0tTZ2b2KXLmvZXP/jwD6MY9w/dFsXtdamiLkVLVgoXd0cBw+OE z4kA== ARC-Authentication-Results: i=1; mx.google.com; dkim=temperror (no key for signature) header.i=@micronovasrl.com header.s=dkim header.b=isKsSjnJ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q13si5263901pgp.262.2018.02.01.08.10.04; Thu, 01 Feb 2018 08:10:21 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=temperror (no key for signature) header.i=@micronovasrl.com header.s=dkim header.b=isKsSjnJ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752189AbeBAQJh (ORCPT + 99 others); Thu, 1 Feb 2018 11:09:37 -0500 Received: from mail.micronovasrl.com ([212.103.203.10]:46820 "EHLO mail.micronovasrl.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751555AbeBAQJg (ORCPT ); Thu, 1 Feb 2018 11:09:36 -0500 Received: from mail.micronovasrl.com (mail.micronovasrl.com [127.0.0.1]) by mail.micronovasrl.com (Postfix) with ESMTP id 0887EB00B83 for ; Thu, 1 Feb 2018 17:09:35 +0100 (CET) Authentication-Results: mail.micronovasrl.com (amavisd-new); dkim=pass reason="pass (just generated, assumed good)" header.d=micronovasrl.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=micronovasrl.com; h=content-transfer-encoding:content-language:content-type :content-type:in-reply-to:mime-version:user-agent:date:date :message-id:from:from:references:to:subject:subject; s=dkim; t= 1517501373; x=1518365374; bh=riRi7zjxngyx9PQGk+HMGat1oG8V4S5Ndsi 6mY4ScSI=; b=isKsSjnJ3nGK9ugevq1qn+rLX4OdWXT+dOnaOY6rZGll+K9eg4i ykQfbfA0Kk5DBnvoa/hXc1QWWmh0Y2Ug3kkdMfG5aOOSpQVgNJUpaVGoaMZ/VD0J VyRk7ADx3/Yp3+LDDjXjOCMv1vK8byvil5HgMsshJmmiN4xFbQEaBWIE= X-Virus-Scanned: Debian amavisd-new at mail.micronovasrl.com X-Spam-Flag: NO X-Spam-Score: -2.9 X-Spam-Level: X-Spam-Status: No, score=-2.9 tagged_above=-10 required=4.5 tests=[ALL_TRUSTED=-1, BAYES_00=-1.9] autolearn=unavailable autolearn_force=no Received: from mail.micronovasrl.com ([127.0.0.1]) by mail.micronovasrl.com (mail.micronovasrl.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id MauOdQol82AG for ; Thu, 1 Feb 2018 17:09:33 +0100 (CET) Received: from [192.168.2.69] (62-11-51-166.dialup.tiscali.it [62.11.51.166]) by mail.micronovasrl.com (Postfix) with ESMTPSA id 70DD5B00379; Thu, 1 Feb 2018 17:09:33 +0100 (CET) Subject: Re: [PATCH 2/2] drm/sun4i: Handle DRM_MODE_FLAG_**SYNC_POSITIVE correctly To: Maxime Ripard Cc: airlied@linux.ie, wens@csie.org, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <1516474221-114596-2-git-send-email-giulio.benetti@micronovasrl.com> <20180122085112.7xo2t3x5ag4k2kpl@flea.lan> <59f7b542-3b1d-ff62-e290-37c47f4075ff@micronovasrl.com> <9929d894-53c3-a7e9-a328-a00cfc1ef546@micronovasrl.com> <20180125152117.qikemrwl7f35ssjg@flea.lan> <20180126145608.5s6c6ltpvrko7iyv@flea.lan> <18ec71dc-a785-a771-76d4-176d95032c97@micronovasrl.com> <20180201101411.d23efsjt7jdyi4zh@flea.lan> From: Giulio Benetti Message-ID: <51323c6d-ba50-f09e-fcd7-d9b18d03673a@micronovasrl.com> Date: Thu, 1 Feb 2018 17:09:33 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 MIME-Version: 1.0 In-Reply-To: <20180201101411.d23efsjt7jdyi4zh@flea.lan> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Language: it Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Il 01/02/2018 11:14, Maxime Ripard ha scritto: > On Sat, Jan 27, 2018 at 11:07:09PM +0100, Giulio Benetti wrote: >>>>>> I don't really know what the polarity of D0 would be just by >>>>>> judging at that capture, but we would have noticed if the colors >>>>>> were inverted for quite some time now. >>>>> >>>>> D0-D23 are correct. >>>>> >>>>> With that capture, I mean to show you instead dclk is inverted, as >>>>> dclk samples D0 on falling edge. >>>> >>>> Ah right, DCLK being the first channel? >>> >>> Yes, sorry I didn't place a label on channels >>> >>>> >>>>> So 0 is NEGEDGE and 1 is POSEDGE(1/3 of clock phase). >>>>> 1/3 clock phase seems enough to me to be considered POSEDGE, >>>>> 2/3 instead risks to go too much to the right of D0(even if it >>>>> could work). >>>> >>>> Do you have captures with both settings? >>> >>> Not now, but asap I'm going to take. >> >> Here we are: >> 1/3 phase: https://pasteboard.co/H4VehON.png >> 2/3 phase: https://pasteboard.co/H4Veq8a.png >> >> Yellow: D0 >> Blue: DCLK >> >> As you can see: >> 1/3 phase has DCLK rising edge almost in the middle of D0 >> 2/3 phase has DCLK rising edge that comes too late >> >> I would go for "1/3 phase" for Rising edge and "normal phase" for >> Falling edge. >> >> What do you think? > > It seems fair. This need a whole lot of comments though :) Yes, then, do I proceed resubmitting both corrected patches with corrected commit logs? > >>>> That it's going to be a nightmare... We've advertised since the very >>>> beginning something, and we're about to break it. I'm not sure we want >>>> to do that. >>> >>> I can take care about that. >>> But I also think that a lot of displays work because they use only >>> DE-mode, almost ignoring HSync and VSync signals(HV-mode). >>> >>> In any case I have to produce these patches because of my company's >>> board based on A20 and A33, and modify defconfig according to it. >>> The only technical nightmare I see is to produce a commit for every >>> defconfig to be modified and copy-paste che commit-log substituing board >>> name(1-2 days of work). >>> Problem is testing, but we're speaking about something that probably was >>> badly working, but you couldn't see it on display. >>> So I think this is only an improvement at the end. >>> >>> I'm sorry I've taken bad news. >>> Drink 1 glass of Spritz to go over! :) >> >> IMHO I think that we have only to take care about displays that don't have >> DE signal. >> >> If DE signal exists, then displays are driven through DE only for back and >> front porch as I know, and on most displays I've used, Hsync and VSync are >> ignored. >> DE is used not only for Data Enable, but also for sync the very beginning of >> frame, the rest of syncing is done by pause between every line sent. >> This is should be why nobody noticed it before, >> I think almost every display is used in DE mode only. >> So, if we fix bug for HSync and VSync, risk should be very low. >> Indeed, everybody or almost, use sync:3 because display ignore those 2 >> signals (HSync and VSYnc) in favour of DE. >> And I don't know how many people checked with oscilloscope signals after >> getting display working in a few. > > I know I did, but I apparently didn't pay attention to that and was > more focused on getting the timings right :) > > But clearly this is a separate discussion that needs to be held on the > U-Boot ML. Ok, so I'd create a patch regarding HSync and VSync polarity and send it to uboot ML. > > Maxime > -- Giulio Benetti R&D Manager & Advanced Research MICRONOVA SRL Sede: Via A. Niedda 3 - 35010 Vigonza (PD) Tel. 049/8931563 - Fax 049/8931346 Cod.Fiscale - P.IVA 02663420285 Capitale Sociale ? 26.000 i.v. Iscritta al Reg. Imprese di Padova N. 02663420285 Numero R.E.A. 258642