Re: [PATCH v5] HID: logitech-hidpp: Add support for HID++ Multi-Platform feature (0x4531)

From: Bastien Nocera

Date: Wed Jul 29 2026 - 11:17:38 EST


Hey,

On Wed, 2026-07-01 at 10:37 +0300, DevExalt wrote:
> +static DEVICE_ATTR_WO(platform);
> +
> +static struct attribute *multiplatform_attrs[] = {
> + &dev_attr_platform.attr,
> + NULL
> +};
> +
> +static const struct attribute_group multiplatform_attribute_group =
> {
> + .attrs = multiplatform_attrs,
> +};

I just realised that even though you retrieve the list of supported
platforms in the code to check whether it's supported, we don't have
any ways to read it. It would really be useful if that was fixed before
merging, it makes verifying that it works as expected much easier,
including whether it can tell user-space that the value changed too.

I tested this with a recent K980 Slim Solar+ keyboard, using the info
in this PDF to switch between macOS, Windows and Chrome using the
keyboard:
https://gzhls.at/blob/ldb/e/3/7/1/4d91f22c1050443f6235092b49270fd021e9.pdf

Shortcuts to switch between platforms:
macos: fn + O
windows: fn + P
chrome: fn + C

The F7 / screenshot key looks like it's something that changes usefully
between platforms:
- macOS: Shift+Win+4
- Windows: Shift+Win+S
- Chrome: SysRq

Testing by between all 3 platforms using both the keyboard keys, and
the sysfs attribute yielded the same results with the changing key
combination generated by the F7 key.

Happy to test again when you have read support added to the sysfs
attribute.

Cheers