Lines Matching refs:gpio_restart
18 struct gpio_restart { struct
27 struct gpio_restart *gpio_restart = data->cb_data; in gpio_restart_notify() argument
30 gpiod_direction_output(gpio_restart->reset_gpio, 1); in gpio_restart_notify()
31 mdelay(gpio_restart->active_delay_ms); in gpio_restart_notify()
34 gpiod_set_value(gpio_restart->reset_gpio, 0); in gpio_restart_notify()
35 mdelay(gpio_restart->inactive_delay_ms); in gpio_restart_notify()
38 gpiod_set_value(gpio_restart->reset_gpio, 1); in gpio_restart_notify()
41 mdelay(gpio_restart->wait_delay_ms); in gpio_restart_notify()
50 struct gpio_restart *gpio_restart; in gpio_restart_probe() local
56 gpio_restart = devm_kzalloc(&pdev->dev, sizeof(*gpio_restart), in gpio_restart_probe()
58 if (!gpio_restart) in gpio_restart_probe()
63 gpio_restart->reset_gpio = devm_gpiod_get(&pdev->dev, NULL, in gpio_restart_probe()
65 ret = PTR_ERR_OR_ZERO(gpio_restart->reset_gpio); in gpio_restart_probe()
72 gpio_restart->active_delay_ms = 100; in gpio_restart_probe()
73 gpio_restart->inactive_delay_ms = 100; in gpio_restart_probe()
74 gpio_restart->wait_delay_ms = 3000; in gpio_restart_probe()
86 &gpio_restart->active_delay_ms); in gpio_restart_probe()
88 &gpio_restart->inactive_delay_ms); in gpio_restart_probe()
90 &gpio_restart->wait_delay_ms); in gpio_restart_probe()
96 gpio_restart); in gpio_restart_probe()