public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Nishanth Menon <menon.nishanth@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot-Users] [PATCH 1/2] Add support for multiple I2C buses
Date: Thu, 31 Aug 2006 22:45:20 -0500	[thread overview]
Message-ID: <44F7ACD0.6010508@gmail.com> (raw)
In-Reply-To: <1156973748.13685.26.camel@saruman.qstreams.net>

Ben Warren stated on 8/30/2006 4:35 PM:

> Overview:
<snip>
> be skipped by the 'i2c probe' command. 
Thanks Ben, this is finally in tune with Denx requirements I guess ;)
> ------------------------------------------------------------------------
> 
> diff --git a/README b/README
> index e772c1a..f674050 100644
> --- a/README
> +++ b/README
> @@ -1188,7 +1188,12 @@ The following options need to be configu
>  		clock chips. See common/cmd_i2c.c for a description of the
>  		command line interface.
>  
> -		CONFIG_HARD_I2C selects the CPM hardware driver for I2C.
> +		CONFIG_I2C_CMD_TREE is a recommended option that places
> +		all I2C commands under a single 'i2c' root command.  The 
> +		older 'imm', 'imd', 'iprobe' etc. commands are considered
> +		deprecated and may disappear in the future.
> +
> +		CONFIG_HARD_I2C selects a hardware I2C controller.
I guess I am slow abt this.... but !slow_i2c... is that not good enough?
and I cant see any other part in the the common patch using it...
> diff --git a/common/cmd_i2c.c b/common/cmd_i2c.c
> index c543bb5..824f7c7 100644
> --- a/common/cmd_i2c.c
> +++ b/common/cmd_i2c.c

> +int do_i2c_bus_speed(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])
> +{
> +	int speed, ret=0;
> +
> +	if (argc == 1)  /* querying current speed */
> +	{
> +		printf("Current bus speed=%d\n", i2c_get_bus_speed());
> +	}
> +	else
> +	{
> +		speed = simple_strtoul(argv[1], NULL, 10);
> +		printf("Setting bus speed to %d Hz\n", speed);
> +		ret = i2c_set_bus_speed(speed);
> +		if(ret)
> +		{
> +			printf("Failure changing bus speed (%d)\n", ret);
> +		}
> +	}
> +	return ret;
> +}
Err... Does this mean that all other folks who can only support a single
speed need to implement this api (including all other existing
drivers??)...... Lotsa people are not going to like this if that is so...


Looks good to me.. it should fit in OMAP2430 framework too :)

Some one gotta tell Denx  to update this:
http://sourceforge.net/cvs/?group_id=65938. i thought we moved to git
sometime back. Do we even look at cvs anymore??? :(

Regards,
Nishanth Menon

  reply	other threads:[~2006-09-01  3:45 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-08-30 21:35 [U-Boot-Users] [PATCH 1/2] Add support for multiple I2C buses Ben Warren
2006-09-01  3:45 ` Nishanth Menon [this message]
2006-09-01 19:42   ` Ben Warren
2006-09-01 21:03     ` Wolfgang Denk
2006-09-05 17:59       ` Tolunay Orkun
2006-09-01 23:42     ` nishanth menon
2006-09-02  3:18       ` Ben Warren
2006-09-02  5:21         ` Nishanth Menon
2006-09-07 20:50 ` Ben Warren

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=44F7ACD0.6010508@gmail.com \
    --to=menon.nishanth@gmail.com \
    --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