Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp1015731imm; Mon, 9 Jul 2018 15:22:04 -0700 (PDT) X-Google-Smtp-Source: AAOMgpdaKwI+aea3QWyu6S44AjygiLvqDKX7F8iOftmL4l1SHmf9TcOJPiciWDgATK//FskvSxCh X-Received: by 2002:a63:5c7:: with SMTP id 190-v6mr19967349pgf.385.1531174924195; Mon, 09 Jul 2018 15:22:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531174924; cv=none; d=google.com; s=arc-20160816; b=P1jIzGZWn5/rpah9cMjpB5su3G1dCTmPoP64ETn7v/xf2d9OeyhfMaQG7U3iRaV+VX 86x61iDsuGwDXKfHvhkF6AiMeianCRDuhD4/kvryv8Beo+mrC50kpC62CDssSNQe8GF4 n1o2Qzf57SOMGdDjcTTl/X8Mp/ZmUpFAyuYTXTTw0CCssNB2PHIKHzio+dAqJZpvSI/3 ooRs6CCKnMDoTG6xp1viIxsY5BoE2NhfJ3xAEbmgKkHQMxphOW3zxkZKhFwPUYxZ8e/h SfD72nd7BcDoSYVyo8j/2+zjM74CbMqc9TnHvTbdwIjqqcib4cWl3V+oJatTaDQqjNfC BlpA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=4zLUZcNPtepAG6lhgKZEKk6xjVzcT5JDpDGYT58Mt7o=; b=nVZ+RYLYHbT3bCk5nHtKve20EzPdWCtvH0E4MrgsJdZo2X1hKk1f5fFwz8m2Xjl8Aa HrXu5nfMrpG6USFnLiXl8JqVkNRlBje1wgR0rbJ11zyQ7e2vhbrarno0h+7mVzVO2VvF /G8bNIKC1aeCE1sjFMm/mzlVpqYZykesXDVMj6gtsqieCCB1E5jvNp3sVu3PLYih8JPE LND1S3fmCoWp4+LMCJNM04RbQvCGChKkrKfA2ZjMu9qfapCjJ6kG7lwTpl9c2NQilJvD QJr05be5SeceJj+SI33HYWwKkJCZwDu1skoFfp8fjc7ROFOXUPbNqfOaWOBANr3LUGdz S4ww== ARC-Authentication-Results: i=1; mx.google.com; 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 n5-v6si14253698pgq.167.2018.07.09.15.21.49; Mon, 09 Jul 2018 15:22:04 -0700 (PDT) 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; 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 S1754574AbeGIWUs (ORCPT + 99 others); Mon, 9 Jul 2018 18:20:48 -0400 Received: from sauhun.de ([88.99.104.3]:37208 "EHLO pokefinder.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754406AbeGIWUq (ORCPT ); Mon, 9 Jul 2018 18:20:46 -0400 Received: from localhost (p54B337BD.dip0.t-ipconnect.de [84.179.55.189]) by pokefinder.org (Postfix) with ESMTPSA id 66E1C56A485; Tue, 10 Jul 2018 00:20:44 +0200 (CEST) Date: Tue, 10 Jul 2018 00:20:43 +0200 From: Wolfram Sang To: Jon Hunter Cc: Laxman Dewangan , Shardar Shariff Md , Thierry Reding , linux-i2c@vger.kernel.org, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org Subject: Re: [PATCH] i2c: tegra: Fix NACK error handling Message-ID: <20180709222043.5x627xxpf337uzeq@ninjato> References: <1530608143-9222-1-git-send-email-jonathanh@nvidia.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="2xo4b6y6k67pplbq" Content-Disposition: inline In-Reply-To: <1530608143-9222-1-git-send-email-jonathanh@nvidia.com> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --2xo4b6y6k67pplbq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jul 03, 2018 at 09:55:43AM +0100, Jon Hunter wrote: > On Tegra30 Cardhu the PCA9546 I2C mux is not ACK'ing I2C commands on > resume from suspend (which is caused by the reset signal for the I2C > mux not being configured correctl). However, this NACK is causing the > Tegra30 to hang on resuming from suspend which is not expected as we > detect NACKs and handle them. The hang observed appears to occur when > resetting the I2C controller to recover from the NACK. >=20 > Commit 77821b4678f9 ("i2c: tegra: proper handling of error cases") added > additional error handling for some error cases including NACK, however, > it appears that this change conflicts with an early fix by commit > f70893d08338 ("i2c: tegra: Add delay before resetting the controller > after NACK"). After commit 77821b4678f9 was made we now disable 'packet > mode' before the delay from commit f70893d08338 happens. Testing shows > that moving the delay to before disabling 'packet mode' fixes the hang > observed on Tegra30. The delay was added to give the I2C controller > chance to send a stop condition and so it makes sense to move this to > before we disable packet mode. Please note that packet mode is always > enabled for Tegra. >=20 > Fixes: 77821b4678f9 ("i2c: tegra: proper handling of error cases") >=20 > Cc: stable@vger.kernel.org >=20 > Signed-off-by: Jon Hunter Applied to for-current, thanks! --2xo4b6y6k67pplbq Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEOZGx6rniZ1Gk92RdFA3kzBSgKbYFAltD37gACgkQFA3kzBSg KbbcMhAArzo9LdUX56To43qMeyV6CEgGkqMHimspA76H325QhBdYLTTNU7JmD+u+ zvEF17a/PqbVX7a1SxKUdwdpQ/v5TieLuXya1iWw8rbFF93bSpZPkUCm2ceFn59G RO3KHoUEx6mgG6FE2m9/2kkqsj+4prTZr2n979hvEFFxy6NsHE4zLzRIhoNlHo2d glrGjKPOtdIm9O4HwMSA48S8C2O1dnj+MNXgPyA4t/uqfA6LBTVvg92L++/2Rfof 7Usm973Yd4B/XqHH9QzWlics+QnfRdOyWWkAeeo8ujnzBiOYJAamM/mFv0vBi07O BaZicPaEmW5JWES8gQj9wJkD0wrldEnlJBmR1PR3F7bkeZqU3fnZbj2S9v6TXM/1 Wfm7jB6gHvTZZt62QDkwNNah1VmCdgXwe5cBQJNlDjmjNEpmURLoMtBC0tU22paY QLt65BRX/IPGNMriXp3uJbkgkTUcbi8tNG4PZUR1ZgYPzktcsgAVnb9kqPIi/chw wg5SzAevRz82c6x8fXdONoJsfxUURfD8/pFrQZiuNA2RKF2foSo7foj2x4VHpNT8 wqU7/aWdYo6cTk3d/+2kHtUt3trNUNsLPHfigUnLJ79UrEwelBfZpiixgkv4GOYk H31Nr9G0zoqwGqllP8qnb38fpqv8K8jgL0nNmIYOZQe6ksiCCp8= =FktC -----END PGP SIGNATURE----- --2xo4b6y6k67pplbq--