All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tomasz Figa <tomasz.figa@gmail.com>
To: Naveen Krishna Ch <naveenkrishna.ch@gmail.com>
Cc: linux-iio@vger.kernel.org,
	"linux-samsung-soc@vger.kernel.org"
	<linux-samsung-soc@vger.kernel.org>,
	jic23@cam.ac.uk, Naveen Krishna <naveen@chromium.org>,
	Naveen Krishna Chatradhi <ch.naveen@samsung.com>,
	Doug Anderson <dianders@chromium.org>,
	Lars-Peter Clausen <lars@metafoo.de>
Subject: Re: [PATCH v2] iio: adc: exynos_adc: Handle timeout issues
Date: Thu, 02 May 2013 20:36:02 +0200	[thread overview]
Message-ID: <1807373.1S4VcvAmeI@flatron> (raw)
In-Reply-To: <CAHfPSqCc81765zQVur=AtW2Cf+taYef=LYJK008i03cmYPu0WQ@mail.gmail.com>

On Thursday 02 of May 2013 11:22:27 Naveen Krishna Ch wrote:
> On 2 May 2013 11:10, Tomasz Figa <tomasz.figa@gmail.com> wrote:
> > Hi Naveen,
> > 
> > On Thursday 02 of May 2013 11:01:03 Naveen Krishna Chatradhi wrote:
> >> From: Naveen Krishna Chatradhi <ch.naveen@samsung.com>
> >> 
> >> This patch does the following
> >> 1. use wait_for_completion_timeout instead of
> >> 
> >>    wait_for_completion_interruptible_timeout
> >> 
> >> 2. Reset software if a timeout happens.
> >> 3. Also reduce the timeout to 100milli secs
> > 
> > I wonder what this patch is trying to fix. In what conditions can an
> > ADC conversion time out?
> > 
> > Sorry if it was already explained in discussion. Still, I think that
> > commit message of a patch should explain why it is needed.
> 
> The discussion started with a bug reported by Dan Carpenter
> http://www.gossamer-threads.com/lists/linux/kernel/1693284?page=last
> 
> and during the discussion we found out the return cases of
> wait_for_completion_interruptible_timeout() were not handled properly.
> so we implemented hw_reset during the error cases.
> 
> As such ISR only does a regiser access.  Which may never timeout.
> This patch reduces the timeout and removes the use of interruptible.
> As, ADC's ISR would be too fast to handle the interruptible operation.
> 
> Now i see, there is nothing much this driver is fixing.
> As you suggest, the subject can be little less harsh.

OK, thanks for the explanation.

Best regards,
Tomasz


WARNING: multiple messages have this Message-ID (diff)
From: Tomasz Figa <tomasz.figa-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Naveen Krishna Ch
	<naveenkrishna.ch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: linux-iio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	"linux-samsung-soc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
	<linux-samsung-soc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	jic23-KWPb1pKIrIJaa/9Udqfwiw@public.gmane.org,
	Naveen Krishna <naveen-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>,
	Naveen Krishna Chatradhi
	<ch.naveen-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>,
	Doug Anderson <dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>,
	Lars-Peter Clausen <lars-Qo5EllUWu/uELgA04lAiVw@public.gmane.org>
Subject: Re: [PATCH v2] iio: adc: exynos_adc: Handle timeout issues
Date: Thu, 02 May 2013 20:36:02 +0200	[thread overview]
Message-ID: <1807373.1S4VcvAmeI@flatron> (raw)
In-Reply-To: <CAHfPSqCc81765zQVur=AtW2Cf+taYef=LYJK008i03cmYPu0WQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

On Thursday 02 of May 2013 11:22:27 Naveen Krishna Ch wrote:
> On 2 May 2013 11:10, Tomasz Figa <tomasz.figa-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> > Hi Naveen,
> > 
> > On Thursday 02 of May 2013 11:01:03 Naveen Krishna Chatradhi wrote:
> >> From: Naveen Krishna Chatradhi <ch.naveen-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
> >> 
> >> This patch does the following
> >> 1. use wait_for_completion_timeout instead of
> >> 
> >>    wait_for_completion_interruptible_timeout
> >> 
> >> 2. Reset software if a timeout happens.
> >> 3. Also reduce the timeout to 100milli secs
> > 
> > I wonder what this patch is trying to fix. In what conditions can an
> > ADC conversion time out?
> > 
> > Sorry if it was already explained in discussion. Still, I think that
> > commit message of a patch should explain why it is needed.
> 
> The discussion started with a bug reported by Dan Carpenter
> http://www.gossamer-threads.com/lists/linux/kernel/1693284?page=last
> 
> and during the discussion we found out the return cases of
> wait_for_completion_interruptible_timeout() were not handled properly.
> so we implemented hw_reset during the error cases.
> 
> As such ISR only does a regiser access.  Which may never timeout.
> This patch reduces the timeout and removes the use of interruptible.
> As, ADC's ISR would be too fast to handle the interruptible operation.
> 
> Now i see, there is nothing much this driver is fixing.
> As you suggest, the subject can be little less harsh.

OK, thanks for the explanation.

Best regards,
Tomasz

  reply	other threads:[~2013-05-02 18:36 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-15 16:26 [RFC: PATCH 2/2] iio: adc: exynos_adc: Handle timeout and race conditions Naveen Krishna Chatradhi
2013-03-15 21:53 ` Lars-Peter Clausen
2013-03-15 21:53   ` Lars-Peter Clausen
2013-03-16  0:37   ` Doug Anderson
2013-03-16 14:41     ` Lars-Peter Clausen
2013-03-16 14:41       ` Lars-Peter Clausen
2013-04-03 17:06       ` Doug Anderson
2013-04-03 17:06         ` Doug Anderson
2013-04-05  8:53         ` Lars-Peter Clausen
2013-04-05 14:56           ` Doug Anderson
2013-04-05 14:56             ` Doug Anderson
2013-04-05 16:38             ` Lars-Peter Clausen
2013-04-04  3:59 ` [PATCH 14/14] temp: iio: adc: exynos_adc: Handle timeout issues Naveen Krishna Chatradhi
2013-04-04  4:09   ` Naveen Krishna Ch
2013-04-04  4:06 ` [PATCH] " Naveen Krishna Chatradhi
2013-04-04  4:06   ` Naveen Krishna Chatradhi
2013-04-13  4:36   ` Naveen Krishna Ch
2013-04-13  4:36     ` Naveen Krishna Ch
2013-04-15 16:01     ` Doug Anderson
2013-04-15 16:01       ` Doug Anderson
2013-05-02 18:01   ` [PATCH v2] " Naveen Krishna Chatradhi
2013-05-02 18:10     ` Tomasz Figa
2013-05-02 18:10       ` Tomasz Figa
2013-05-02 18:22       ` Naveen Krishna Ch
2013-05-02 18:22         ` Naveen Krishna Ch
2013-05-02 18:36         ` Tomasz Figa [this message]
2013-05-02 18:36           ` Tomasz Figa
2013-10-11  8:23   ` [PATCH v3] iio: exynos_adc: use wait_for_completion_timeout instead of interruptible Naveen Krishna Chatradhi
2013-10-11 14:30     ` Lars-Peter Clausen
2013-10-11 14:30       ` Lars-Peter Clausen
2013-10-12  6:40       ` Naveen Krishna Ch
2013-10-12  6:40         ` Naveen Krishna Ch
2013-10-15  5:15     ` [PATCH v4] " Naveen Krishna Chatradhi
2013-10-25 15:42       ` Doug Anderson
2013-10-28  5:41     ` [PATCH v5] " Naveen Krishna Chatradhi
2013-11-05  9:45     ` [PATCH v6] " Naveen Krishna Chatradhi
2013-11-10 12:48       ` Tomasz Figa
2013-11-10 12:48         ` Tomasz Figa

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=1807373.1S4VcvAmeI@flatron \
    --to=tomasz.figa@gmail.com \
    --cc=ch.naveen@samsung.com \
    --cc=dianders@chromium.org \
    --cc=jic23@cam.ac.uk \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=naveen@chromium.org \
    --cc=naveenkrishna.ch@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.