public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: k.kozlowski@samsung.com (Krzysztof Kozlowski)
To: linux-arm-kernel@lists.infradead.org
Subject: [TRIVIAL PATCH 1/2] regulator: s5m8767: Define symbol for buck control mask
Date: Tue, 10 Dec 2013 10:30:06 +0100	[thread overview]
Message-ID: <1386667806.4008.2.camel@AMDC1943> (raw)
In-Reply-To: <CAK9yfHwz0Swi=vBu_Wynsr5ZDMDfwnFxS1p2Sc6ofabiotEa1w@mail.gmail.com>

On Tue, 2013-12-10 at 14:48 +0530, Sachin Kamat wrote:
> Hi Krzysztof,
> 
> On 10 December 2013 14:39, Krzysztof Kozlowski <k.kozlowski@samsung.com> wrote:
> 
> >  static int s5m8767_reg_disable(struct regulator_dev *rdev)
> >  {
> >         struct s5m8767_info *s5m8767 = rdev_get_drvdata(rdev);
> >         int ret, reg;
> > -       int  mask = 0xc0, enable_ctrl;
> > +       int mask = S5M8767_ENCTRL_MASK, enable_ctrl;
> 
> Couldn't we get rid of this mask variable here too?
> 
> Otherwise the patch looks good to me.

Not in this patch because it leads to warning:

drivers/regulator/s5m8767.c: In function ?s5m8767_reg_disable?:
drivers/regulator/s5m8767.c:259:2: warning: large integer implicitly truncated to unsigned type [-Woverflow]
drivers/regulator/s5m8767.c:253:6: warning: unused variable ?mask? [-Wunused-variable]

I plan to remove the sec_reg_*() helpers because they are confusing
and error-prone (mixing u8 and unsigned int). After using standard regmap
API this "mask" variable could be removed.

Best regards,
Krzysztof

  reply	other threads:[~2013-12-10  9:30 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-10  9:09 [TRIVIAL PATCH 1/2] regulator: s5m8767: Define symbol for buck control mask Krzysztof Kozlowski
2013-12-10  9:09 ` [PATCH 2/2] regulator: s5m8767: Fix driver probe fail on BUCK7/8 regulators Krzysztof Kozlowski
2013-12-11 22:51   ` Mark Brown
2013-12-10  9:18 ` [TRIVIAL PATCH 1/2] regulator: s5m8767: Define symbol for buck control mask Sachin Kamat
2013-12-10  9:30   ` Krzysztof Kozlowski [this message]
2013-12-10  9:38     ` Sachin Kamat
2013-12-10  9:56 ` Lee Jones

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=1386667806.4008.2.camel@AMDC1943 \
    --to=k.kozlowski@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.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