Skip to content

Commit

Permalink
drivers: gpio: gpio_pca953x: Adding input latch and interrupt mask
Browse files Browse the repository at this point in the history
Resolved git error

Signed-off-by: Vudang Thaihai <[email protected]>
  • Loading branch information
VuDangBP committed Dec 6, 2023
1 parent 2c316ca commit 70bdbfa
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/gpio/gpio_pca953x.c
Original file line number Diff line number Diff line change
Expand Up @@ -445,10 +445,10 @@ static int gpio_pca953x_init(const struct device *dev)
&drv_data->gpio_cb);

/* This may not present on all variants of device */
if (cfg->input_latch != NULL) {
if (cfg->input_latch) {
i2c_reg_write_byte_dt(&cfg->i2c, REG_INPUT_LATCH_PORT0, cfg->input_latch);
}
if (cfg->input_latch != NULL) {
if (cfg->interrupt_mask) {
i2c_reg_write_byte_dt(&cfg->i2c, REG_INT_MASK_PORT0, cfg->interrupt_mask);
}
}
Expand Down

0 comments on commit 70bdbfa

Please sign in to comment.