public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Ashish Jangam <Ashish.Jangam@kpitcummins.com>
Cc: "lrg@slimlogic.co.uk" <lrg@slimlogic.co.uk>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	David Dajun Chen <Dajun.Chen@diasemi.com>
Subject: Re: [PATCHv2 5/11 ] REGULATOR: Added current_limit functionality for buck
Date: Fri, 10 Jun 2011 12:33:38 +0100	[thread overview]
Message-ID: <20110610113338.GI26436@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <E2CAE7F7B064EA49B5CE7EE9A4BB167D151C2507A6@KCINPUNHJCMS01.kpit.com>

On Fri, Jun 10, 2011 at 04:45:31PM +0530, Ashish Jangam wrote:
> Hi Mark
> 
> current_limit functionality has been added for bucks. Also get_voltage are replaced by get_voltage_sel and dedicated regulator_ops has been added for bucks and ldos.

Every time you submit patches I find myself telling you to follow the
instructions in SubmittingPatches.  Could you please do this?  Ignoring
this just means the same feedback needs to be provided every time you
resubmit.  There's been some improvement but it's extremely slow and
it's very tiresome having to go over basic issues again and again -
you've been sending these for long enough that we should be over these
issues by now.  As I've said before it really doesn't feel like you're
valuing the time and effort people spend on review.

Here your changelog isn't a changelog for the patch you're submitting at
all, you're submitting a new driver not updating an existing one so your
changelog should be about how you're adding a new driver, you've
got word wrapping issues and so on. an existing one, you've got word
wrapping issues and so on. an existing one, you've got word wrapping
issues and so on. an existing one, you've got word wrapping issues and
so on.

> +static int da9052_dcdc_get_current_limit(struct regulator_dev *rdev)
> +{
> +       struct da9052_regulator *regulator = rdev_get_drvdata(rdev);
> +       int offset = rdev_get_id(rdev);
> +       int ret;
> +
> +       ret = da9052_reg_read(regulator->da9052, DA9052_BUCKA_REG + offset/2);
> +       if (ret < 0)
> +               return ret;
> +
> +/*
> + * Determine the odd or event bit pos of the buck current limit field
> +*/

Indentation and throughout the rest of the driver.

> +static int da9052_set_ldo_voltage(struct regulator_dev *rdev,
> +                       int min_uV, int max_uV, unsigned int *selector)
> +{
> +       return da9052_regulator_set_voltage_int(rdev, min_uV, max_uV, selector);
> +
> +}

You keep adding these random blank lines a the end of functions...

> +static int da9052_get_regulator_voltage_sel(struct regulator_dev *rdev)
> +{
> +       struct da9052_regulator *regulator = rdev_get_drvdata(rdev);
> +       struct da9052_regulator_info *info = regulator->info;
> +       int offset = rdev_get_id(rdev);
> +       int ret;
> +
> +       ret = da9052_reg_read(regulator->da9052, DA9052_BUCKCORE_REG + offset);
> +       if (ret < 0)
> +               return ret;
> +
> +       ret &= ((1 << info->volt_shift) - 1);
> +
> +       return da9052_list_voltage(rdev, ret);
> +

Either your list_voltage() is buggy or this is buggy.  A _sel()
get_voltage() should return a selector and list_voltage() should return
a voltage.  Similarly for the other get_voltage() functions.  Have you
tested this code?

      reply	other threads:[~2011-06-10 11:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-10 11:15 [PATCHv2 5/11 ] REGULATOR: Added current_limit functionality for buck Ashish Jangam
2011-06-10 11:33 ` Mark Brown [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=20110610113338.GI26436@opensource.wolfsonmicro.com \
    --to=broonie@opensource.wolfsonmicro.com \
    --cc=Ashish.Jangam@kpitcummins.com \
    --cc=Dajun.Chen@diasemi.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lrg@slimlogic.co.uk \
    /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