linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Uwe Kleine-König" <u.kleine-koenig-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
To: Wolfram Sang <wsa-z923LK4zBo2bacvFa/9K2g@public.gmane.org>
Cc: Ben Dooks <ben.dooks-4yDnlxn2s6sWdaTGBSpHTA@public.gmane.org>,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-4yDnlxn2s6sWdaTGBSpHTA@public.gmane.org,
	Haavard Skinnemoen
	<hskinnemoen-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Subject: Re: [PATCH] i2c: i2c-gpio: fix some of gpio sleep issues
Date: Wed, 22 Apr 2015 11:05:02 +0200	[thread overview]
Message-ID: <20150422090502.GD23758@pengutronix.de> (raw)
In-Reply-To: <20150327154609.GD27238@katana>

On Fri, Mar 27, 2015 at 04:46:09PM +0100, Wolfram Sang wrote:
> On Tue, Mar 17, 2015 at 12:04:29PM +0000, Ben Dooks wrote:
> > The i2c-gpio driver can be used in systems where the GPIO itself is
> > provided by a GPIO driver that may be sleeping (for example, SPI or
> > USB). In this case, it is preferable to use the _cansleep() variants
> > of the GPIO code.
> > 
> > We can only fix this up for the case where the i2c-gpio implementation
> > provides open-drain outputs as there are no gpio_direction_xxx_cansleep()
> > provided.
> > 
> > This removes the issues on the customer system with the console constantly
> > showing the following warning:
> > 
> > WARNING: CPU: 0 PID: 1 at drivers/gpio/gpiolib.c:2389 gpiod_set_raw_value
> 
> ??? It will silence a warning but will totally break the timing in case
> sleeping is needed? I'd think the warning is very suitable.
I don't understand this objection. What do you mean by "timing"? A
sleeping gpio is probably slower, but this shouldn't affect correctness
of the protocol implementation, should it?

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

      parent reply	other threads:[~2015-04-22  9:05 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-17 12:04 [PATCH] i2c: i2c-gpio: fix some of gpio sleep issues Ben Dooks
     [not found] ` <1426593869-8724-1-git-send-email-ben.dooks-4yDnlxn2s6sWdaTGBSpHTA@public.gmane.org>
2015-03-27 15:46   ` Wolfram Sang
2015-04-22  8:40     ` Ben Dooks
     [not found]       ` <55375E6B.9050405-4yDnlxn2s6sWdaTGBSpHTA@public.gmane.org>
2015-04-22  8:43         ` [Linux-kernel] " Ben Dooks
2015-04-22  9:05     ` Uwe Kleine-König [this message]

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=20150422090502.GD23758@pengutronix.de \
    --to=u.kleine-koenig-bicnvbalz9megne8c9+irq@public.gmane.org \
    --cc=ben.dooks-4yDnlxn2s6sWdaTGBSpHTA@public.gmane.org \
    --cc=hskinnemoen-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-kernel-4yDnlxn2s6sWdaTGBSpHTA@public.gmane.org \
    --cc=wsa-z923LK4zBo2bacvFa/9K2g@public.gmane.org \
    /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;
as well as URLs for NNTP newsgroup(s).