Skip to content

Commit

Permalink
gpio: pca953x: correct type of reg_direction
Browse files Browse the repository at this point in the history
The type of reg_direction needs to match the type of the regmap, which
is u8.

Fixes: 0f25fda ("gpio: pca953x: Zap ad-hoc reg_direction cache")
Cc: Cc: <stable@vger.kernel.org>
Signed-off-by: David Jander <david@protonic.nl>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
  • Loading branch information
David Jander authored and Bartosz Golaszewski committed Aug 28, 2019
1 parent a55aa89 commit bc624a0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/gpio/gpio-pca953x.c
Original file line number Diff line number Diff line change
Expand Up @@ -604,7 +604,7 @@ static void pca953x_irq_bus_sync_unlock(struct irq_data *d)
u8 new_irqs;
int level, i;
u8 invert_irq_mask[MAX_BANK];
int reg_direction[MAX_BANK];
u8 reg_direction[MAX_BANK];

regmap_bulk_read(chip->regmap, chip->regs->direction, reg_direction,
NBANK(chip));
Expand Down Expand Up @@ -679,7 +679,7 @@ static bool pca953x_irq_pending(struct pca953x_chip *chip, u8 *pending)
bool pending_seen = false;
bool trigger_seen = false;
u8 trigger[MAX_BANK];
int reg_direction[MAX_BANK];
u8 reg_direction[MAX_BANK];
int ret, i;

if (chip->driver_data & PCA_PCAL) {
Expand Down Expand Up @@ -768,7 +768,7 @@ static int pca953x_irq_setup(struct pca953x_chip *chip,
{
struct i2c_client *client = chip->client;
struct irq_chip *irq_chip = &chip->irq_chip;
int reg_direction[MAX_BANK];
u8 reg_direction[MAX_BANK];
int ret, i;

if (!client->irq)
Expand Down

0 comments on commit bc624a0

Please sign in to comment.