* [PATCH 1/1] HID: Send SwID in GetProtocolVersion
@ 2022-11-11 19:45 Andreas Bergmeier
2022-11-14 14:19 ` Bastien Nocera
2022-11-21 21:35 ` Jiri Kosina
0 siblings, 2 replies; 3+ messages in thread
From: Andreas Bergmeier @ 2022-11-11 19:45 UTC (permalink / raw)
To: lains, jikos, benjamin.tissoires; +Cc: linux-input, linux-kernel
According to docs a SwID should be sent for GetProtocolVersion.
> 0x10.DeviceIndex.0x00.0x1n
where n is SwID
Signed-off-by: Andreas Bergmeier <abergmeier@gmx.net>
---
drivers/hid/hid-logitech-hidpp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hid/hid-logitech-hidpp.c b/drivers/hid/hid-logitech-hidpp.c
index a0c148a8df6c..964a523c3de7 100644
--- a/drivers/hid/hid-logitech-hidpp.c
+++ b/drivers/hid/hid-logitech-hidpp.c
@@ -896,7 +896,7 @@ static int hidpp_root_get_protocol_version(struct hidpp_device *hidpp)
ret = hidpp_send_rap_command_sync(hidpp,
HIDPP_PAGE_ROOT_IDX,
- CMD_ROOT_GET_PROTOCOL_VERSION,
+ CMD_ROOT_GET_PROTOCOL_VERSION | LINUX_KERNEL_SW_ID,
ping_data, sizeof(ping_data), &response);
if (ret == HIDPP_ERROR_INVALID_SUBID) {
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] HID: Send SwID in GetProtocolVersion
2022-11-11 19:45 [PATCH 1/1] HID: Send SwID in GetProtocolVersion Andreas Bergmeier
@ 2022-11-14 14:19 ` Bastien Nocera
2022-11-21 21:35 ` Jiri Kosina
1 sibling, 0 replies; 3+ messages in thread
From: Bastien Nocera @ 2022-11-14 14:19 UTC (permalink / raw)
To: Andreas Bergmeier, lains, jikos, benjamin.tissoires
Cc: linux-input, linux-kernel
On Fri, 2022-11-11 at 20:45 +0100, Andreas Bergmeier wrote:
> According to docs a SwID should be sent for GetProtocolVersion.
> > 0x10.DeviceIndex.0x00.0x1n
> where n is SwID
I would mention the value of CMD_ROOT_GET_PROTOCOL_VERSION (0x10) in
the commit message, but otherwise looks good to me.
Reviewed-by: Bastien Nocera <hadess@hadess.net>
>
> Signed-off-by: Andreas Bergmeier <abergmeier@gmx.net>
> ---
> drivers/hid/hid-logitech-hidpp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/hid/hid-logitech-hidpp.c b/drivers/hid/hid-
> logitech-hidpp.c
> index a0c148a8df6c..964a523c3de7 100644
> --- a/drivers/hid/hid-logitech-hidpp.c
> +++ b/drivers/hid/hid-logitech-hidpp.c
> @@ -896,7 +896,7 @@ static int hidpp_root_get_protocol_version(struct
> hidpp_device *hidpp)
>
> ret = hidpp_send_rap_command_sync(hidpp,
> HIDPP_PAGE_ROOT_IDX,
> - CMD_ROOT_GET_PROTOCOL_VERSION,
> + CMD_ROOT_GET_PROTOCOL_VERSION |
> LINUX_KERNEL_SW_ID,
> ping_data, sizeof(ping_data), &response);
>
> if (ret == HIDPP_ERROR_INVALID_SUBID) {
> --
> 2.34.1
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] HID: Send SwID in GetProtocolVersion
2022-11-11 19:45 [PATCH 1/1] HID: Send SwID in GetProtocolVersion Andreas Bergmeier
2022-11-14 14:19 ` Bastien Nocera
@ 2022-11-21 21:35 ` Jiri Kosina
1 sibling, 0 replies; 3+ messages in thread
From: Jiri Kosina @ 2022-11-21 21:35 UTC (permalink / raw)
To: Andreas Bergmeier; +Cc: lains, benjamin.tissoires, linux-input, linux-kernel
On Fri, 11 Nov 2022, Andreas Bergmeier wrote:
> According to docs a SwID should be sent for GetProtocolVersion.
> > 0x10.DeviceIndex.0x00.0x1n
> where n is SwID
>
> Signed-off-by: Andreas Bergmeier <abergmeier@gmx.net>
> ---
> drivers/hid/hid-logitech-hidpp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/hid/hid-logitech-hidpp.c b/drivers/hid/hid-logitech-hidpp.c
> index a0c148a8df6c..964a523c3de7 100644
> --- a/drivers/hid/hid-logitech-hidpp.c
> +++ b/drivers/hid/hid-logitech-hidpp.c
> @@ -896,7 +896,7 @@ static int hidpp_root_get_protocol_version(struct hidpp_device *hidpp)
>
> ret = hidpp_send_rap_command_sync(hidpp,
> HIDPP_PAGE_ROOT_IDX,
> - CMD_ROOT_GET_PROTOCOL_VERSION,
> + CMD_ROOT_GET_PROTOCOL_VERSION | LINUX_KERNEL_SW_ID,
> ping_data, sizeof(ping_data), &response);
>
> if (ret == HIDPP_ERROR_INVALID_SUBID) {
Applied, thanks Andreas.
--
Jiri Kosina
SUSE Labs
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-11-21 21:35 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-11 19:45 [PATCH 1/1] HID: Send SwID in GetProtocolVersion Andreas Bergmeier
2022-11-14 14:19 ` Bastien Nocera
2022-11-21 21:35 ` Jiri Kosina
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox