From: Caleb Connolly <caleb@connolly.tech>
To: Gergo Koteles <soyer@irl.hu>, Pavel Machek <pavel@ucw.cz>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>,
Andy Gross <agross@kernel.org>,
Bjorn Andersson <andersson@kernel.org>,
Konrad Dybcio <konrad.dybcio@linaro.org>,
Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
Jiri Kosina <jikos@kernel.org>,
Benjamin Tissoires <benjamin.tissoires@redhat.com>,
linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v2 3/3] arm64: dts: qcom: sdm845-oneplus: add tri-state-key
Date: Sun, 19 Feb 2023 15:30:00 +0000 [thread overview]
Message-ID: <b2becbcf-fd9c-69b5-b208-17f4d0339684@connolly.tech> (raw)
In-Reply-To: <007239f0-1b13-77b9-0d9c-d68747e20331@irl.hu>
On 16/02/2023 03:32, Gergo Koteles wrote:
> Hi,
>
>>
>>
>> On 11/02/2023 16:40, Pavel Machek wrote:
>>> Hi!
>>>
>>>> +++ b/arch/arm64/boot/dts/qcom/sdm845-oneplus-common.dtsi
>>>> @@ -52,6 +52,43 @@ key-vol-up {
>>>> };
>>>> };
>>>>
>>>> + tri-state-key {
>>>> + compatible = "gpio-keys";
>>>> + label = "Tri-state key";
>>>> + pinctrl-names = "default";
>>>> + pinctrl-0 = <&tri_state_key_default>;
>>>> + state-top {
>>>> + label = "Tri-state key top";
>>>
>>> "top/middle" is not too useful. Do we need the label at all? If so,
>>> should it say "loud/vibrations only/mute"?
>>
>> "mute", "vibrate" and "ring" sound good to me.
>>
>
> OnePlus uses the silent/vibrate/ring, iPhone the silent/ring names.
> Maybe silent/vibrate/ring are more familiar.
>
> Adding labels can document these modes here.
> Should we also document these in input-event-codes.h?
Maybe it would be best to define macros for these rather than leave them
as magic numbers
> #define ABS_SND_PROFILE 0x22 /* 0 = silent; 1 = vibrate; 2 = ring */
#define ABS_SND_PROFILE_SILENT 0
#define ABS_SND_PROFILE_VIBRATE 1
#define ABS_SND_PROFILE_RING 2
>
>
> Thanks,
> Gergo
>
>> Although it would be nice if users can easily map the physical key
>> position to the action when viewing the input device or remapping the
>> key in userspace.
>>
>> Do you have any ideas or recommendations on how to do this?
>>>
>>> BR,
>>> Pavel
>>
>> --
>> Kind Regards,
>> Caleb
>>
>
--
Kind Regards,
Caleb
prev parent reply other threads:[~2023-02-19 15:30 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-09 23:25 [PATCH v2 3/3] arm64: dts: qcom: sdm845-oneplus: add tri-state-key Gergo Koteles
2023-02-10 11:33 ` Krzysztof Kozlowski
2023-02-10 13:45 ` Gergo Koteles
2023-02-10 13:53 ` Konrad Dybcio
2023-02-11 16:40 ` Pavel Machek
2023-02-12 1:58 ` Caleb Connolly
2023-02-16 3:32 ` Gergo Koteles
2023-02-19 15:30 ` Caleb Connolly [this message]
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=b2becbcf-fd9c-69b5-b208-17f4d0339684@connolly.tech \
--to=caleb@connolly.tech \
--cc=agross@kernel.org \
--cc=andersson@kernel.org \
--cc=benjamin.tissoires@redhat.com \
--cc=devicetree@vger.kernel.org \
--cc=dmitry.torokhov@gmail.com \
--cc=jikos@kernel.org \
--cc=konrad.dybcio@linaro.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=pavel@ucw.cz \
--cc=robh+dt@kernel.org \
--cc=soyer@irl.hu \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox