mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-16 04:27:36 +07:00
dfb6db007a
We can communicate the clock rate using platform data rather than setting a flag to use a particular value in the driver, which is cleaner and avoids the dependency. No platform in the kernel currently defines the ep93xx keypad device structure, so this is a rather pointless excercise. Any out of tree users are probably dead now, but if not, they have to change their platform code to match the new platform_data structure. Acked-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Olof Johansson <olof@lixom.net>
33 lines
1.0 KiB
C
33 lines
1.0 KiB
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef __KEYPAD_EP93XX_H
|
|
#define __KEYPAD_EP93XX_H
|
|
|
|
struct matrix_keymap_data;
|
|
|
|
/* flags for the ep93xx_keypad driver */
|
|
#define EP93XX_KEYPAD_DISABLE_3_KEY (1<<0) /* disable 3-key reset */
|
|
#define EP93XX_KEYPAD_DIAG_MODE (1<<1) /* diagnostic mode */
|
|
#define EP93XX_KEYPAD_BACK_DRIVE (1<<2) /* back driving mode */
|
|
#define EP93XX_KEYPAD_TEST_MODE (1<<3) /* scan only column 0 */
|
|
#define EP93XX_KEYPAD_AUTOREPEAT (1<<4) /* enable key autorepeat */
|
|
|
|
/**
|
|
* struct ep93xx_keypad_platform_data - platform specific device structure
|
|
* @keymap_data: pointer to &matrix_keymap_data
|
|
* @debounce: debounce start count; terminal count is 0xff
|
|
* @prescale: row/column counter pre-scaler load value
|
|
* @flags: see above
|
|
*/
|
|
struct ep93xx_keypad_platform_data {
|
|
struct matrix_keymap_data *keymap_data;
|
|
unsigned int debounce;
|
|
unsigned int prescale;
|
|
unsigned int flags;
|
|
unsigned int clk_rate;
|
|
};
|
|
|
|
#define EP93XX_MATRIX_ROWS (8)
|
|
#define EP93XX_MATRIX_COLS (8)
|
|
|
|
#endif /* __KEYPAD_EP93XX_H */
|