devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Javier Martinez Canillas <javier.martinez@collabora.co.uk>
To: Lee Jones <lee.jones@linaro.org>
Cc: Samuel Ortiz <sameo@linux.intel.com>,
	Olof Johansson <olof@lixom.net>,
	Doug Anderson <dianders@chromium.org>,
	Bill Richardson <wfrichar@chromium.org>,
	Simon Glass <sjg@google.com>,
	Gwendal Grignou <gwendal@google.com>,
	Stephen Barber <smbarber@chromium.org>,
	Filipe Brandenburger <filbranden@google.com>,
	Todd Broch <tbroch@chromium.org>,
	Alexandru M Stan <amstan@chromium.org>,
	Heiko Stuebner <heiko@sntech.de>,
	linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org,
	devicetree@vger.kernel.org,
	Gwendal Grignou <gwendal@chromium.org>
Subject: Re: [PATCH v4 6/8] mfd: cros_ec: Support multiple EC in a system
Date: Wed, 03 Jun 2015 13:49:03 +0200	[thread overview]
Message-ID: <556EE9AF.6030303@collabora.co.uk> (raw)
In-Reply-To: <20150603112741.GA12304@x1>

Hello Lee,

On 06/03/2015 01:27 PM, Lee Jones wrote:
> On Wed, 03 Jun 2015, Javier Martinez Canillas wrote:

[snip]

>> >>  
>> >> -	err = mfd_add_devices(dev, 0, cros_devs,
>> >> -			      ARRAY_SIZE(cros_devs),
>> >> +	if (IS_ENABLED(CONFIG_OF) && dev->of_node)
>> >> +		ec_p.ec_name = of_get_property(dev->of_node, "devname",
>> >> +					       NULL);
>> > 
>> > Has this binding already been accepted?  We don't normally allow
>> > "device name"properties in DT.
>> > 
>> 
>> Sigh, I now noticed that I missed the DT binding change when originally
>> forward porting the patches from the downstream ChromiumOS tree. I'm so
>> sorry about that.
>> 
>> ChromiumOS tree has in Documentation/devicetree/bindings/mfd/cros-ec.txt:
>> 
>> Optional properties (All):
>> - devname: name of the EC. Can be based on its function: for instance,
>>   for Sensor Hub, 'cros_sh', for Power Delivery MCU 'cros_pd'.
>>   If not present, 'cros_ec' can be assumed.
>> 
>> When you say that normally device names are not allowed in DT, do you mean
>> that "devname" is a too generic property name? (which I totally agree) or
>> that DT bindings shouldn't have a property to change a device's name for
>> something more descriptive?
>> 
>> Because for example, the regulator bindings has a "regulator-name" property.
>> If you agree I can change the property to "google,cros-ec-name" which should
>> be more precise.
> 
> I mean, no names of devices are allowed in Device Tree:
> 
>   `git grep name -- arch/arm/boot/dts/ | grep dev`
> 

Ok, but do you agree on having a "google,cros-ec-name" (with no dev on it)
property to define the resource name just like regulators have "regulator-name"
that changes what is shown in /sys/kernel/debug/regulator/$name?

Otherwise all the EC's will be named cros_ec or regardless of their function
and this is shown in both /dev/$name and /sys/class/chromeos/$name.

Best regards,
Javier

  reply	other threads:[~2015-06-03 11:49 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-02  8:11 [PATCH v4 0/8] mfd: cros_ec: Add multi EC and proto v3 support Javier Martinez Canillas
2015-06-02  8:11 ` [PATCH v4 1/8] mfd: cros_ec: Use a zero-length array for command data Javier Martinez Canillas
2015-06-02  8:11 ` [PATCH v4 2/8] mfd: cros_ec: rev cros_ec_commands.h Javier Martinez Canillas
2015-06-02  8:11 ` [PATCH v4 3/8] mfd: cros_ec: Move protocol helpers out of the MFD driver Javier Martinez Canillas
2015-06-02  8:11 ` [PATCH v4 4/8] mfd: cros_ec: add proto v3 skeleton Javier Martinez Canillas
     [not found] ` <1433232671-27679-1-git-send-email-javier.martinez-ZGY8ohtN/8pPYcu2f3hruQ@public.gmane.org>
2015-06-02  8:11   ` [PATCH v4 5/8] mfd: cros_ec: add bus-specific proto v3 code Javier Martinez Canillas
2015-06-02  8:11   ` [PATCH v4 6/8] mfd: cros_ec: Support multiple EC in a system Javier Martinez Canillas
2015-06-03  8:53     ` Lee Jones
2015-06-03 10:12       ` Javier Martinez Canillas
2015-06-03 11:27         ` Lee Jones
2015-06-03 11:49           ` Javier Martinez Canillas [this message]
2015-06-02  8:11   ` [PATCH v4 7/8] mfd: cros_ec: spi: Add a DT property to delay asserting the CS Javier Martinez Canillas
2015-06-02  8:11 ` [PATCH v4 8/8] mfd: cros_ec: spi: Add delay for asserting CS Javier Martinez Canillas
2015-06-02 21:15 ` [PATCH v4 0/8] mfd: cros_ec: Add multi EC and proto v3 support Heiko Stübner
2015-06-03  6:45   ` Javier Martinez Canillas

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=556EE9AF.6030303@collabora.co.uk \
    --to=javier.martinez@collabora.co.uk \
    --cc=amstan@chromium.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dianders@chromium.org \
    --cc=filbranden@google.com \
    --cc=gwendal@chromium.org \
    --cc=gwendal@google.com \
    --cc=heiko@sntech.de \
    --cc=lee.jones@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=olof@lixom.net \
    --cc=sameo@linux.intel.com \
    --cc=sjg@google.com \
    --cc=smbarber@chromium.org \
    --cc=tbroch@chromium.org \
    --cc=wfrichar@chromium.org \
    /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;
as well as URLs for NNTP newsgroup(s).