• Nikita Yushchenko's avatar
    iio: hi8435: cleanup reset gpio · 61305664
    Nikita Yushchenko authored
    Reset GPIO is active low.
    
    Currently driver uses gpiod_set_value(1) to clean reset, which depends
    on device tree to contain GPIO_ACTIVE_HIGH - that does not match reality.
    
    This fixes driver to use _raw version of gpiod_set_value() to enforce
    active-low semantics despite of what's written in device tree. Allowing
    device tree to override that only opens possibility for errors and does
    not add any value.
    
    Additionally, use _cansleep version to make things work with i2c-gpio
    and other sleeping gpio drivers.
    Signed-off-by: default avatarNikita Yushchenko <nikita.yoush@cogentembedded.com>
    Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
    61305664
hi8435.c 14 KB