From patchwork Thu Nov 30 14:30:07 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrzej Hajda X-Patchwork-Id: 10085011 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0A65B6035E for ; Thu, 30 Nov 2017 14:30:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E736F29E53 for ; Thu, 30 Nov 2017 14:30:28 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id DBCDD29E59; Thu, 30 Nov 2017 14:30:28 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AE2D429E53 for ; Thu, 30 Nov 2017 14:30:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752777AbdK3Oa0 (ORCPT ); Thu, 30 Nov 2017 09:30:26 -0500 Received: from mailout2.w1.samsung.com ([210.118.77.12]:36142 "EHLO mailout2.w1.samsung.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752368AbdK3OaW (ORCPT ); Thu, 30 Nov 2017 09:30:22 -0500 Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20171130143020euoutp02c815c70b1712c6cb52d225192d150412~743utFKRz2281222812euoutp02C; Thu, 30 Nov 2017 14:30:20 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20171130143020euoutp02c815c70b1712c6cb52d225192d150412~743utFKRz2281222812euoutp02C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1512052220; bh=/JdzSJvsaYA8G5o5GUuZ56yRMTedUXJYNGXe5s7co1c=; h=From:To:Cc:Subject:Date:In-reply-to:References:From; b=faTeE1VUKReXjkMUw0+fAW/3x1wnlJHpcAA9bPW8l5KfdOdHQZOWbRcfs/poO3F0D +rRLTLo4kt59sINmHHHxcH+QWfZRdNP+JEQ021jmJA1mxYgK/FtC9NqvuGF6eqWE+P Mefz+VTXBfqv8wIv5Wh0tQrEGET7wb+4At8lG+LE= Received: from eusmges2.samsung.com (unknown [203.254.199.241]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20171130143019eucas1p276f314ba7f1d70f80f6183768c19e90f~743uDPILO2367323673eucas1p2R; Thu, 30 Nov 2017 14:30:19 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges2.samsung.com (EUCPMTA) with SMTP id 83.7E.12907.BF5102A5; Thu, 30 Nov 2017 14:30:19 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20171130143018eucas1p1eba2c4f3361e0752cc53a25d217ce616~743tZMuD_2128521285eucas1p13; Thu, 30 Nov 2017 14:30:18 +0000 (GMT) X-AuditID: cbfec7f1-f793a6d00000326b-01-5a2015fb7629 Received: from eusync3.samsung.com ( [203.254.199.213]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id CF.A8.18832.AF5102A5; Thu, 30 Nov 2017 14:30:18 +0000 (GMT) Received: from AMDC2768.DIGITAL.local ([106.120.43.17]) by eusync3.samsung.com (Oracle Communications Messaging Server 7.0.5.31.0 64bit (built May 5 2014)) with ESMTPA id <0P08005A4IYGHDA0@eusync3.samsung.com>; Thu, 30 Nov 2017 14:30:18 +0000 (GMT) From: Andrzej Hajda To: Wolfram Sang , Andi Shyti Cc: Andrzej Hajda , Bartlomiej Zolnierkiewicz , Marek Szyprowski , linux-i2c@vger.kernel.org (open list:I2C SUBSYSTEM), linux-samsung-soc@vger.kernel.org (moderated list:ARM/SAMSUNG EXYNOS ARM ARCHITECTURES) Subject: [PATCH 3/3] i2c: exynos5: do not check TRANS_STATUS in case of Exynos7 variant Date: Thu, 30 Nov 2017 15:30:07 +0100 Message-id: <20171130143007.30258-4-a.hajda@samsung.com> X-Mailer: git-send-email 2.15.0 In-reply-to: <20171130143007.30258-1-a.hajda@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFtrGIsWRmVeSWpSXmKPExsWy7djPc7q/RRWiDLZcFrC4te4cq8X2I89Y LTbOWM9q0fH3C6PFjPP7mCzWHrnLbrHyxCxmB3aPvi2rGD1OnnrC4vF5k1wAcxSXTUpqTmZZ apG+XQJXxv1tr5gLmrgqJj88ztTAuJyji5GTQ0LARKLt5TlGCFtM4sK99WxdjFwcQgJLGSVO 9J1lhHA+M0r8XnqJFabj59YLLBCJZYwSjVdegiWEBP4zSuydnQRiswloSvzdfJMNxBYR8JS4 9bkFrIFZYAGTxIvbPWAJYYFIiXWL9zCB2CwCqhJnzy4Fu4NXwELiQGMz1E3yEou/7wSr5xSw lNg0exHYIAmBRjaJ2zsmM0MUuUhsOz6FCcIWlnh1fAs7hC0j0dlxkAmioZtR4lP/CXYIZwqj xL8PM6C6rSUOH78I9gOzAJ/EpG3TgeIcQHFeiY42IYgSD4n2Gd/ZIGxHiQvHdzND/N/DKDG9 aQnrBEbpBYwMqxhFUkuLc9NTi430ihNzi0vz0vWS83M3MQJj8/S/4x93ML4/YXWIUYCDUYmH 10JQIUqINbGsuDL3EKMEB7OSCK/yCfkoId6UxMqq1KL8+KLSnNTiQ4zSHCxK4ry2UW2RQgLp iSWp2ampBalFMFkmDk6pBsbNp/9drili+i9n8J/vrfGxzEd1DNfvpSrGBySfcfrP3XT8/u+b CZUNt9sP93pLfT9S73C++7pTk5zFxNmpL7bMftt/o77GpZppZoXdkZwndyRKg/k/cJQfKtEp OeZ05ObJihkbN3TGHeO5UtFUmmxYalGoq2S/x+Rn/8Xj5z9dP/mO5duOMC8lluKMREMt5qLi RACo0MljyQIAAA== X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFupkluLIzCtJLcpLzFFi42I5/e/4Vd1fogpRBrevGVrcWneO1WL7kWes FhtnrGe16Pj7hdFixvl9TBZrj9xlt1h5YhazA7tH35ZVjB4nTz1h8fi8SS6AOYrLJiU1J7Ms tUjfLoEr4/62V8wFTVwVkx8eZ2pgXM7RxcjJISFgIvFz6wUWCFtM4sK99WxdjFwcQgJLGCV6 jsxnhXAamSQaJh1kB6liE9CU+Lv5JhuILSLgKXHrcwsLSBGzwCImibNde8GKhAUiJa5s/8gI YrMIqEqcPbsUzOYVsJA40NjMCLFOXmLx951ggzgFLCU2zV4ENIgDaJuFxMvXghMYeRcwMqxi FEktLc5Nzy021CtOzC0uzUvXS87P3cQIDKBtx35u3sF4aWPwIUYBDkYlHt4JwgpRQqyJZcWV uYcYJTiYlUR4lU/IRwnxpiRWVqUW5ccXleakFh9ilOZgURLn7d2zOlJIID2xJDU7NbUgtQgm y8TBKdXAaHG7f1KWw75Nlv26cmyzjUNy5+cvijTpfyL1d1akr97yW7uv64t9uBT+ymXxRekd CXfe7pz41M5JyaPkXWG/x9pDPHvS7vVtry1reOgib/+5lXnOkz22zSlPlLbGHHJ/c6BC/M+8 R7kCa6PX/LlldvLn1s3lB08Xrwp+qmr7J/idffjjzszdJkosxRmJhlrMRcWJAC1or3QcAgAA X-CMS-MailID: 20171130143018eucas1p1eba2c4f3361e0752cc53a25d217ce616 X-Msg-Generator: CA CMS-TYPE: 201P X-CMS-RootMailID: 20171130143018eucas1p1eba2c4f3361e0752cc53a25d217ce616 X-RootMTR: 20171130143018eucas1p1eba2c4f3361e0752cc53a25d217ce616 References: <20171130143007.30258-1-a.hajda@samsung.com> Sender: linux-samsung-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-samsung-soc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP HSI2C_MASTER_ST_LOSE state is not documented properly, extensive tests show that hardware is usually able to recover from this state without interrupting the transfer. On the other side enforcing transfer repetition in such case does not help in many situations, especially on busy systems and causes -EAGAIN and -ETIMEOUT errors. Moreover documentation says that such state can be caused by slave clock stretching, and should not be treated as an error. Signed-off-by: Andrzej Hajda --- drivers/i2c/busses/i2c-exynos5.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/drivers/i2c/busses/i2c-exynos5.c b/drivers/i2c/busses/i2c-exynos5.c index 4ca43980e2ed..d579b45b3092 100644 --- a/drivers/i2c/busses/i2c-exynos5.c +++ b/drivers/i2c/busses/i2c-exynos5.c @@ -445,12 +445,6 @@ static irqreturn_t exynos5_i2c_irq(int irqno, void *dev_id) i2c->state = -ETIMEDOUT; goto stop; } - - trans_status = readl(i2c->regs + HSI2C_TRANS_STATUS); - if ((trans_status & HSI2C_MASTER_ST_MASK) == HSI2C_MASTER_ST_LOSE) { - i2c->state = -EAGAIN; - goto stop; - } } else if (int_status & HSI2C_INT_I2C) { trans_status = readl(i2c->regs + HSI2C_TRANS_STATUS); if (trans_status & HSI2C_NO_DEV_ACK) {