All of lore.kernel.org
 help / color / mirror / Atom feed
From: Laxman Dewangan <ldewangan-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
To: Jon Hunter <jonathanh-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>,
	linus.walleij-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org,
	robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	mark.rutland-5wv7dgnIgG8@public.gmane.org,
	swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org,
	thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
Cc: gnurou-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
	yamada.masahiro-uWyLwvC0a2jby3iVrkZq2A@public.gmane.org,
	linux-gpio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH V2 2/2] pinctrl: tegra: Add driver to configure voltage and power of io pads
Date: Mon, 21 Nov 2016 15:06:05 +0530	[thread overview]
Message-ID: <5832C005.3070104@nvidia.com> (raw)
In-Reply-To: <b65cf9ea-208a-0704-7cc9-843bc18da508-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>


Hi Jon,
I will update the patch per your comment.
Here is answer for some of the query.

Thanks,
Laxman


On Tuesday 15 November 2016 08:37 PM, Jon Hunter wrote:
> On 09/11/16 13:06, Laxman Dewangan wrote:
>> +/**
>> + * Macro for 1.8V, keep 200mV as tolerance for deciding that
>> + * IO pads should be set for 3.3V (high voltage) or 1.8V.
>> + */
>> +#define TEGRA_IO_PAD_1800000UV_UPPER_LIMIT 2000000
> Is there a reference we could add for the source of this information?

I had a discussion with the ASIC on this and as per them
     1.8 V nominal is (1.62V, 1.98V)
     3.3 V nominal is (2.97V,3.63V)

I am working with them to update the TRM document but we can assume that 
this information will be there in TRM.

>> +	const struct pinctrl_pin_desc *pins_desc;
>> +	int num_pins_desc;
>> +};
>> +
>> +struct tegra_io_pads_regulator_info {
>> +	struct device *dev;
>> +	const struct tegra_io_pads_cfg_info *pads_cfg;
>> +	struct regulator *regulator;
>> +	struct notifier_block regulator_nb;
>> +};
> Is this struct necessary? Seems to be a lot of duplicated information
> from the other structs. Why not add the regulator and regulator_nb to
> the main struct? OK, not all io_pads have a regulator but you are only
> saving one pointer.
Yes, some of IO pads support multi-voltage.


>
> +		if ((vdata->old_uV > TEGRA_IO_PAD_1800000UV_UPPER_LIMIT) &&
> +		    (vdata->min_uV <= TEGRA_IO_PAD_1800000UV_UPPER_LIMIT))
> +			break;
> The data-sheet for Tegra210 only lists 1.8V or 3.3V as supported
> options. Do we need to support a range? Or does the h/w support a range
> of voltages? I am just wondering why we cannot check explicitly for 1.8V
> or 3.3V and treat anything else as an error.

Two voltage level, not range.

WARNING: multiple messages have this Message-ID (diff)
From: Laxman Dewangan <ldewangan@nvidia.com>
To: Jon Hunter <jonathanh@nvidia.com>, <linus.walleij@linaro.org>,
	<robh+dt@kernel.org>, <mark.rutland@arm.com>,
	<swarren@wwwdotorg.org>, <thierry.reding@gmail.com>
Cc: <gnurou@gmail.com>, <yamada.masahiro@socionext.com>,
	<linux-gpio@vger.kernel.org>, <devicetree@vger.kernel.org>,
	<linux-tegra@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH V2 2/2] pinctrl: tegra: Add driver to configure voltage and power of io pads
Date: Mon, 21 Nov 2016 15:06:05 +0530	[thread overview]
Message-ID: <5832C005.3070104@nvidia.com> (raw)
In-Reply-To: <b65cf9ea-208a-0704-7cc9-843bc18da508@nvidia.com>


Hi Jon,
I will update the patch per your comment.
Here is answer for some of the query.

Thanks,
Laxman


On Tuesday 15 November 2016 08:37 PM, Jon Hunter wrote:
> On 09/11/16 13:06, Laxman Dewangan wrote:
>> +/**
>> + * Macro for 1.8V, keep 200mV as tolerance for deciding that
>> + * IO pads should be set for 3.3V (high voltage) or 1.8V.
>> + */
>> +#define TEGRA_IO_PAD_1800000UV_UPPER_LIMIT 2000000
> Is there a reference we could add for the source of this information?

I had a discussion with the ASIC on this and as per them
     1.8 V nominal is (1.62V, 1.98V)
     3.3 V nominal is (2.97V,3.63V)

I am working with them to update the TRM document but we can assume that 
this information will be there in TRM.

>> +	const struct pinctrl_pin_desc *pins_desc;
>> +	int num_pins_desc;
>> +};
>> +
>> +struct tegra_io_pads_regulator_info {
>> +	struct device *dev;
>> +	const struct tegra_io_pads_cfg_info *pads_cfg;
>> +	struct regulator *regulator;
>> +	struct notifier_block regulator_nb;
>> +};
> Is this struct necessary? Seems to be a lot of duplicated information
> from the other structs. Why not add the regulator and regulator_nb to
> the main struct? OK, not all io_pads have a regulator but you are only
> saving one pointer.
Yes, some of IO pads support multi-voltage.


>
> +		if ((vdata->old_uV > TEGRA_IO_PAD_1800000UV_UPPER_LIMIT) &&
> +		    (vdata->min_uV <= TEGRA_IO_PAD_1800000UV_UPPER_LIMIT))
> +			break;
> The data-sheet for Tegra210 only lists 1.8V or 3.3V as supported
> options. Do we need to support a range? Or does the h/w support a range
> of voltages? I am just wondering why we cannot check explicitly for 1.8V
> or 3.3V and treat anything else as an error.

Two voltage level, not range.

  parent reply	other threads:[~2016-11-21  9:36 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-09 13:06 [PATCH V2 0/2] pinctrl: tegra: Add support for IO pad control Laxman Dewangan
2016-11-09 13:06 ` Laxman Dewangan
     [not found] ` <1478696782-11657-1-git-send-email-ldewangan-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-09 13:06   ` [PATCH V2 1/2] pinctrl: tegra: Add DT binding for io pads control Laxman Dewangan
2016-11-09 13:06     ` Laxman Dewangan
2016-11-14 19:34     ` Rob Herring
2016-11-15 11:45       ` Laxman Dewangan
2016-11-15 11:45         ` Laxman Dewangan
     [not found]     ` <1478696782-11657-2-git-send-email-ldewangan-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-15 18:48       ` Jon Hunter
2016-11-15 18:48         ` Jon Hunter
2016-11-21  9:16         ` Laxman Dewangan
2016-11-21  9:16           ` Laxman Dewangan
2016-11-09 13:06   ` [PATCH V2 2/2] pinctrl: tegra: Add driver to configure voltage and power of io pads Laxman Dewangan
2016-11-09 13:06     ` Laxman Dewangan
2016-11-15  8:59     ` Linus Walleij
2016-11-15 15:07     ` Jon Hunter
2016-11-15 15:07       ` Jon Hunter
     [not found]       ` <b65cf9ea-208a-0704-7cc9-843bc18da508-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-21  9:36         ` Laxman Dewangan [this message]
2016-11-21  9:36           ` Laxman Dewangan
     [not found]           ` <5832C005.3070104-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-21 11:08             ` Jon Hunter
2016-11-21 11:08               ` Jon Hunter
     [not found]               ` <89eaabf1-c830-3ae9-5f34-a7f6d79e0816-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-21 12:49                 ` Laxman Dewangan
2016-11-21 12:49                   ` Laxman Dewangan
     [not found]                   ` <5832ED69.3090903-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-21 20:37                     ` Jon Hunter
2016-11-21 20:37                       ` Jon Hunter
     [not found]                       ` <2d442ccc-c438-cf3a-24c4-032d6c906f26-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-22  8:13                         ` Laxman Dewangan
2016-11-22  8:13                           ` Laxman Dewangan
2016-11-21  6:04     ` kbuild test robot
2016-11-21  6:04       ` kbuild test robot
     [not found]     ` <1478696782-11657-3-git-send-email-ldewangan-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-21 21:01       ` Jon Hunter
2016-11-21 21:01         ` Jon Hunter
     [not found]         ` <29e19381-9250-3059-b083-49e8ab56ea7f-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-22  8:15           ` Laxman Dewangan
2016-11-22  8:15             ` Laxman Dewangan
     [not found]             ` <5833FE99.2020004-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2016-11-22  9:45               ` Joe Perches
2016-11-22  9:45                 ` Joe Perches
2016-11-22  9:32                 ` Laxman Dewangan
2016-11-22  9:32                   ` Laxman Dewangan

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=5832C005.3070104@nvidia.com \
    --to=ldewangan-ddmlm1+adcrqt0dzr+alfa@public.gmane.org \
    --cc=devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=gnurou-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=jonathanh-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org \
    --cc=linus.walleij-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=linux-gpio-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-tegra-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=mark.rutland-5wv7dgnIgG8@public.gmane.org \
    --cc=robh+dt-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org \
    --cc=thierry.reding-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org \
    --cc=yamada.masahiro-uWyLwvC0a2jby3iVrkZq2A@public.gmane.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 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.