From: Andy Shevchenko <andy.shevchenko@gmail.com>
To: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
Cc: Alexandre Courbot <gnurou@gmail.com>,
Linus Walleij <linus.walleij@linaro.org>,
"linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
Sathyanarayanan Kuppuswamy Natarajan <sathyaosid@gmail.com>
Subject: Re: [PATCH v1 1/2] gpio: gpio-wcove: fix GPIO irq status mask
Date: Wed, 19 Apr 2017 23:41:37 +0300 [thread overview]
Message-ID: <CAHp75VefVpwf-Ooom9Am3Gfmc8zR31fqWxTzYXest_+YTOk2yg@mail.gmail.com> (raw)
In-Reply-To: <d2f4d86de7bb816663e1db3a1385ae917aa699ca.1492190203.git.sathyanarayanan.kuppuswamy@linux.intel.com>
On Fri, Apr 14, 2017 at 8:29 PM,
<sathyanarayanan.kuppuswamy@linux.intel.com> wrote:
> From: Kuppuswamy Sathyanarayanan <sathyanarayanan.kuppuswamy@linux.intel.com>
>
> According to Whiskey cove PMIC spec, bit 7 of GPIOIRQ0_REG belongs to
cove -> Cove
> battery IO. So we should skip this bit when checking for GPIO irq pending
irq -> IRQ
> status. Otherwise, wcove_gpio_irq_handler() might go into the infinite
> loop until irq "pending" status becomes 0. This patch fixes this issue.
Ditto.
> +#define GPIO_IRQ0_MASK 0x7f
> +#define GPIO_IRQ1_MASK 0x3f
GENMASK()
> - pending = p[0] | (p[1] << 8);
> + pending = (p[0] & GPIO_IRQ0_MASK) |
> + ((p[1] & GPIO_IRQ1_MASK) << 7);
I would leave this on one line despite 80 characters limit (actually
how long is it?).
--
With Best Regards,
Andy Shevchenko
next prev parent reply other threads:[~2017-04-19 20:41 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-14 17:29 [PATCH v1 1/2] gpio: gpio-wcove: fix GPIO irq status mask sathyanarayanan.kuppuswamy
2017-04-14 17:29 ` sathyanarayanan.kuppuswamy
2017-04-14 17:29 ` [PATCH v1 2/2] gpio: gpio-wcove: fix irq pending status bit width sathyanarayanan.kuppuswamy
2017-04-14 17:29 ` sathyanarayanan.kuppuswamy
2017-04-24 13:15 ` Linus Walleij
2017-04-24 13:15 ` Linus Walleij
2017-04-24 14:27 ` Andy Shevchenko
2017-04-24 14:27 ` Andy Shevchenko
2017-04-19 20:41 ` Andy Shevchenko [this message]
2017-04-19 20:41 ` [PATCH v1 1/2] gpio: gpio-wcove: fix GPIO irq status mask Andy Shevchenko
2017-04-21 0:52 ` sathyanarayanan kuppuswamy
2017-04-21 0:52 ` sathyanarayanan kuppuswamy
2017-04-24 19:15 ` [PATCH v2 1/1] gpio: gpio-wcove: fix GPIO IRQ " sathyanarayanan.kuppuswamy
2017-04-24 19:15 ` sathyanarayanan.kuppuswamy
2017-04-26 14:26 ` Linus Walleij
2017-04-26 14:26 ` Linus Walleij
2017-04-26 14:50 ` Mika Westerberg
2017-04-26 14:50 ` Mika Westerberg
2017-04-26 14:52 ` Andy Shevchenko
2017-04-26 14:52 ` Andy Shevchenko
2017-04-26 16:42 ` Gao, Bin
2017-04-26 16:42 ` Gao, Bin
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=CAHp75VefVpwf-Ooom9Am3Gfmc8zR31fqWxTzYXest_+YTOk2yg@mail.gmail.com \
--to=andy.shevchenko@gmail.com \
--cc=gnurou@gmail.com \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sathyanarayanan.kuppuswamy@linux.intel.com \
--cc=sathyaosid@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.