From: sameo@linux.intel.com (Samuel Ortiz)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/4] mfd: update i2c driver for max8925
Date: Tue, 2 Feb 2010 16:15:55 +0100 [thread overview]
Message-ID: <20100202151554.GC28139@sortiz.org> (raw)
In-Reply-To: <771cded01002020622v7fa47689je2a5b1c11e2bb0c7@mail.gmail.com>
Hi Haojian,
On Tue, Feb 02, 2010 at 09:22:58AM -0500, Haojian Zhuang wrote:
> On Fri, Jan 29, 2010 at 2:54 PM, Samuel Ortiz <sameo@linux.intel.com> wrote:
> I wants to initialize max8925 after all three components probed. In
> core driver, irq handling needs to access all three components. In
> power supply driver, both adc and generic components are accessed.
> It's the reason that using three i2c clients in one driver.
Ok, that's what I understood. Adding appropriate comments to the code to
describe this would be really helpful.
> Yes, the code is not very clear. Now I use i2c_new_dummy() now. Now I
> attache new patches now.
>
> Updates are in below.
> 1. use i2c_new_dummy() to replace i2c_new_probed_device().
> 2. add onkey driver
> 3. remove unused i2c pointer in rtc driver
Very good, I just have one last comment:
> @@ -142,27 +138,28 @@ static int __devinit max8925_probe(struct i2c_client *client,
> const struct i2c_device_id *id)
> {
> struct max8925_platform_data *pdata = client->dev.platform_data;
> - struct max8925_chip *chip;
> + static struct max8925_chip *chip;
That no longer needs to be static.
The rest of the code looks fine to me. Once you remove that static
definition, and you add some comments explaining why you need those 3 i2c
pointers, I'll merge it.
Thanks for your work.
Cheers,
Samuel.
--
Intel Open Source Technology Centre
http://oss.intel.com/
next prev parent reply other threads:[~2010-02-02 15:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-25 11:07 [PATCH 1/4] mfd: update i2c driver for max8925 Haojian Zhuang
2010-01-29 19:54 ` Samuel Ortiz
2010-02-02 14:22 ` Haojian Zhuang
2010-02-02 15:15 ` Samuel Ortiz [this message]
2010-02-03 1:44 ` Haojian Zhuang
2010-02-05 9:06 ` Samuel Ortiz
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=20100202151554.GC28139@sortiz.org \
--to=sameo@linux.intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.