Commit 7f84e243 authored by José Expósito's avatar José Expósito Committed by Jiri Kosina
Browse files

HID: apple: Add Magic Keyboard 2021 with fingerprint reader FN key mapping



Use the function key table introduced for the Magic Keyboard 2021
without fingerprint reader in the models with fingerprint reader and/or
numpad.

Tested with the ANSI variant of the keyboard with and without numpad.

Signed-off-by: default avatarJosé Expósito <jose.exposito89@gmail.com>
Signed-off-by: default avatarJiri Kosina <jkosina@suse.cz>
parent 531cb569
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -242,7 +242,9 @@ static int hidinput_apple_event(struct hid_device *hid, struct input_dev *input,
	}

	if (fnmode) {
		if (hid->product == USB_DEVICE_ID_APPLE_MAGIC_KEYBOARD_2021)
		if (hid->product == USB_DEVICE_ID_APPLE_MAGIC_KEYBOARD_2021 ||
		    hid->product == USB_DEVICE_ID_APPLE_MAGIC_KEYBOARD_FINGERPRINT_2021 ||
		    hid->product == USB_DEVICE_ID_APPLE_MAGIC_KEYBOARD_NUMPAD_2021)
			table = apple2021_fn_keys;
		else if (hid->product >= USB_DEVICE_ID_APPLE_WELLSPRING4_ANSI &&
				hid->product <= USB_DEVICE_ID_APPLE_WELLSPRING4A_JIS)