From: Wolfram Sang <wsa@kernel.org>
To: Chunyan Zhang <zhang.lyra@gmail.com>
Cc: Baolin Wang <baolin.wang7@gmail.com>,
Orson Zhai <orsonzhai@gmail.com>,
linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org,
Chunyan Zhang <chunyan.zhang@unisoc.com>,
Linhua Xu <linhua.xu@unisoc.com>
Subject: Re: [PATCH v2] i2c: sprd: use a specific timeout to avoid system hang up issue
Date: Mon, 4 Jan 2021 19:23:53 +0100 [thread overview]
Message-ID: <20210104182353.GA935@ninjato> (raw)
In-Reply-To: <20201214045850.1026293-1-zhang.lyra@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 767 bytes --]
On Mon, Dec 14, 2020 at 12:58:50PM +0800, Chunyan Zhang wrote:
> From: Chunyan Zhang <chunyan.zhang@unisoc.com>
>
> If the i2c device SCL bus being pulled up due to some exception before
> message transfer done, the system cannot receive the completing interrupt
> signal any more, it would not exit waiting loop until MAX_SCHEDULE_TIMEOUT
> jiffies eclipse, that would make the system seemed hang up. To avoid that
> happen, this patch adds a specific timeout for message transfer.
>
> Fixes: 8b9ec0719834 ("i2c: Add Spreadtrum I2C controller driver")
> Signed-off-by: Linhua Xu <linhua.xu@unisoc.com>
> Signed-off-by: Chunyan Zhang <chunyan.zhang@unisoc.com>
Took the liberty to change the errno to ETIMEDOUT and applied to
for-current, thanks!
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2021-01-04 18:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-14 4:58 [PATCH v2] i2c: sprd: use a specific timeout to avoid system hang up issue Chunyan Zhang
2021-01-04 18:23 ` Wolfram Sang [this message]
2021-01-05 2:13 ` Chunyan Zhang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210104182353.GA935@ninjato \
--to=wsa@kernel.org \
--cc=baolin.wang7@gmail.com \
--cc=chunyan.zhang@unisoc.com \
--cc=linhua.xu@unisoc.com \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=orsonzhai@gmail.com \
--cc=zhang.lyra@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox