Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1610038
| From | Mark Brown <broonie@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] regulator: core: Limit propagation of parent voltage count and list |
| Date | 2017-03-27 20:20 +0200 |
| Message-ID | <tpHpf-3Jt-3@gated-at.bofh.it> (permalink) |
| References | <toDQK-6Kj-13@gated-at.bofh.it> <toEa5-6Td-7@gated-at.bofh.it> <toM7E-4uF-5@gated-at.bofh.it> <tpGWd-3iR-3@gated-at.bofh.it> <tpH5U-3my-13@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
[Multipart message — attachments visible in raw view] - view raw
On Mon, Mar 27, 2017 at 01:54:50PM -0400, Javier Martinez Canillas wrote: > On 03/27/2017 01:39 PM, Matthias Kaehlcke wrote: > > I don't know for sure if this condition is superfluous or if there are > > cases where it makes sense to have a .list_voltage but not > > .get_voltage_sel. > I don't think is the same condition. Unless I'm misreading the code > what it's checking is if there's a .list_voltage even when there is > no .get_voltage_sel. Yes. > IOW, it's valid to have a .list_voltage even when there's no callback > for .get_voltage_sel, but the opposite isn't true. Yes. > >> Something like if (!rdev->supply || !rdev->switch) looks more clear > >> to me. > > I agree and we can even reduce it to if (!rdev_switch) since a switch > > implicitly has a supply. > I wonder if that's always true. What happens if you have a switch but > its <name>-supply parent isn't defined in the Device Tree? We may already be substituting in the dummy supply, I'd need to go check but if we're not that's a fairly straightforward fix for the immediate problem. You do then have to worry about the fact that the parent supply might not have voltage operations either, dummy supplies obviously won't and there are use cases where an actual supply might not either (things like unregulated wall supplies).
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH] regulator: core: Limit propagation of parent voltage count and list Matthias Kaehlcke <mka@chromium.org> - 2017-03-24 21:20 +0100
Re: [PATCH] regulator: core: Limit propagation of parent voltage count and list Brian Norris <briannorris@chromium.org> - 2017-03-24 21:40 +0100
Re: [PATCH] regulator: core: Limit propagation of parent voltage count and list Javier Martinez Canillas <javier@osg.samsung.com> - 2017-03-25 06:10 +0100
Re: [PATCH] regulator: core: Limit propagation of parent voltage count and list Mark Brown <broonie@kernel.org> - 2017-03-27 12:30 +0200
Re: [PATCH] regulator: core: Limit propagation of parent voltage count and list Matthias Kaehlcke <mka@chromium.org> - 2017-03-27 19:50 +0200
Re: [PATCH] regulator: core: Limit propagation of parent voltage count and list Javier Martinez Canillas <javier@osg.samsung.com> - 2017-03-27 20:00 +0200
Re: [PATCH] regulator: core: Limit propagation of parent voltage count and list Mark Brown <broonie@kernel.org> - 2017-03-27 20:20 +0200
Re: [PATCH] regulator: core: Limit propagation of parent voltage count and list Matthias Kaehlcke <mka@chromium.org> - 2017-03-27 20:30 +0200
csiph-web