devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Lee Jones <lee.jones@linaro.org>
To: Krzysztof Kozlowski <k.kozlowski@samsung.com>
Cc: Rob Herring <rob.herring@calxeda.com>,
	Pawel Moll <pawel.moll@arm.com>,
	Mark Rutland <mark.rutland@arm.com>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	Kumar Gala <galak@codeaurora.org>, Rob Landley <rob@landley.net>,
	Sangbeom Kim <sbkim73@samsung.com>,
	Samuel Ortiz <sameo@linux.intel.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>,
	Grant Likely <grant.likely@linaro.org>,
	Sachin Kamat <sachin.kamat@linaro.org>,
	Thomas Abraham <thomas.abraham@linaro.org>,
	Amit Daniel Kachhap <amit.daniel@samsung.com>,
	devicetree@vger.kernel.org, linux-doc@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	Kyungmin Park <kyungmin.park@samsung.com>,
	Marek Szyprowski <m.szyprowski@samsung.com>
Subject: Re: [PATCH 1/5] regulator: s5m8767: Add symbols for hard-coded DVS_RAMP register
Date: Tue, 17 Dec 2013 14:58:46 +0000	[thread overview]
Message-ID: <20131217145846.GA32283@lee--X1> (raw)
In-Reply-To: <1387289193.13191.9.camel@AMDC1943>

On Tue, 17 Dec 2013, Krzysztof Kozlowski wrote:

> On Tue, 2013-12-17 at 13:51 +0000, Lee Jones wrote:
> > > Add symbols for hard-coded values of BUCK_RAMP field in DVS_RAMP
> > > register. This simplifies a little the code as register update is called
> > > only once.
> > > 
> > > Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
> > > Cc: Kyungmin Park <kyungmin.park@samsung.com>
> > > Cc: Marek Szyprowski <m.szyprowski@samsung.com>
> > > ---
> > >  drivers/regulator/s5m8767.c         |   22 ++++++++++------------
> > >  include/linux/mfd/samsung/s5m8767.h |   15 +++++++++++++++
> > >  2 files changed, 25 insertions(+), 12 deletions(-)
> > 
> > <snip>
> > 
> > > diff --git a/include/linux/mfd/samsung/s5m8767.h b/include/linux/mfd/samsung/s5m8767.h
> > > index 9198377ee859..2ab0b0f03641 100644
> > > --- a/include/linux/mfd/samsung/s5m8767.h
> > > +++ b/include/linux/mfd/samsung/s5m8767.h
> > > @@ -186,4 +186,19 @@ enum s5m8767_regulators {
> > >  #define S5M8767_ENCTRL_SHIFT		6
> > >  #define S5M8767_ENCTRL_MASK		(0x3 << S5M8767_ENCTRL_SHIFT)
> > >  
> > > +/*
> > > + * Values for BUCK_RAMP field in DVS_RAMP register, matching raw values
> > > + * in mV/us.
> > > + */
> > > +enum s5m8767_dvs_buck_ramp_values {
> > > +	S5M8767_DVS_BUCK_RAMP_5		= 0x4,
> > > +	S5M8767_DVS_BUCK_RAMP_10	= 0x9,
> > > +	S5M8767_DVS_BUCK_RAMP_12_5	= 0xb,
> > > +	S5M8767_DVS_BUCK_RAMP_25	= 0xd,
> > > +	S5M8767_DVS_BUCK_RAMP_50	= 0xe,
> > > +	S5M8767_DVS_BUCK_RAMP_100	= 0xf,
> > > +};
> > 
> > Why do these have to be enums?
> 
> There is no special need. I chose enum because it is a kind of
> enumeration of all valid values for BUCK_RAMP field (valid according to
> datasheet). If you prefer #define then I'll change it.

I'm not fussed enough to make you resubmit.

Acked-by: Lee Jones <lee.jones@linaro.org>

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

  reply	other threads:[~2013-12-17 14:58 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-17 13:23 [PATCH 0/5] mfd/regulator: s5m: Various fixes and GPIO control over Buck9 Krzysztof Kozlowski
2013-12-17 13:23 ` [PATCH 1/5] regulator: s5m8767: Add symbols for hard-coded DVS_RAMP register Krzysztof Kozlowski
2013-12-17 13:51   ` Lee Jones
2013-12-17 14:06     ` Krzysztof Kozlowski
2013-12-17 14:58       ` Lee Jones [this message]
2013-12-18 13:27   ` Mark Brown
2013-12-18 13:28   ` Mark Brown
     [not found] ` <1387286601-21646-1-git-send-email-k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2013-12-17 13:23   ` [PATCH 2/5] regulator: s5m8767: Do not use sec_reg* regmap helpers Krzysztof Kozlowski
2013-12-17 15:03     ` Lee Jones
     [not found]     ` <1387286601-21646-3-git-send-email-k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2013-12-18 13:28       ` Mark Brown
2013-12-17 13:23   ` [PATCH 5/5] regulator: s5m8767: Document new bindings for Buck9 GPIO control Krzysztof Kozlowski
2013-12-17 13:23 ` [PATCH 3/5] mfd: sec: Remove sec_reg* regmap helpers Krzysztof Kozlowski
2013-12-18 13:36   ` Mark Brown
2013-12-18 14:03     ` Krzysztof Kozlowski
2013-12-18 17:25       ` Mark Brown
2013-12-17 13:23 ` [PATCH 4/5] regulator: s5m8767: Use GPIO for controlling Buck9/eMMC Krzysztof Kozlowski
2013-12-17 13:49   ` Lee Jones
2013-12-18 13:47   ` Mark Brown
     [not found]     ` <20131218134720.GU28455-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2013-12-18 14:57       ` Krzysztof Kozlowski

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=20131217145846.GA32283@lee--X1 \
    --to=lee.jones@linaro.org \
    --cc=amit.daniel@samsung.com \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=galak@codeaurora.org \
    --cc=grant.likely@linaro.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=k.kozlowski@samsung.com \
    --cc=kyungmin.park@samsung.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=m.szyprowski@samsung.com \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=rob.herring@calxeda.com \
    --cc=rob@landley.net \
    --cc=sachin.kamat@linaro.org \
    --cc=sameo@linux.intel.com \
    --cc=sbkim73@samsung.com \
    --cc=thomas.abraham@linaro.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).