All of lore.kernel.org
 help / color / mirror / Atom feed
From: Werner Sembach <wse@tuxedocomputers.com>
To: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: hdegoede@redhat.com, linux-input@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 1/2] i8042: Add forcenorestore quirk to leave controller untouched even on s3
Date: Wed, 10 Jan 2024 14:51:44 +0100	[thread overview]
Message-ID: <dd140606-6786-4c4f-9e39-448a4df72bb5@tuxedocomputers.com> (raw)
In-Reply-To: <ZZ2_KMGdokHNWcNL@google.com>


Am 09.01.24 um 22:48 schrieb Dmitry Torokhov:
> Hi Werner,
>
> On Thu, Jan 04, 2024 at 07:31:17PM +0100, Werner Sembach wrote:
>> On s3 resume the i8042 driver tries to restore the controller to a known
>> state by reinitializing things, however this can confuse the controller
>> with different effects. Mostly occasionally unresponsive keyboards after
>> resume.
>>
>> These issues do not rise on s0ix resume as here the controller is assumed
>> to preserved its state from before suspend.
>>
>> This patch adds a quirk for devices where the reinitialization on s3 resume
>> is not needed and might be harmful as described above. It does this by
>> using the s0ix resume code path at selected locations.
>>
>> This new quirk goes beyond what the preexisting reset=never quirk does,
>> which only skips some reinitialization steps.
> I think the original change mentioned not only issues on resume, but
> also after boot, which this one does not address, at least directly, so
> I am not sure if this patch is the proper replacement.

The original change introduced issues after boot and fixed issues after resume.

The new quirk fixes the issues after resume without introducing issues after boot.

The issues after boot where only affecting the NHxxRZQ and the N1xxCU iirc.

>
> I would also like to understand better what exact step is troublesome,
> as I would be surprised if any interaction with the keyboard
> controller while suspending causes the issue to manifest. Is it enough,
> by chance, to skip restoring MUX mode and reset?

SERIO_QUIRK_NOMUX and SERIO_QUIRK_RESET_ALWAYS are required in the old fix for 
the resume issues to go away (I don't know if SERIO_QUIRK_NOLOOP and 
SERIO_QUIRK_NOPNP are required, I threw them in just in case because we were 
running them already on the device, so they where somewhat "field proven" to not 
break things).

However while SERIO_QUIRK_NOMUX and SERIO_QUIRK_RESET_ALWAYS for themself did 
not individually introduce the boot problem, in combination they did.

That was all I was able to find out back when I tested the old quirks.

>
> Also, shoudl this system use s2idle by chance?
N1xxCU is s3 only (intel 10th gen clevo)
>
> Thanks.
>

  reply	other threads:[~2024-01-10 13:51 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-04 18:31 [PATCH v4 0/2] i8042: Add forcenorestore quirk to leave controller Werner Sembach
2024-01-04 18:31 ` [PATCH v4 1/2] i8042: Add forcenorestore quirk to leave controller untouched even on s3 Werner Sembach
2024-01-05 19:38   ` Hans de Goede
2024-01-09 21:48   ` Dmitry Torokhov
2024-01-10 13:51     ` Werner Sembach [this message]
2024-01-04 18:31 ` [PATCH v4 2/2] i8042: Use new forcenorestore quirk to replace old buggy quirk combination Werner Sembach
2024-01-05 19:38   ` Hans de Goede

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=dd140606-6786-4c4f-9e39-448a4df72bb5@tuxedocomputers.com \
    --to=wse@tuxedocomputers.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=hdegoede@redhat.com \
    --cc=linux-input@vger.kernel.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.