Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp3901514pxv; Mon, 19 Jul 2021 11:31:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwpIz4UDcwADzdy6kIqIYRNU8axR+oNxIwWirTDgfGjbKgUOUGGqbtzOapssCZz5s9FxLe0 X-Received: by 2002:aa7:db94:: with SMTP id u20mr36186827edt.381.1626719375501; Mon, 19 Jul 2021 11:29:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626719375; cv=none; d=google.com; s=arc-20160816; b=VlsH6ZVNwbPNV3y4OGASH/ns+qX1oAL9spIp6PnrS0LRc4ujcDAiNIk0hDhkmereYd GalOpWYWhl34W+ct5McmlC/giN5Nli3o9JvpVgp3qIGRQR0Vt0Kva17Jar4W0mYp4qcd srD9oW/bxCP3UfH+NmJqElA+NL9sGAqHgExOwPkbfNHGIzZJZIgMRK2HutNN366CT37r l6RCSsyqoNZg7nJx0X/p4UzwNgRX71TwqIAFeYWQ4vQK5y2Olj8cI26DMgBl/j5ksty/ ybFfzWrxLNepddhdDfXutT9rVTj7wITNNX5clHMI0UZhYUlVMLcj20klSjLOHonVzYZ2 WT1g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=HEXZweqgYJVklWr9hryJRs34EHGLfve8XO83yKZu7B8=; b=nCBJPHcVP+m+M7xPqHseifTDp8s0d0itVGSRx/VVSRhXcnGvK80WHwwSEe8jRErPGe tp58wRlHXBaueynltWGSg45XM+jq+uvqQ6/25/Yt59/92ZwrseEwvS9eUaLY3WpeSeIf EwMhkqfCOKqPZSX3a5LeJAPelPJqaynX8C6ceWOM/2btXSFXawCUqxJcmAOLgnuaO3y5 6aKnnRy1G5wqY1LAOaRtnpdDoRDCj+gRrgGaF46rcn+ZV87rCpe6iTPCmXslcyvyIRqM GqstdLu3JwT5NLkm+6GBBUvxrfKjHM+h1q4KxBLJoOZMzMt3yNup4pYPEu69MS1SkcvL 9s8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@denx.de header.s=phobos-20191101 header.b=J+ywi6bQ; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k5si22901899edv.339.2021.07.19.11.29.11; Mon, 19 Jul 2021 11:29:35 -0700 (PDT) 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; dkim=pass header.i=@denx.de header.s=phobos-20191101 header.b=J+ywi6bQ; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1382967AbhGSRn1 (ORCPT + 99 others); Mon, 19 Jul 2021 13:43:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46426 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236213AbhGSRV7 (ORCPT ); Mon, 19 Jul 2021 13:21:59 -0400 Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8E29CC0613B7; Mon, 19 Jul 2021 10:44:21 -0700 (PDT) Received: from [IPv6:::1] (p578adb1c.dip0.t-ipconnect.de [87.138.219.28]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 02023829E7; Mon, 19 Jul 2021 20:00:19 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1626717620; bh=HEXZweqgYJVklWr9hryJRs34EHGLfve8XO83yKZu7B8=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=J+ywi6bQWKnsHS3gBtT5PAfJuzpX5IN4LBOfCQHf/gB1A3uRouP+KjX3FJ5C/1TQr 1+D+F8vIDSO32O6E2Z5+M3XkV0m1MZfejm+UdchLH/ET6AOIJAt3MxWYT4/4cnO3/J XVMdPsaEe3jfFjv7E4VKzP2R4UMXJ1Zc24EJ+yfdv6MCf+2o2NHMoaTxuWW1hAmuHt HjW2nuPFQzTKm4/YyKRzAj2oOsxgGNlGhGwuvz8cJuU1tumkSZTbsWeEWqpsF1MMUN um1GChfcTcVfcTCcy5CdrhzNAiTXXrUq2OAKzSWbQTmGca2e/4RmMepl32SpelDCGW +KRDWIW0ArSRQ== Subject: Re: [PATCH v2 00/10] i2c: xiic: Add features, bug fixes. To: Raviteja Narayanam , Michal Simek , "linux-i2c@vger.kernel.org" Cc: "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , git , "joe@perches.com" References: <20210626102806.15402-1-raviteja.narayanam@xilinx.com> <95162fd0-10e6-2bc6-4079-899ac26f66ce@xilinx.com> <0c51785f-9763-aebc-a9ea-04337ad1accc@denx.de> From: Marek Vasut Message-ID: <45aa8d2b-a077-32a2-0608-8f20a5b807a8@denx.de> Date: Mon, 19 Jul 2021 20:00:19 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 7/19/21 12:09 PM, Raviteja Narayanam wrote: Hi, [...] >>>> -Add 'standard mode' feature for reads > 255 bytes. >>>> -Add 'smbus block read' functionality. >>>> -Add 'xlnx,axi-iic-2.1' new IP version support. >>>> -Switch to 'AXI I2C standard mode' for i2c reads in affected IP versions. >>>> -Remove 'local_irq_save/restore' calls as discussed here: >> https://www.spinics.net/lists/linux-i2c/msg46483.html. >>>> -Some trivial fixes. >>>> >>>> Changes in v2: >>>> -Grouped the commits as fixes first and then features. >>>> -The first 4 commits fix the dynamic mode broken feature. >>>> -Corrected the indentation in coding style issues. >>>> >>>> Michal Simek (1): >>>> i2c: xiic: Fix coding style issues >>>> >>>> Raviteja Narayanam (7): >>>> i2c: xiic: Fix Tx Interrupt path for grouped messages >>>> i2c: xiic: Add standard mode support for > 255 byte read transfers >>>> i2c: xiic: Switch to Xiic standard mode for i2c-read >>>> i2c: xiic: Remove interrupt enable/disable in Rx path >>>> dt-bindings: i2c: xiic: Add 'xlnx,axi-iic-2.1' to compatible >>>> i2c: xiic: Update compatible with new IP version >>>> i2c: xiic: Add smbus_block_read functionality >>>> >>>> Shubhrajyoti Datta (2): >>>> i2c: xiic: Return value of xiic_reinit >>>> i2c: xiic: Fix the type check for xiic_wakeup >>>> >>>> .../bindings/i2c/xlnx,xps-iic-2.00.a.yaml | 4 +- >>>> drivers/i2c/busses/i2c-xiic.c | 593 ++++++++++++++---- >>>> 2 files changed, 487 insertions(+), 110 deletions(-) >>>> >>> >>> Acked-by: Michal Simek >> >> I just tested this patchset on next-20210716 and the XIIC failures are still >> present, see: > > The probe of ' atmel_mxt_ts' failed as per the error. May I know the details of > your test case if you tweaked any i2ctransfers/added delays. It is still the same test case from a year ago -- Atmel MXT touchscreen controller connected to XIIC I2C IP in ZynqMP FPGA, both drivers are compiled into the kernel. Also, it is not the "new" XIIC IP revision, but older one from Vivado 2019 or so. > If it failed without adding anything, then please check whether the vivado design constraints > are correctly applied or not. They are, we already checked multiple times and the FPGA part is OK. > Also check if the other devices on the bus are detected and i2ctransfer command is successful on them. Note that this problem is very likely a race condition in the XIIC driver, so a trivial test like i2ctransfer on idle system from userspace is unlikely to trigger it. When the system is under heavy load e.g. during the kernel boot, that is when these corner cases start showing up. > It would be helpful to know if the device ' atmel_mxt_ts' is successfully probed with next-20210716 > without applying this patchset. Sometimes, the XIIC driver in current mainline Linux suffers from race conditions on SMP, so it depends. The MXT driver also has to be patched to avoid longer than 255 byte transfers, because that is currently broken with XIIC. > I have tested this again on our boards with eeprom and other sensors, this is working fine for us. Can you share details of how those tests were performed ?