Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 771d899a authored by Geert Uytterhoeven's avatar Geert Uytterhoeven Committed by Linus Walleij
Browse files

gpio: 74x164: Use spi_write() helper instead of open coding

parent 99468c1a
Loading
Loading
Loading
Loading
+2 −7
Original line number Original line Diff line number Diff line
@@ -35,13 +35,8 @@ struct gen_74x164_chip {


static int __gen_74x164_write_config(struct gen_74x164_chip *chip)
static int __gen_74x164_write_config(struct gen_74x164_chip *chip)
{
{
	struct spi_transfer xfer = {
	return spi_write(to_spi_device(chip->gpio_chip.parent), chip->buffer,
		.tx_buf = chip->buffer,
			 chip->registers);
		.len = chip->registers,
	};

	return spi_sync_transfer(to_spi_device(chip->gpio_chip.parent),
				 &xfer, 1);
}
}


static int gen_74x164_get_value(struct gpio_chip *gc, unsigned offset)
static int gen_74x164_get_value(struct gpio_chip *gc, unsigned offset)