From: Grant Likely <grant.likely@secretlab.ca>
To: Michael Trimarchi <michael@amarulasolutions.com>,
Peter Ujfalusi <peter.ujfalusi@ti.com>,
Linus Walleij <linus.walleij@linaro.org>
Cc: linux-kernel@vger.kernel.org, linux-omap@vger.kernel.org
Subject: Re: [PATCH v2 2/3] gpio: twl4030: Cache the direction and output states in private data
Date: Wed, 19 Dec 2012 22:17:41 +0000 [thread overview]
Message-ID: <20121219221741.1E1CA3E0AD6@localhost> (raw)
In-Reply-To: <a26b13f1-84e2-44fa-9801-690f7edf9345@email.android.com>
On Wed, 19 Dec 2012 21:53:23 +0100, Michael Trimarchi <michael@amarulasolutions.com> wrote:
> Hi
>
> Grant Likely <grant.likely@secretlab.ca> wrote:
>
> >On Thu, 6 Dec 2012 11:52:06 +0100, Peter Ujfalusi
> ><peter.ujfalusi@ti.com> wrote:
> >> Use more coherent locking in the driver. Use bitfield to store the
> >GPIO
> >> direction and if the pin is configured as output store the status
> >also in a
> >> bitfiled.
> >> In this way we can just look at these bitfields when we need
> >information
> >> about the pin status and only reach out to the chip when it is
> >needed.
> >>
> >> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
> >
> >Applied, thanks
> >
> >g.
> >
> >> @@ -279,64 +276,98 @@ static void twl_free(struct gpio_chip *chip,
> >unsigned offset)
> >> {
> >> struct gpio_twl4030_priv *priv = to_gpio_twl4030(chip);
> >>
> >> + mutex_lock(&priv->mutex);
> >> if (offset >= TWL4030_GPIO_MAX) {
> >> twl4030_led_set_value(offset - TWL4030_GPIO_MAX, 1);
>
> I have the mobile but where is the unlock here?
Good catch. I've dropped the patch. Peter, please resend a fixed-up version.
g.
next prev parent reply other threads:[~2012-12-19 22:17 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-06 10:52 [PATCH v2 0/3] gpio: twl4030: Correct status reporting for outputs Peter Ujfalusi
2012-12-06 10:52 ` [PATCH v2 1/3] gpio: twl4030: Introduce private structure to store variables needed runtime Peter Ujfalusi
2012-12-19 17:02 ` Grant Likely
2012-12-06 10:52 ` [PATCH v2 2/3] gpio: twl4030: Cache the direction and output states in private data Peter Ujfalusi
2012-12-19 17:03 ` Grant Likely
2012-12-19 20:53 ` Michael Trimarchi
2012-12-19 22:17 ` Grant Likely [this message]
2012-12-06 10:52 ` [PATCH v2 3/3] gpio: twl4030: TODO comment to remove the PWMA/B (LEDA/B) handling Peter Ujfalusi
2012-12-19 17:07 ` Grant Likely
2012-12-20 9:23 ` Peter Ujfalusi
2012-12-20 9:45 ` Grant Likely
2012-12-07 8:09 ` [PATCH v2 0/3] gpio: twl4030: Correct status reporting for outputs Linus Walleij
2012-12-12 11:12 ` Peter Ujfalusi
2012-12-12 11:45 ` Grant Likely
2012-12-12 12:47 ` Peter Ujfalusi
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=20121219221741.1E1CA3E0AD6@localhost \
--to=grant.likely@secretlab.ca \
--cc=linus.walleij@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=michael@amarulasolutions.com \
--cc=peter.ujfalusi@ti.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