All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laurentiu Mihalcea <laurentiumihalcea111@gmail.com>
To: Charles Keepax <ckeepax@opensource.cirrus.com>
Cc: Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>,
	Sebastian Krzyszkowiak <sebastian.krzyszkowiak@puri.sm>,
	elena.popa@nxp.com, cosmin.stoica@nxp.com,
	patches@opensource.cirrus.com, linux-sound@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/3] ASoC: wm8962: implement GPIO .get callback
Date: Tue, 1 Dec 2026 23:36:28 +0200	[thread overview]
Message-ID: <148781f6-ebff-42a8-9f3c-61e08fb0f609@gmail.com> (raw)
In-Reply-To: <aw1bjp6Dx90N8Zk7@opensource.cirrus.com>

Hey Charles,

On 11/30/2026 1:18 PM, Charles Keepax wrote:
> On Fri, Nov 27, 2026 at 07:00:37PM +0200, Laurentiu Mihalcea wrote:
>> +	/*
>> +	 * only GPIO5/GPIO6 can be used as inputs! Note the difference between the GPIO
>> +	 * index and the register offset.
>> +	 */
>> +	if (offset != 4 && offset != 5) {
>> +		dev_err(component->dev, "Only GPIO5/GPIO6 can be used as inputs!\n");
>> +		return -EINVAL;
>> +	}
> I feel like it would be better to add a direction_input callback
> and fail there for the other GPIOs. Better to not allow setting
> the GPIO to an input than to error out whilst reading it.


Yeah, I think this makes sense. To be addressed in V2. Thanks!


  reply	other threads:[~2026-12-01 21:36 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-27 17:00 [PATCH 0/3] ASoC: wm8962: make GPIO-based HP detection work Laurentiu Mihalcea
2026-11-27 17:00 ` [PATCH 1/3] ASoC: wm8962: implement GPIO .get callback Laurentiu Mihalcea
2026-11-27 17:22   ` sashiko-bot
2026-11-30 11:18   ` Charles Keepax
2026-12-01 21:36     ` Laurentiu Mihalcea [this message]
2026-11-27 17:00 ` [PATCH 2/3] ASoC: wm8962: add GPIO interrupt controller support Laurentiu Mihalcea
2026-11-27 17:36   ` sashiko-bot
2026-11-30 11:25   ` Charles Keepax
2026-12-01 22:35     ` Laurentiu Mihalcea
2026-11-27 17:00 ` [PATCH 3/3] ASoC: wm8962: fix interrupt mis-firing during runtime_resume() Laurentiu Mihalcea
2026-11-27 17:30   ` sashiko-bot

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=148781f6-ebff-42a8-9f3c-61e08fb0f609@gmail.com \
    --to=laurentiumihalcea111@gmail.com \
    --cc=broonie@kernel.org \
    --cc=ckeepax@opensource.cirrus.com \
    --cc=cosmin.stoica@nxp.com \
    --cc=elena.popa@nxp.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=patches@opensource.cirrus.com \
    --cc=sebastian.krzyszkowiak@puri.sm \
    /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.