Lines Matching +full:reset +full:- +full:delay
1 // SPDX-License-Identifier: GPL-2.0-only
3 * lms283gf05.c -- support for Samsung LMS283GF05 LCD
10 #include <linux/delay.h>
21 struct gpio_desc *reset; member
27 unsigned char delay; member
32 /* REG, VALUE, DELAY */
95 gpiod_set_value(gpiod, 0); /* De-asserted */ in lms283gf05_reset()
99 gpiod_set_value(gpiod, 0); /* De-asserted */ in lms283gf05_reset()
120 mdelay(seq[i].delay); in lms283gf05_toggle()
127 struct spi_device *spi = st->spi; in lms283gf05_power_set()
130 if (st->reset) in lms283gf05_power_set()
131 lms283gf05_reset(st->reset); in lms283gf05_power_set()
135 if (st->reset) in lms283gf05_power_set()
136 gpiod_set_value(st->reset, 1); /* Asserted */ in lms283gf05_power_set()
152 st = devm_kzalloc(&spi->dev, sizeof(struct lms283gf05_state), in lms283gf05_probe()
155 return -ENOMEM; in lms283gf05_probe()
157 st->reset = gpiod_get_optional(&spi->dev, "reset", GPIOD_OUT_LOW); in lms283gf05_probe()
158 if (IS_ERR(st->reset)) in lms283gf05_probe()
159 return PTR_ERR(st->reset); in lms283gf05_probe()
160 gpiod_set_consumer_name(st->reset, "LMS283GF05 RESET"); in lms283gf05_probe()
162 ld = devm_lcd_device_register(&spi->dev, "lms283gf05", &spi->dev, st, in lms283gf05_probe()
167 st->spi = spi; in lms283gf05_probe()
168 st->ld = ld; in lms283gf05_probe()
173 if (st->reset) in lms283gf05_probe()
174 lms283gf05_reset(st->reset); in lms283gf05_probe()