mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Keerthy <j-keerthy@ti.com>
To: "Michał Mirosław" <mirq-linux@rere.qmqm.pl>,
	linux-kernel@vger.kernel.org
Cc: Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>, Tony Lindgren <tony@atomide.com>,
	<linux-omap@vger.kernel.org>
Subject: Re: [PATCH 1/2] regulator: tps65910: check TPS65910_NUM_REGS at build time
Date: Tue, 13 Jun 2017 19:31:21 +0530	[thread overview]
Message-ID: <8d9e234b-8963-8ee8-8330-cfbe04f4a119@ti.com> (raw)
In-Reply-To: <0c5e903eed2005e39bdf7abdd1061dffc078109a.1497361550.git.mirq-linux@rere.qmqm.pl>



On Tuesday 13 June 2017 07:28 PM, Michał Mirosław wrote:

Missing commit log?

> Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
> ---
>  drivers/regulator/tps65910-regulator.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/regulator/tps65910-regulator.c b/drivers/regulator/tps65910-regulator.c
> index 696116ebdf50a..81672a58fcc23 100644
> --- a/drivers/regulator/tps65910-regulator.c
> +++ b/drivers/regulator/tps65910-regulator.c
> @@ -1107,6 +1107,7 @@ static int tps65910_probe(struct platform_device *pdev)
>  
>  	switch (tps65910_chip_id(tps65910)) {
>  	case TPS65910:
> +		BUILD_BUG_ON(TPS65910_NUM_REGS < ARRAY_SIZE(tps65910_regs));
>  		pmic->get_ctrl_reg = &tps65910_get_ctrl_register;
>  		pmic->num_regulators = ARRAY_SIZE(tps65910_regs);
>  		pmic->ext_sleep_control = tps65910_ext_sleep_control;
> @@ -1119,6 +1120,7 @@ static int tps65910_probe(struct platform_device *pdev)
>  					DCDCCTRL_DCDCCKSYNC_MASK);
>  		break;
>  	case TPS65911:
> +		BUILD_BUG_ON(TPS65910_NUM_REGS < ARRAY_SIZE(tps65911_regs));
>  		pmic->get_ctrl_reg = &tps65911_get_ctrl_register;
>  		pmic->num_regulators = ARRAY_SIZE(tps65911_regs);
>  		pmic->ext_sleep_control = tps65911_ext_sleep_control;
> @@ -1144,8 +1146,7 @@ static int tps65910_probe(struct platform_device *pdev)
>  	if (!pmic->rdev)
>  		return -ENOMEM;
>  
> -	for (i = 0; i < pmic->num_regulators && i < TPS65910_NUM_REGS;
> -			i++, info++) {
> +	for (i = 0; i < pmic->num_regulators; i++, info++) {
>  		/* Register the regulators */
>  		pmic->info[i] = info;
>  
> 

  parent reply	other threads:[~2017-06-13 14:01 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-13 13:58 Michał Mirosław
2017-06-13 13:58 ` [PATCH 2/2] regulator: tps65910: Allow supply references to the same chip Michał Mirosław
2017-06-13 14:01 ` Keerthy [this message]
2017-06-13 14:35   ` [PATCH 1/2] regulator: tps65910: check TPS65910_NUM_REGS at build time Michał Mirosław
2017-06-13 14:41 ` [PATCH v2 " Michał Mirosław
2017-06-13 14:41   ` [PATCH v2 2/2] regulator: tps65910: Allow supply references to the same chip Michał Mirosław
2017-06-13 17:46     ` Mark Brown
2017-06-13 20:22       ` Michał Mirosław
2017-06-13 20:42         ` Mark Brown
2017-06-14  7:56         ` Javier Martinez Canillas
2017-06-14 12:14           ` Michał Mirosław
2017-06-13 17:44   ` [PATCH v2 1/2] regulator: tps65910: check TPS65910_NUM_REGS at build time Mark Brown

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=8d9e234b-8963-8ee8-8330-cfbe04f4a119@ti.com \
    --to=j-keerthy@ti.com \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=mirq-linux@rere.qmqm.pl \
    --cc=tony@atomide.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

all inboxes | Powered by JetHome®