Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1449108

Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control method lid device restrictions

From Bastien Nocera <hadess@hadess.net>
Newsgroups linux.kernel
Subject Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control method lid device restrictions
Date 2016-07-24 13:30 +0200
Message-ID <rYpLz-7hd-9@gated-at.bofh.it> (permalink)
References (3 earlier) <rXwvL-6y9-5@gated-at.bofh.it> <rXApH-Uz-7@gated-at.bofh.it> <rXCBb-2fD-3@gated-at.bofh.it> <rXEjE-3pq-17@gated-at.bofh.it> <rXECZ-3Mr-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Fri, 2016-07-22 at 11:08 +0200, Benjamin Tissoires wrote:
> 
<snip>
> Then you just need to amend the documentation to say that the
> fallback
> of the KEY events is not the "future" but a way to get events on some
> reduced platforms and it will not be the default.
> Please make sure userspace knows that the default is the good SW_LID,
> and some particular cases will need to be handled through the KEY
> events, not the other way around.
> 
> [few thoughts later]
> 
> How about:
> - you send only one patch with the SW_LID ON/OFF or OFF/ON when we
> receive the notification on buggy platform
> - in the same patch, you add the documentation saying that on most
> platforms, LID is reliable but some don't provide a reliable LID
> state, but you guarantee to send an event when the state changes
> - in userspace, we add the hwdb which says "on this particular
> platform, don't rely on the actual state, but wait for events" ->
> this
> basically removes the polling on these platforms.
> 
> Bastien, Dmitry?
> 
> I still don't like relying on userspace to actually set the SW_LID
> back to open on resume, as we should not rely on some userspace
> program to set the value (but if logind really wants it, it's up to
> them).

From my point of view, I would only send the events that can actually
be generated by the system, not any synthetic ones, because user-space
would have no way to know that this was synthetic, and how accurate it
would be.

So we'd have a separate API, or a separate event for the "close to
Windows behaviour" devices. We'd then use hwdb in udev to tag the
machines that don't have a reliable LID status, in user-space, so we
can have a quick turn around for those machines.

That should hopefully give us a way to tag test systems, so we can test
the new behaviour, though we'll certainly need to have some changes
made in the stack.

As Benjamin mentioned, it would be nice to have a list of devices that
don't work today, because of this problem.

Cheers

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v4 2/2] ACPI / button: Add document for ACPI control method lid device restrictions Lv Zheng <lv.zheng@intel.com> - 2016-07-19 10:20 +0200
  Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions Benjamin Tissoires <benjamin.tissoires@gmail.com> - 2016-07-19 10:50 +0200
  Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2016-07-21 22:40 +0200
    RE: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions "Zheng, Lv" <lv.zheng@intel.com> - 2016-07-22 02:30 +0200
      Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2016-07-22 06:40 +0200
        Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions Benjamin Tissoires <benjamin.tissoires@gmail.com> - 2016-07-22 09:00 +0200
          RE: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions "Zheng, Lv" <lv.zheng@intel.com> - 2016-07-22 10:50 +0200
            Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions Benjamin Tissoires <benjamin.tissoires@gmail.com> - 2016-07-22 11:10 +0200
              RE: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions "Zheng, Lv" <lv.zheng@intel.com> - 2016-07-22 11:40 +0200
              Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions Bastien Nocera <hadess@hadess.net> - 2016-07-24 13:30 +0200
                RE: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions "Zheng, Lv" <lv.zheng@intel.com> - 2016-07-25 02:40 +0200
          Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2016-07-22 19:10 +0200
            RE: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions "Zheng, Lv" <lv.zheng@intel.com> - 2016-07-23 14:20 +0200
        RE: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions "Zheng, Lv" <lv.zheng@intel.com> - 2016-07-22 10:40 +0200
          Re: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2016-07-22 19:30 +0200
            RE: [PATCH v4 2/2] ACPI / button: Add document for ACPI control  method lid device restrictions "Zheng, Lv" <lv.zheng@intel.com> - 2016-07-23 14:00 +0200

csiph-web