| 602 | } |
| 603 | |
| 604 | static void |
| 605 | mv_gpio_double_edge_init(device_t dev, int pin) |
| 606 | { |
| 607 | uint8_t raw_read; |
| 608 | struct mv_gpio_softc *sc; |
| 609 | sc = (struct mv_gpio_softc *)device_get_softc(dev); |
| 610 | |
| 611 | MV_GPIO_ASSERT_LOCKED(); |
| 612 | |
| 613 | raw_read = (mv_gpio_value_get(dev, pin, 1) ? 1 : 0); |
| 614 | |
| 615 | if (raw_read) |
| 616 | mv_gpio_polarity(dev, pin, 1, 0); |
| 617 | else |
| 618 | mv_gpio_polarity(dev, pin, 0, 0); |
| 619 | } |
| 620 | |
| 621 | static int |
| 622 | mv_gpio_debounce_setup(device_t dev, int pin) |
no test coverage detected