From: Heiko Schocher <hs@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 03/12] 83xx, kmeter1: add I2C, dtt, eeprom support
Date: Wed, 18 Feb 2009 09:14:05 +0100 [thread overview]
Message-ID: <499BC34D.5010004@denx.de> (raw)
In-Reply-To: <20090217192233.03b27dd7.kim.phillips@freescale.com>
Hello Kim
Kim Phillips wrote:
> On Tue, 17 Feb 2009 07:03:23 +0100
> Heiko Schocher <hs@denx.de> wrote:
>
>> Hello Kim,
>
> Hello Heiko,
>
>> Kim Phillips wrote:
>>> On Wed, 11 Feb 2009 19:25:49 +0100
>>> Heiko Schocher <hs@denx.de> wrote:
>>>> /* switch to correct I2C bus */
>>>> old_bus = I2C_GET_BUS();
>>>> - I2C_SET_BUS(CONFIG_SYS_DTT_BUS_NUM);
>>>> + if ((gd->flags & GD_FLG_RELOC) != GD_FLG_RELOC) {
>>>> + uchar *tmp = (uchar *)getenv("dtt_bus");
>>> sorry Heiko, I should have asked you before: this is a hardcoded
>>> environment variable in driver code, does the dtt bus value change
>>> between boots? If not, what's the reason the value isn't specified as
>>> a CONFIG_SYS_DTT_BUS_NUM?
>> It changes not between boots, but between different hardware.
>
> so why not make it a CONFIG_SYS_DTT_BUS_NUM instead of permanently
> polluting environment namespace. That's what the rest of the boards
> that use this DTT code do; what makes the kmeter1 special in this
> regard? Because CONFIG_SYS_DTT_BUS_NUM is not just a single number?
There are several hardwareversions, which only differ in the way, how
the DTTs are reached (0,1,2 muxes and they use also different channels
...). So we save this "way" in an environment variable. When running
in RAM, it is just a number see else part ...
> In that case we can make CONFIG_SYS_DTT_BUS_REF or something (not sure
> if that's a good enough name).
What exactly do you mean with that?
But I was wondering why the DTTs are initialized so early. Is this
necessary? If not, I don;t need this ...
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:[~2009-02-18 8:14 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-11 18:25 [U-Boot] [PATCH 03/12] 83xx, kmeter1: add I2C, dtt, eeprom support Heiko Schocher
2009-02-17 1:36 ` Kim Phillips
2009-02-17 6:03 ` Heiko Schocher
2009-02-18 1:22 ` Kim Phillips
2009-02-18 8:14 ` Heiko Schocher [this message]
2009-02-19 0:55 ` Kim Phillips
2009-02-19 8:10 ` 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=499BC34D.5010004@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