drivers: input: fix few types

Fix few wrong types in various input drivers.

Signed-off-by: Fabio Baltieri <fabiobaltieri@google.com>
This commit is contained in:
Fabio Baltieri 2023-12-05 23:18:02 +00:00 committed by Fabio Baltieri
parent 210bd28a24
commit c161253287
3 changed files with 5 additions and 5 deletions

View file

@ -47,7 +47,7 @@ static void gpio_kbd_matrix_drive_column(const struct device *dev, int col)
const struct gpio_kbd_matrix_config *cfg = dev->config;
const struct input_kbd_matrix_common_config *common = &cfg->common;
struct gpio_kbd_matrix_data *data = dev->data;
int state;
uint32_t state;
if (col == INPUT_KBD_MATRIX_COLUMN_DRIVE_NONE) {
state = 0;
@ -92,7 +92,7 @@ static kbd_row_t gpio_kbd_matrix_read_row(const struct device *dev)
const struct gpio_kbd_matrix_config *cfg = dev->config;
const struct input_kbd_matrix_common_config *common = &cfg->common;
struct gpio_kbd_matrix_data *data = dev->data;
int val = 0;
kbd_row_t val = 0;
if (data->direct_read) {
const struct gpio_dt_spec *gpio0 = &cfg->row_gpio[0];
@ -132,7 +132,7 @@ static void gpio_kbd_matrix_set_detect_mode(const struct device *dev, bool enabl
{
const struct gpio_kbd_matrix_config *cfg = dev->config;
const struct input_kbd_matrix_common_config *common = &cfg->common;
unsigned int flags = enabled ? GPIO_INT_EDGE_BOTH : GPIO_INT_DISABLE;
gpio_flags_t flags = enabled ? GPIO_INT_EDGE_BOTH : GPIO_INT_DISABLE;
int ret;
if (cfg->idle_poll_dwork != NULL) {

View file

@ -131,7 +131,7 @@ static void gpio_qdec_event_worker(struct k_work *work)
static void gpio_qdec_irq_setup(const struct device *dev, bool enable)
{
const struct gpio_qdec_config *cfg = dev->config;
unsigned int flags = enable ? GPIO_INT_EDGE_BOTH : GPIO_INT_DISABLE;
gpio_flags_t flags = enable ? GPIO_INT_EDGE_BOTH : GPIO_INT_DISABLE;
int ret;
for (int i = 0; i < GPIO_QDEC_GPIO_NUM; i++) {

View file

@ -102,7 +102,7 @@ static kbd_row_t npcx_kbd_read_row(const struct device *dev)
const struct npcx_kbd_config *config = dev->config;
const struct input_kbd_matrix_common_config *common = &config->common;
struct kbs_reg *const inst = config->base;
int val;
kbd_row_t val;
val = inst->KBSIN;