From: Kevin Hilman <khilman@deeprootsystems.com>
To: "Gopinath, Thara" <thara@ti.com>
Cc: "linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
"paul@pwsan.com" <paul@pwsan.com>,
"Cousson, Benoit" <b-cousson@ti.com>,
"Sripathy, Vishwanath" <vishwanath.bs@ti.com>,
"Sawant, Anand" <sawant@ti.com>
Subject: Re: [PATCH v4 7/9] OMAP3: PM: Adding debug support to Voltage and Smartreflex drivers
Date: Mon, 15 Nov 2010 14:12:53 -0800 [thread overview]
Message-ID: <878w0ume1m.fsf@deeprootsystems.com> (raw)
In-Reply-To: <5A47E75E594F054BAF48C5E4FC4B92AB035EFF4E67@dbde02.ent.ti.com> (Thara Gopinath's message of "Mon, 15 Nov 2010 16:30:17 +0530")
"Gopinath, Thara" <thara@ti.com> writes:
>>>-----Original Message-----
>>>From: Kevin Hilman [mailto:khilman@deeprootsystems.com]
>>>Sent: Thursday, November 11, 2010 12:43 AM
>>>To: Gopinath, Thara
>>>Cc: linux-omap@vger.kernel.org; paul@pwsan.com; Cousson, Benoit; Sripathy,
>>>Vishwanath; Sawant, Anand
>>>Subject: Re: [PATCH v4 7/9] OMAP3: PM: Adding debug support to Voltage and
>>>Smartreflex drivers
>>>
>>>Thara Gopinath <thara@ti.com> writes:
>>>
>>>> This patch adds debug support to the voltage and smartreflex drivers.
>>>> This means a whole bunch of voltage processor and smartreflex
>>>> parameters are now visible through the pm debugfs.
>>>> The voltage parameters can be viewed at
>>>> /debug/voltage/vdd_<x>/<parameter>
>>>> and the smartreflex parameters can be viewed at
>>>> /debug/vdd_<x>/smartreflex/<parameter>
>>>>
>>>> To enable overriding of these parameters from user side, write 1
>>>> into
>>>> /debug/voltage/vdd_<x>/override_volt_params
>>>
>>>Please just git rid of any sort of override parameter from sysfs.
>>>
>>>Instead, you can detect in the sysfs code itself if any parameters were
>>>changed and then set the vdd->user_override flag.
>
> But when will I unset this flag??
You can't.
And, AFAICT, it wasn't clear from the current code or docs whether this
could work or was expected to work either, e.g., if you set
override_volt_params back to zero, to the original values all get reused?
If you want to provide this feature, then it should be documented and
made clear that this is an intended goal.
Thinking about this more, the main thing I don't like about this
approach is that the active code paths (enable & disable) have to check
each time if any of these values have been overidden.
Rather than have several places in the active code paths where this
override value is checked, there the sysfs methods should simply update
the values that are used by the core code. This way, the core would
not need to know about where the values came from (defalts, volt_data,
user override, etc.)
If you want to provide a way to revert this, then maybe writing -1 will
should switch that value back to the HW default, or volt_data default.
Kevin
next prev parent reply other threads:[~2010-11-15 22:13 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-27 16:10 [PATCH v4 0/9] OMAP3: Adding Smartreflex and Voltage driver support Thara Gopinath
2010-10-27 16:10 ` [PATCH v4 1/9] OMAP3: PM: Adding voltage driver support for OMAP3 Thara Gopinath
2010-11-10 18:59 ` Kevin Hilman
2010-11-15 10:47 ` Gopinath, Thara
[not found] ` <FCCFB4CDC6E5564B9182F639FC356087034C012076@dbde02.ent.ti.com>
2010-11-15 14:55 ` Gopinath, Thara
[not found] ` <87hbfp9gli.fsf@deeprootsystems.com>
[not found] ` <5A47E75E594F054BAF48C5E4FC4B92AB035EFF4E51@dbde02.ent.ti.com>
2010-11-15 19:43 ` Kevin Hilman
2010-12-02 6:13 ` Gopinath, Thara
2010-10-27 16:10 ` [PATCH v4 2/9] OMAP3: PM: Adding smartreflex driver support Thara Gopinath
2010-10-27 16:10 ` [PATCH v4 3/9] OMAP3: PM: Adding smartreflex device file Thara Gopinath
2010-10-28 5:38 ` Varadarajan, Charulatha
2010-10-28 15:26 ` Gopinath, Thara
2010-10-29 4:48 ` Varadarajan, Charulatha
2010-10-27 16:10 ` [PATCH v4 4/9] OMAP3: PM: Adding smartreflex hwmod data Thara Gopinath
2010-10-27 16:10 ` [PATCH v4 5/9] OMAP3: PM: Adding smartreflex class3 driver Thara Gopinath
2010-10-27 16:10 ` [PATCH v4 6/9] OMAP3: PM: Adding T2 enabling of smartreflex support Thara Gopinath
2010-10-27 16:10 ` [PATCH v4 7/9] OMAP3: PM: Adding debug support to Voltage and Smartreflex drivers Thara Gopinath
2010-11-10 19:12 ` Kevin Hilman
2010-11-15 11:00 ` Gopinath, Thara
2010-11-15 22:12 ` Kevin Hilman [this message]
2010-12-08 16:18 ` Gopinath, Thara
2010-12-08 16:34 ` Nishanth Menon
2010-12-09 9:43 ` Gopinath, Thara
2010-12-09 11:23 ` Nishanth Menon
2010-12-09 14:13 ` Gopinath, Thara
2010-12-09 17:19 ` Kevin Hilman
2010-12-09 17:22 ` Nishanth Menon
2010-10-27 16:10 ` [PATCH v4 8/9] OMAP3: PM: Program correct init voltages for VDD1 and VDD2 Thara Gopinath
2010-10-27 16:10 ` [PATCH v4 9/9] OMAP3: PM: Register TWL4030 pmic info with the voltage driver Thara Gopinath
2010-10-27 17:21 ` [PATCH v4 0/9] OMAP3: Adding Smartreflex and Voltage driver support Nishanth Menon
2010-10-28 15:32 ` Gopinath, Thara
2010-11-10 19:03 ` Kevin Hilman
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=878w0ume1m.fsf@deeprootsystems.com \
--to=khilman@deeprootsystems.com \
--cc=b-cousson@ti.com \
--cc=linux-omap@vger.kernel.org \
--cc=paul@pwsan.com \
--cc=sawant@ti.com \
--cc=thara@ti.com \
--cc=vishwanath.bs@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.