Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1435820
| From | Alexandre Belloni <alexandre.belloni@free-electrons.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation |
| Date | 2016-07-02 15:40 +0200 |
| Message-ID | <rQtjj-48Z-1@gated-at.bofh.it> (permalink) |
| References | <rQdRf-39s-5@gated-at.bofh.it> <rQpfH-1GJ-7@gated-at.bofh.it> <rQpz4-1Nb-21@gated-at.bofh.it> <rQqY9-2RL-13@gated-at.bofh.it> <rQrAR-359-3@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 02/07/2016 at 13:45:18 +0200, Hans de Goede wrote : > Hi, > > On 02-07-16 13:02, Maxime Ripard wrote: > > On Sat, Jul 02, 2016 at 11:32:07AM +0200, Hans de Goede wrote: > > > Hi, > > > > > > On 02-07-16 11:12, Chen-Yu Tsai wrote: > > > > Hi, > > > > > > > > On Sat, Jul 2, 2016 at 5:00 AM, Alexandre Belloni > > > > <alexandre.belloni@free-electrons.com> wrote: > > > > > Document the bindings for the Allwinner LRADC. > > > > > > > > We already have Documentation/devicetree/bindings/input/sun4i-lradc-keys.txt > > > > and I'm pretty sure Hans (CC-ed) argued that this is not a generic ADC > > > > block. > > > > > > Right, this block is used on many tablets and some dev boards to > > > provide buttons (as in the hid type) and the block is designed for > > > this purpose, giving an irq when the adc level crosses a certain > > > threshold. > > > > > > Sure it can be used in a more generic way, but that is not its > > > primary goal. > > > > We've always had a different view on this, but it's a detail :) > > > > > So any generic purpose adc driver must not break the current > > > use-case (which is already used in mainline kernel dts files > > > in plenty of cases). > > > > Yep. > > > > > I believe that the best way to deal with this is to add an > > > "allwinner,general-purpose-mode" flag to the existing binding > > > (as well as document general purpose mode in the existing > > > binding rather then in a new binding doc). > > > > > > That seems to be the right thing to do purely looking at this > > > from a dt binding pov. > > > > There's a way simpler solution: if there's no child nodes, it's meant > > to be used as an ADC, otherwise, as input. > > > > The logic will have to be a bit more complex than that, since there's > > two channels, and you could only require one for the buttons, leaving > > the other one available as an ADC. > > > > But that doesn't require any new property. > > True, if there are no button nodes, then go general-purpose will > work too. > Well, I'd still argue that we need two different compatibles because encoding the usage of an IP in its compatible string is less than ideal. -- Alexandre Belloni, Free Electrons Embedded Linux and Kernel engineering http://free-electrons.com
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 1/2] iio: sun4i-lradc: Add binding documentation Alexandre Belloni <alexandre.belloni@free-electrons.com> - 2016-07-01 23:10 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Chen-Yu Tsai <wens@csie.org> - 2016-07-02 11:20 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Hans de Goede <hdegoede@redhat.com> - 2016-07-02 11:40 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Maxime Ripard <maxime.ripard@free-electrons.com> - 2016-07-02 13:10 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Hans de Goede <hdegoede@redhat.com> - 2016-07-02 13:50 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Alexandre Belloni <alexandre.belloni@free-electrons.com> - 2016-07-02 15:40 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Maxime Ripard <maxime.ripard@free-electrons.com> - 2016-07-02 15:50 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Alexandre Belloni <alexandre.belloni@free-electrons.com> - 2016-07-02 15:40 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Hans de Goede <hdegoede@redhat.com> - 2016-07-02 21:50 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Alexandre Belloni <alexandre.belloni@free-electrons.com> - 2016-07-02 22:50 +0200
Re: [PATCH 1/2] iio: sun4i-lradc: Add binding documentation Jonathan Cameron <jic23@kernel.org> - 2016-07-03 14:10 +0200
csiph-web