xref: /linux/include/linux/input/vivaldi-fmap.h (revision 45ceaf14)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef _VIVALDI_FMAP_H
3 #define _VIVALDI_FMAP_H
4 
5 #include <linux/types.h>
6 
7 #define VIVALDI_MAX_FUNCTION_ROW_KEYS	24
8 
9 /**
10  * struct vivaldi_data - Function row map data for ChromeOS Vivaldi keyboards
11  * @function_row_physmap: An array of scancodes or their equivalent (HID usage
12  *                        codes, encoded rows/columns, etc) for the top
13  *                        row function keys, in an order from left to right
14  * @num_function_row_keys: The number of top row keys in a custom keyboard
15  *
16  * This structure is supposed to be used by ChromeOS keyboards using
17  * the Vivaldi keyboard function row design.
18  */
19 struct vivaldi_data {
20 	u32 function_row_physmap[VIVALDI_MAX_FUNCTION_ROW_KEYS];
21 	unsigned int num_function_row_keys;
22 };
23 
24 ssize_t vivaldi_function_row_physmap_show(const struct vivaldi_data *data,
25 					  char *buf);
26 
27 #endif /* _VIVALDI_FMAP_H */
28