public inbox for linux-arm-kernel@lists.infradead.org 
 help / color / mirror / Atom feed
From: swarren@wwwdotorg•org (Stephen Warren)
To: linux-arm-kernel@lists•infradead.org
Subject: [PATCH 2/2] ARM: dt: tegra: harmony: add regulators
Date: Tue, 28 Aug 2012 16:06:11 -0700	[thread overview]
Message-ID: <503D4EE3.1000603@wwwdotorg.org> (raw)
In-Reply-To: <503CDDEB.1050201@nvidia.com>

On 08/28/2012 08:04 AM, Laxman Dewangan wrote:
> On Tuesday 28 August 2012 12:40 PM, Stephen Warren wrote:
>>   #include "board.h"
>> -#include "board-harmony.h"
>>
>>   #ifdef CONFIG_TEGRA_PCI
>>
>>   int __init harmony_pcie_init(void)
>>   {
>> -       struct regulator *regulator = NULL;
>> +       struct regulator *regulator_1v5, *regulator_pex;
>>          int err;
>>
>> -       err = gpio_request(TEGRA_GPIO_EN_VDD_1V05_GPIO, "EN_VDD_1V05");
>> -       if (err)
>> -               return err;
>> +       regulator_1v5 = regulator_get(NULL, "vdd_1v5");
>> +       if (IS_ERR_OR_NULL(regulator_1v5)) {
>> +               err = PTR_ERR(regulator_1v5);
>> +               goto err_reg;
>> +       }
> 
> You need to return in case of err otherwise it will cause the crash in
> regulator_disable() with NULL argument.

OK, I think I've fixed this and the crash, and re-pushed my personal
linux-next_common. I don't suppose you could retest this. Thanks very much!

  reply	other threads:[~2012-08-28 23:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-28  7:09 [PATCH 1/2] ARM: tegra: remove dead code Stephen Warren
2012-08-28  7:10 ` [PATCH 2/2] ARM: dt: tegra: harmony: add regulators Stephen Warren
2012-08-28 15:04   ` Laxman Dewangan
2012-08-28 23:06     ` Stephen Warren [this message]
2012-08-28 14:49 ` [PATCH 1/2] ARM: tegra: remove dead code Laxman Dewangan
2012-09-11 17:10 ` Stephen Warren

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=503D4EE3.1000603@wwwdotorg.org \
    --to=swarren@wwwdotorg$(echo .)org \
    --cc=linux-arm-kernel@lists$(echo .)infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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