public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Stephen Warren <swarren@wwwdotorg.org>
To: Andrzej Hajda <a.hajda@samsung.com>
Cc: Lee Jones <lee.jones@linaro.org>,
	Rob Herring <rob.herring@calxeda.com>,
	Pawel Moll <pawel.moll@arm.com>,
	Mark Rutland <mark.rutland@arm.com>,
	Ian Campbell <ian.campbell@citrix.com>,
	Rob Landley <rob@landley.net>,
	Samuel Ortiz <sameo@linux.intel.com>,
	Grant Likely <grant.likely@linaro.org>,
	Sylwester Nawrocki <s.nawrocki@samsung.com>,
	Jonghwa Lee <jonghwa3.lee@samsung.com>,
	Kyungmin Park <kyungmin.park@samsung.com>,
	"open list:OPEN FIRMWARE AND..." <devicetree@vger.kernel.org>,
	open list <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v2] max77693: added device tree support
Date: Tue, 20 Aug 2013 10:41:28 -0600	[thread overview]
Message-ID: <52139C38.6000006@wwwdotorg.org> (raw)
In-Reply-To: <52136400.7040406@samsung.com>

On 08/20/2013 06:41 AM, Andrzej Hajda wrote:
> Hi,
> 
> Thanks for the review.
> 
> On 08/19/2013 11:18 PM, Stephen Warren wrote:
>> On 08/19/2013 05:40 AM, Andrzej Hajda wrote:
>>> max77693 mfd main device uses only wakeup field
>>> from max77693_platform_data. This field is mapped
>>> to wakeup-source common property in device tree.
>>> diff --git a/Documentation/devicetree/bindings/mfd/max77693.txt b/Documentation/devicetree/bindings/mfd/max77693.txt
>>>  Optional properties:
>>>  - regulators : The regulators of max77693 have to be instantiated under subnod
>>>    named "regulators" using the following format.
>>> +- wakeup-source : Indicates if the device can wakeup the system from the sleep
>>> +  state.
>>
>> Does the property mean "can" or "should"?
>>
>> "Can" implies that the property means something about the HW. What
>> exactly does it mean; perhaps that some specific output pin of the chip
>> has been wired to an input IRQ/GPIO of the SoC or PMIC that (can) wake
>> up the system? If so, which pin, signal, ...? Also, doesn't this also
>> depend on the SoC itself supporting its input IRQ/GPIO as a wakeup
>> source, so isn't some co-ordination required between the SoC and chip,
>> such that this property doesn't mean "can wakeup the system", but simply
>> "a signal is routed to the SoC, so perhaps it can wakeup the system".
>>
>> "Should" implies policy, which probably shouldn't be represented in
>> device tree, since DT should describe the HW and not how it should be used.
>
> After short digging I have realized that "wakeup-source" property is
> already parsed by 
> of_i2c_register_devices core function and it should not be parsed again
> by the driver itself.
> So I suppose the description of it can be removed from max77693 binding.
> Do you agree?

Well, that in turn means that the core I2C binding should describe this
property, and it doesn't. So, that just means you need to apply this
part of the patch to a different document instead, but doesn't remove
the need to document exactly what it means...

But, it's reasonable to go ahead and add DT support to the driver based
on the current binding in this patch, and add the documentation for this
property to the I2C core binding document in some other patch.

      reply	other threads:[~2013-08-20 16:41 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-19 10:12 [PATCH RESEND] max77693: added device tree support Andrzej Hajda
2013-08-19 10:44 ` Lee Jones
2013-08-19 11:40   ` [PATCH v2] " Andrzej Hajda
2013-08-19 12:02     ` Lee Jones
2013-08-19 21:18     ` Stephen Warren
2013-08-20  7:13       ` Lee Jones
2013-08-20 12:41       ` Andrzej Hajda
2013-08-20 16:41         ` Stephen Warren [this message]

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=52139C38.6000006@wwwdotorg.org \
    --to=swarren@wwwdotorg.org \
    --cc=a.hajda@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=grant.likely@linaro.org \
    --cc=ian.campbell@citrix.com \
    --cc=jonghwa3.lee@samsung.com \
    --cc=kyungmin.park@samsung.com \
    --cc=lee.jones@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=rob.herring@calxeda.com \
    --cc=rob@landley.net \
    --cc=s.nawrocki@samsung.com \
    --cc=sameo@linux.intel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox