From: Mike Frysinger <vapier@gentoo.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/3] i2c: add i2c_core and prepare for new multibus support
Date: Wed, 18 Jan 2012 15:41:41 -0500 [thread overview]
Message-ID: <201201181541.42710.vapier@gentoo.org> (raw)
In-Reply-To: <CAOZdJXV2kgZMZ5C_cOo99j1es_J6Q=ipz40hcLJSEpjwnmpvOw@mail.gmail.com>
On Wednesday 18 January 2012 15:11:56 Tabi Timur-B04825 wrote:
> On Tue, Jan 17, 2012 at 1:12 AM, Simon Glass wrote:
> > --- a/arch/arm/include/asm/global_data.h
> > +++ b/arch/arm/include/asm/global_data.h
> > @@ -87,6 +87,9 @@ typedef struct global_data {
> > unsigned long post_log_res; /* success of POST test */
> > unsigned long post_init_f_time; /* When post_init_f started */
> > #endif
> > +#if defined(CONFIG_SYS_I2C)
> > + void *cur_adap; /* current used i2c adapter */
> > +#endif
>
> I was really hoping we could get rid of the concept of a "current" i2c
> adapter, and just force all drivers to specify the I2C adapter they
> want to use for a given I2C operation. That's how Linux operates, and
> it will prevent stuff like this:
>
> void *old;
> void *new;
>
> old = get_current_i2c_adapter();
> set_i2c_adapter(new);
> // do I2C stuff
> set_i2c_adapter(old);
that's only needed if you expect the pointer to stay valid across calls. i
don't think it does for most (all?) drivers.
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20120118/75ccaa78/attachment.pgp>
next prev parent reply other threads:[~2012-01-18 20:41 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-17 7:12 [U-Boot] [PATCH 0/3] Bring in new I2C framework Simon Glass
2012-01-17 7:12 ` [U-Boot] [PATCH 1/3] i2c: add i2c_core and prepare for new multibus support Simon Glass
2012-01-17 19:23 ` Mike Frysinger
2012-01-18 20:11 ` Tabi Timur-B04825
2012-01-18 20:41 ` Mike Frysinger [this message]
2012-01-18 20:43 ` Timur Tabi
2012-01-18 21:37 ` Simon Glass
2012-01-18 21:39 ` Timur Tabi
2012-01-18 22:21 ` Simon Glass
2012-01-18 22:24 ` Timur Tabi
2012-01-19 5:36 ` Wolfgang Denk
2012-01-19 6:35 ` Heiko Schocher
2012-01-19 6:53 ` Simon Glass
2012-01-19 7:53 ` Heiko Schocher
2012-01-19 18:07 ` Simon Glass
2012-01-19 11:20 ` Wolfgang Denk
2012-01-19 18:10 ` Simon Glass
2012-01-19 18:47 ` Timur Tabi
2012-01-20 6:50 ` Heiko Schocher
2012-01-17 7:12 ` [U-Boot] [PATCH 2/3] i2c: common changes for multibus/multiadapter support Simon Glass
2012-01-17 7:12 ` [U-Boot] [PATCH 3/3] WIP: tegra: i2c: Enable new I2C framework Simon Glass
2012-01-17 8:51 ` Heiko Schocher
2012-01-17 8:30 ` [U-Boot] [PATCH 0/3] Bring in " Heiko Schocher
-- strict thread matches above, loose matches on Subject: below --
2012-10-22 17:40 Heiko Schocher
2012-10-22 17:40 ` [U-Boot] [PATCH 1/3] i2c: add i2c_core and prepare for new multibus support Heiko Schocher
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=201201181541.42710.vapier@gentoo.org \
--to=vapier@gentoo.org \
--cc=u-boot@lists.denx.de \
/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.