From: Heiko Schocher <hs@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 0/3] Bring in new I2C framework
Date: Tue, 17 Jan 2012 09:30:42 +0100 [thread overview]
Message-ID: <4F1531B2.8090302@denx.de> (raw)
In-Reply-To: <1326784345-19953-1-git-send-email-sjg@chromium.org>
Hello Simon,
Simon Glass wrote:
> This series provides Heiko's upgraded I2C framework from a few years ago.
> I hope that we can bring this in and move boards over to it as time
> permits, rather than switching everything in one fell swoop which never
> happens.
Ok, lets try it!
> To show it working I have enabled it for Tegra in a very rough way. It
> seems fine with my limited testing.
Great! Thanks! Patches for other i2c drivers can be found here:
http://git.denx.de/?p=u-boot/u-boot-i2c.git;a=shortlog;h=refs/heads/multibus_v2_20111112
They just need a rebase and an update to your changes (and of course
some tests)
> In terms of changes, I have just fixed some checkpatch errors and fiddled
> with a couple of function signatures.
>
> I will start a thread on the list with a few thoughts on this series
> at some point.
Ok, thanks. Here some thoughts comming in my mind:
- Why a "cur_adap" added in gd_t:
- This points allways to the current used i2c adapter.
- because gd_t is writeable when running in flash,
complete multiadapter/multibus functionality is
usable, when running in flash, which is needed for
some SoCs.
- using a pointer brings faster accesses to the i2c_adapter_t
struct and saves some bytes here and there.
- init from a i2c controller:
In current code all i2c controllers, as a precaution,
getting initialized. In the new code, a i2c controller
gets only initialized if it is used. This is done in
i2c_set_bus_num().
Also, with this approach, we can easy add in a second step,
a i2c_deinit() function, called from i2c_set_bus_num(),
so we can easy deactivate a no longer used controller.
- added "hw_adapnr" in i2c_adapter_t struct:
when for example a CPU has more then one i2c controller
we can use this variable to differentiate which
controller the actual i2c adapter uses.
- Maybe we should add a base_addr field in struct i2c_adapter?
This would help for SoCs, who have more then one identical
controller, just differ in their base_addr...
(Currently I made a function, or an array which returns
the base_addr, dependend on "hw_adapnr"). We should drop
this, and introduce a "base_addr" field.
[...]
bye,
Heiko
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
next prev parent reply other threads:[~2012-01-17 8:30 UTC|newest]
Thread overview: 42+ 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
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 ` Heiko Schocher [this message]
-- strict thread matches above, loose matches on Subject: below --
2012-10-22 17:40 [U-Boot] [PATCH 0/3] Bring in " Heiko Schocher
2012-10-25 21:37 ` Simon Glass
2012-10-26 5:48 ` Heiko Schocher
2012-10-26 16:07 ` Stephen Warren
2012-10-29 9:47 ` Heiko Schocher
2012-10-29 15:34 ` Stephen Warren
2012-10-29 15:56 ` Simon Glass
2012-10-30 5:57 ` Heiko Schocher
2012-10-30 16:50 ` Stephen Warren
2012-10-30 17:22 ` Simon Glass
2012-10-31 5:02 ` Heiko Schocher
2012-10-31 5:20 ` Tom Rini
2012-10-26 16:08 ` Simon Glass
2012-10-29 9:44 ` Heiko Schocher
2012-10-29 13:48 ` Simon Glass
2012-10-30 5:44 ` Heiko Schocher
2012-10-26 18:44 ` Tom Rini
2012-10-29 9:53 ` Heiko Schocher
2012-10-30 22:38 ` Tom Rini
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=4F1531B2.8090302@denx.de \
--to=hs@denx.de \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox