From: Heiko Schocher <hs@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/3] i2c: add i2c_core and prepare for new multibus support
Date: Fri, 20 Jan 2012 07:50:53 +0100 [thread overview]
Message-ID: <4F190ECD.6070007@denx.de> (raw)
In-Reply-To: <4F186554.5060904@freescale.com>
Hello Timur,
Timur Tabi wrote:
> Wolfgang Denk wrote:
>> As mentioned before, this is what we currently have as "device model"
>> in U-Boot - not only I2C: we have the same "current device" concept
>> with IDE, USB, ...
>
> The difference is that I2C operations are typically done internally by
> other code, whereas IDE, USB, etc are done by the user on the command
> line. It's not unusual for boot code to access multiple I2C devices on
> different buses, so we're switching I2C buses a lot. People generally
> don't try to access two networks or two USB devices back-to-back, but
> that's exactly what we do with I2C.
>
> The other problem is that I2C operations are necessary prior to
> relocation, but IDE, USB, etc generally are not. That's why we have this:
>
> static unsigned int i2c_bus_num __attribute__ ((section (".data"))) =
> CONFIG_SYS_SPD_BUS_NUM;
Yep, correct. For that case, I need the "trickery" with the "cur_i2c_adap"
pointer in gd_t in the "new" framework, as gd_t is writeable before
relocation ...
> We need to initialize i2c_bus_num to the I2C bus that SPD is on, because
> i2c_bus_num is not writable until after relocation, and DDR initialization
> requires I2C.
>
> A board that has SPD on two different I2C buses could not be supported by
> U-Boot today.
... and so with the "new" framework, it should be possible to switch to
other i2c busses (incl. i2c muxes on that), before relocation.
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-20 6:50 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
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 [this message]
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=4F190ECD.6070007@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 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.