All of lore.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: khali@linux-fr.org
Cc: Greg KH <greg@kroah.com>,
	Linux Kernel list <linux-kernel@vger.kernel.org>
Subject: i2c/ smbus question
Date: Sun, 08 Jan 2006 09:36:03 +1100	[thread overview]
Message-ID: <1136673364.30123.20.camel@localhost.localdomain> (raw)

Hi !

Can you confirm the difference between writing a block of data with
I2C_SMBUS_BLOCK_DATA vs I2C_SMBUS_I2C_BLOCK_DATA on the wire ? It's my
understanding that the former will actually send the lenght byte on the
wire before the data while the later won't, though they both send a
subaddress.

I'm completely rewriting the powermac i2c support (consolidating all
busses behind a low level layer that I need to use in circumstances
where the linux i2c layer isn't useable, and with a single driver in
drivers/i2c/busses/* replacing i2c-keywest.c and i2c-pmac-smu.c) and I
think I'm hitting a problem where i2c-keywest didn't implement
I2C_SMBUS_BLOCK_DATA properly (didn't send the lenght byte) and some
drivers (our sound drivers) rely on that behaviour (that's fine, I can
fix them too, I just want to make sure I understand what the semantic
should be).

I'm a bit surprised that there seem to be no wrapper for writing with
I2C_SMBUS_I2C_BLOCK_DATA, only for reading, in i2c-core.c since it
appears to me that it's the most common one, at least for all devices
I've dealt with so far (mostly sound & clock chips in addition to
sensors)...

Cheers,
Ben.



             reply	other threads:[~2006-01-07 22:38 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-01-07 22:36 Benjamin Herrenschmidt [this message]
2006-01-08 10:30 ` i2c/ smbus question Jean Delvare
2006-01-08 21:10   ` Benjamin Herrenschmidt
2006-01-08 22:58   ` Benjamin Herrenschmidt
2006-01-09  3:53     ` Greg KH
2006-01-09  4:19       ` Benjamin Herrenschmidt

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=1136673364.30123.20.camel@localhost.localdomain \
    --to=benh@kernel.crashing.org \
    --cc=greg@kroah.com \
    --cc=khali@linux-fr.org \
    --cc=linux-kernel@vger.kernel.org \
    /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.