linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Haojian Zhuang <haojian.zhuang@gmail.com>
To: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: Haojian Zhuang <haojian.zhuang@marvell.com>,
	sameo@linux.intel.com, linux-kernel@vger.kernel.org,
	dmitry.torokhov@gmail.com, a.zummo@towertech.it,
	johnpol@2ka.mipt.ru, cbou@mail.ru, dwmw2@infradead.org,
	lrg@slimlogic.co.uk
Subject: Re: [PATCH 13/14] regulator: check name in initialization of max8925
Date: Mon, 18 Apr 2011 23:33:34 +0800	[thread overview]
Message-ID: <BANLkTim1QHe-hpyt0yQxKt2SBwtOAPQ3Bg@mail.gmail.com> (raw)
In-Reply-To: <20110418142855.GE2466@opensource.wolfsonmicro.com>

On Mon, Apr 18, 2011 at 10:28 PM, Mark Brown
<broonie@opensource.wolfsonmicro.com> wrote:
> On Mon, Apr 18, 2011 at 10:04:10PM +0800, Haojian Zhuang wrote:
>> Check name in initialization of max8925 regulator driver.
>
> What name are we checking and why do we need to check it?  I've no idea
> what the patch is supposed to do which makes it hard to review.
>
Actually, I didn't submit any platform driver before. So I can't
attach the related patch on
platform driver. After 2.6.39, I'll upload patches on platform driver.

In this original design, regulator data is assigned in platform driver
separately with index.
If I missed to define regulator[0] in platform data, the regulator
driver will meet failure
because of checking in max8925-core.c. The regulator[0] always means Buck0.

So I want to avoid to use the index and check regulator[] one by one.
I use a pointer to link
all regulator data together. I just need to check whether the
regulator pointer is valid or not.

>> +++ b/drivers/regulator/max8925-regulator.c
>> @@ -174,7 +174,7 @@ static struct regulator_ops max8925_regulator_ldo_ops = {
>>  #define MAX8925_SDV(_id, min, max, step)                     \
>>  {                                                            \
>>       .desc   = {                                             \
>> -             .name   = "SDV" #_id,                           \
>> +             .name   = "SD" #_id,                            \
>
> The above isn't obviously correct - it changes the name that's assigned
> from matching the macro used to something different.
>

The name isn't used by others. So I change it to SDx in order to
compare regulator name.

  reply	other threads:[~2011-04-18 15:33 UTC|newest]

Thread overview: 52+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <2011041801>
2011-04-18 14:03 ` [PATCH v2 00/14] Update 88pm860x and max8925 MFD driver Haojian Zhuang
2011-04-18 14:03 ` [PATCH 01/14] input: touchscreen: use polling mode in 88pm860x Haojian Zhuang
2011-04-18 14:03 ` [PATCH 02/14] input: touchscreen: move initialization " Haojian Zhuang
2011-04-26  8:57   ` Samuel Ortiz
2011-04-18 14:04 ` [PATCH 03/14] rtc: add 88pm860x rtc Haojian Zhuang
2011-04-26  8:58   ` Samuel Ortiz
2011-04-18 14:04 ` [PATCH 04/14] input: set the long press detection in 88pm860x onkey Haojian Zhuang
2011-04-18 14:04 ` [PATCH 05/14] w1: add DS278x slave driver Haojian Zhuang
2011-04-18 14:04 ` [PATCH 06/14] mfd: pxa-w1: MFD driver for PXA 1wire control + DS1WM chip Haojian Zhuang
2011-04-26  9:48   ` Samuel Ortiz
2011-05-14 14:21     ` Haojian Zhuang
2011-05-14 19:40       ` Russell King - ARM Linux
2011-05-14 22:23         ` Mark Brown
2011-05-22 20:00       ` Samuel Ortiz
2011-04-18 14:04 ` [PATCH 07/14] mfd: fix build warning on 88pm860x Haojian Zhuang
2011-04-26  9:49   ` Samuel Ortiz
2011-04-26 16:44     ` Haojian Zhuang
2011-04-26 16:47       ` Samuel Ortiz
2011-04-18 14:04 ` [PATCH 08/14] mfd: use platform_data in max8925 Haojian Zhuang
2011-04-20 11:54   ` Haojian Zhuang
2011-04-26  9:45     ` Samuel Ortiz
2011-04-18 14:04 ` [PATCH 09/14] input: get irq from resource in max8925 onkey Haojian Zhuang
2011-04-18 14:04 ` [PATCH 10/14] rtc: avoid to use hardcoding irq number in max8925 Haojian Zhuang
2011-04-18 14:04 ` [PATCH 11/14] power_supply: max8925: use platform_data from cell Haojian Zhuang
2011-04-18 21:49   ` Anton Vorontsov
2011-05-02 15:15     ` Samuel Ortiz
2011-04-18 14:04 ` [PATCH 12/14] regulator: max8925: enable i2c sequence for control Haojian Zhuang
2011-04-18 14:27   ` Mark Brown
2011-05-02 15:16   ` Samuel Ortiz
2011-04-18 14:04 ` [PATCH 13/14] regulator: check name in initialization of max8925 Haojian Zhuang
2011-04-18 14:28   ` Mark Brown
2011-04-18 15:33     ` Haojian Zhuang [this message]
2011-04-18 16:04       ` Mark Brown
2011-04-19  2:42         ` Haojian Zhuang
2011-04-19  8:09           ` Mark Brown
2011-04-19  8:28             ` Haojian Zhuang
2011-04-19 10:51               ` Mark Brown
2011-04-19 11:33                 ` Haojian Zhuang
2011-04-20 11:55   ` [PATCH 13/14] regulator: max8925: fix not add device if missing init data Haojian Zhuang
2011-04-21 10:42     ` Mark Brown
2011-04-21 11:13       ` Haojian Zhuang
2011-04-21 12:03         ` Mark Brown
2011-04-21 15:23           ` Haojian Zhuang
2011-04-21 18:32             ` Mark Brown
2011-04-18 14:04 ` [PATCH 14/14] regulator: 88pm8607: avoid to use constraint name in driver Haojian Zhuang
2011-04-18 14:30   ` Mark Brown
2011-04-18 15:38     ` Haojian Zhuang
2011-04-18 16:02       ` Mark Brown
2011-04-19  2:45         ` Haojian Zhuang
2011-04-19  8:13           ` Mark Brown
2011-04-19 11:34             ` Haojian Zhuang
2011-04-20 11:56   ` Haojian Zhuang

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=BANLkTim1QHe-hpyt0yQxKt2SBwtOAPQ3Bg@mail.gmail.com \
    --to=haojian.zhuang@gmail.com \
    --cc=a.zummo@towertech.it \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=cbou@mail.ru \
    --cc=dmitry.torokhov@gmail.com \
    --cc=dwmw2@infradead.org \
    --cc=haojian.zhuang@marvell.com \
    --cc=johnpol@2ka.mipt.ru \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lrg@slimlogic.co.uk \
    --cc=sameo@linux.intel.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;
as well as URLs for NNTP newsgroup(s).