All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tzung-Bi Shih <tzungbi@kernel.org>
To: Diogo Ivo <diogo.ivo@tecnico.ulisboa.pt>
Cc: Benson Leung <bleung@chromium.org>,
	Guenter Roeck <groeck@chromium.org>,
	chrome-platform@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] platform/chrome: sensorhub: Support devices without FIFO_INT_ENABLE
Date: Fri, 14 Nov 2025 03:19:59 +0000	[thread overview]
Message-ID: <aRaf39MnKjA3q6iL@google.com> (raw)
In-Reply-To: <20251112-diogo-smaug_ec_sensorhub-v1-1-f71d4e9eb9d4@tecnico.ulisboa.pt>

On Wed, Nov 12, 2025 at 04:00:12PM +0000, Diogo Ivo wrote:
> In order to fix this, since the EC does not provide a way to determine
> a priori if there is support for FIFO_INT_ENABLE send this command
> unconditionally and carefully interpret the return value -EINVAL as a
> device where FIFO_INT_ENABLE is not present and the interrupt is always
> enabled.

Thanks for looking into this.

Simplified the commit message and some side notes:
- -EOPNOTSUPP[1] for learning if a EC command is unsupported.
- FIFO_INT_ENABLE is a sub-command of EC_CMD_MOTION_SENSE_CMD.
- It likely falls into [2].

[1] https://elixir.bootlin.com/linux/v6.17/source/drivers/platform/chrome/cros_ec_proto.c#L22
[2] https://crrev.com/30c5bc8e822436e6a74b36adc24d71293a5ba9c2/common/motion_sense.c#1438


Changed the commit message and code comment, and applied to

    https://git.kernel.org/pub/scm/linux/kernel/git/chrome-platform/linux.git for-next

[1/1] platform/chrome: sensorhub: Support devices without FIFO_INT_ENABLE
      commit: 52075d2c7595cfd6c1ce211a9cd138a9b067c448

Thanks!

  reply	other threads:[~2025-11-14  3:20 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-12 16:00 [PATCH] platform/chrome: sensorhub: Support devices without FIFO_INT_ENABLE Diogo Ivo
2025-11-14  3:19 ` Tzung-Bi Shih [this message]
2025-11-14  9:21   ` Diogo Ivo

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=aRaf39MnKjA3q6iL@google.com \
    --to=tzungbi@kernel.org \
    --cc=bleung@chromium.org \
    --cc=chrome-platform@lists.linux.dev \
    --cc=diogo.ivo@tecnico.ulisboa.pt \
    --cc=groeck@chromium.org \
    --cc=linux-kernel@vger.kernel.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 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.