From: Johan Hovold <johan@kernel.org>
To: Octavian Purdila <octavian.purdila@intel.com>
Cc: Johan Hovold <johan@kernel.org>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Linus Walleij <linus.walleij@linaro.org>,
Alexandre Courbot <gnurou@gmail.com>,
wsa@the-dreams.de, Samuel Ortiz <sameo@linux.intel.com>,
Lee Jones <lee.jones@linaro.org>, Arnd Bergmann <arnd@arndb.de>,
Daniel Baluta <daniel.baluta@intel.com>,
Laurentiu Palcu <laurentiu.palcu@intel.com>,
linux-usb@vger.kernel.org, lkml <linux-kernel@vger.kernel.org>,
linux-gpio@vger.kernel.org, linux-i2c@vger.kernel.org
Subject: Re: [PATCH v4 3/3] gpio: add support for the Diolan DLN-2 USB GPIO driver
Date: Thu, 18 Sep 2014 14:46:11 +0200 [thread overview]
Message-ID: <20140918124611.GA26817@localhost> (raw)
In-Reply-To: <CAE1zot+_hX6TVkW-B6H9NzgyLhF54oQJZt+x_xXGjEB6A5dAZA@mail.gmail.com>
On Thu, Sep 18, 2014 at 03:43:07PM +0300, Octavian Purdila wrote:
> On Thu, Sep 18, 2014 at 1:54 PM, Johan Hovold <johan@kernel.org> wrote:
> > On Tue, Sep 09, 2014 at 10:24:46PM +0300, Octavian Purdila wrote:
> > Either way, it looks like this could race with get_direction() if you
> > get a set_direction() while get_direction() is retrieving the direction
> > from the device.
> >
> > This would break gpio_get().
> >
> I don't think gpio_set_direction() and gpio_get() are allowed to race.
I wrote that set_direction() and get_direction() could race, which in
turn would break gpio_get() as you would be caching the wrong
direction setting.
But perhaps gpiolib prevents this from happening.
Johan
next prev parent reply other threads:[~2014-09-18 12:48 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-09 19:24 [PATCH v4 0/3] mfd: add support for Diolan DLN-2 Octavian Purdila
2014-09-09 19:24 ` [PATCH v4 1/3] mfd: add support for Diolan DLN-2 devices Octavian Purdila
2014-09-16 23:21 ` Lee Jones
2014-09-17 7:25 ` Octavian Purdila
[not found] ` <CAE1zotJWUnduPUd9C8EgSHHSo-OCgdj7c-sKaT5M2Ajj2CmNWw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-09-17 7:38 ` Johan Hovold
2014-09-17 7:38 ` Johan Hovold
2014-09-17 15:56 ` Lee Jones
2014-09-17 9:10 ` Johan Hovold
2014-09-17 15:46 ` Lee Jones
2014-09-17 15:46 ` Lee Jones
[not found] ` <1410290686-6680-2-git-send-email-octavian.purdila-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2014-09-18 11:31 ` Johan Hovold
2014-09-18 11:31 ` Johan Hovold
2014-09-18 14:21 ` Johan Hovold
2014-09-18 14:21 ` Johan Hovold
2014-09-09 19:24 ` [PATCH v4 2/3] i2c: add support for Diolan DLN-2 USB-I2C adapter Octavian Purdila
2014-09-17 9:44 ` Johan Hovold
2014-09-17 10:07 ` Octavian Purdila
2014-09-17 10:07 ` Octavian Purdila
2014-09-18 8:19 ` Johan Hovold
2014-09-18 8:49 ` Octavian Purdila
2014-09-18 9:13 ` Johan Hovold
2014-09-09 19:24 ` [PATCH v4 3/3] gpio: add support for the Diolan DLN-2 USB GPIO driver Octavian Purdila
2014-09-18 10:54 ` Johan Hovold
2014-09-18 12:43 ` Octavian Purdila
2014-09-18 12:46 ` Johan Hovold [this message]
2014-09-18 15:54 ` Octavian Purdila
[not found] ` <CAE1zotK7nb6VVp5a3n2_fnWZQHfizg4hFFy-ZVW5fzyFwmBMcA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-09-19 7:11 ` Johan Hovold
2014-09-19 7:11 ` Johan Hovold
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=20140918124611.GA26817@localhost \
--to=johan@kernel.org \
--cc=arnd@arndb.de \
--cc=daniel.baluta@intel.com \
--cc=gnurou@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=laurentiu.palcu@intel.com \
--cc=lee.jones@linaro.org \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=octavian.purdila@intel.com \
--cc=sameo@linux.intel.com \
--cc=wsa@the-dreams.de \
/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.