Re: [PATCH v3] iio: dac: Add support for the AD5592R/AD5593R ADCs/DACs
From: Linus Walleij <hidden>
Date: 2016-03-22 08:49:55
Also in:
linux-gpio, linux-iio
From: Linus Walleij <hidden>
Date: 2016-03-22 08:49:55
Also in:
linux-gpio, linux-iio
On Mon, Mar 21, 2016 at 2:48 PM, Michael Hennerich [off-list ref] wrote:
The thing is that the device directly supports an OPEN DRAIN mode. If the consumer asks for open drain mode - everything works as expected. However instead of utilizing the on-chip feature, GPIOLIB will emulate open drain behaviour by configuring the chip for input when someone writes logic high. So the comment above was really meant to say - remove on-chip OPEN DRAIN mode, consumers should use the GPIOLIB implementation if required.
This is very interesting. So if a hardware has *real* open drain, i.e. a bit in hardware that says "set me in open drain mode" we should manage this in gpiolib and provide a special callback in the vtable for it, right? Because it is certainly better to do this with hardware, if we can. I'll send a draft patch and we can see if this is what you want. Yours, Linus Walleij