- Sep 09, 2007
-
-
David Brownell authored
This fixes a bug in the way i2c-algo-bit handles I2C_M_RECV_LEN, used to implement i2c_smbus_read_block_data(). Previously, in the absence of PEC (rarely used!) it would NAK the "length" byte: S addr Rd [A] [length] NA That prevents the subsequent data bytes from being read: S addr Rd [A] [length] { A [data] }* NA The primary fix just reorders two code blocks, so the length used in the "should I NAK now?" check incorporates the data which it just read from the slave device. However, that move also highlighted other fault handling glitches. This fixes those by abstracting the RX path ack/nak logic, so it can be used in more than one location. Also, a few CodingStyle issues were also resolved. Signed-off-by:
David Brownell <dbrownell@users.sourceforge.net> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Jean Delvare authored
It turns out that platform_device.id is a "u32" so testing it for being nonnegative is useless when setting up an i2c adapte. Instead, do what the platform_bus code does and test it against the value "-1". Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
David Brownell authored
It turns out that platform_device.id is a "u32" so testing it for being nonnegative is useless when setting up an i2c bitbang device. Instead, do what the platform_bus code does and test it against the value "-1". Signed-off-by:
David Brownell <dbrownell@users.sourceforge.net> Acked-by:
Atsushi Nemoto <anemo@mba.ocn.ne.jp> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
- Aug 31, 2007
-
-
Shane Huang authored
We find that SB700 and SB800 use the same SMBus device ID as SB600, which is 0x4385, instead of the already submitted 0x4395. Besides removing the wrong SB700 device ID, add SB800 support to kernel, by renaming the PCI_DEVICE_ID_ATI_IXP600_SMBUS into PCI_DEVICE_ID_ATI_SBX00_SMBUS. Signed-off-by:
Shane Huang <shane.huang@amd.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Aug 14, 2007
-
-
Ben Dooks authored
Fixup the include files after the arch moves that where included in 2.6.23. Signed-off-by:
Ben Dooks <ben-linux@fluff.org> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
David Brownell authored
Fix Menelaus build error, and remove needless "#define DEBUG". Signed-off-by:
David Brownell <dbrownell@users.sourceforge.net> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Dale Farnsworth authored
Under certain conditions, the mv64xxx I2C bus can hang preventing further operation. To make the driver more robust, we now reset the I2C hardware and the driver state machine when such hangs are detected. Signed-off-by:
Dale Farnsworth <dale@farnsworth.org> Acked-by:
Mark A. Greer <mgreer@mvista.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Domen Puncer authored
Disabling module on stop doesn't work on some CPUs (ie. mpc8241, as reported by Guennadi Liakhovetski), so remove that. Disable I2C module on errors/interrupts to prevent it from locking up on mpc5200b. Signed-off-by:
Domen Puncer <domen.puncer@telargo.com> Acked-by:
Guennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Arnaud Patard authored
In order to be able to use sensors on the IOP3xx SoCs, one needs to set the adapter class to I2C_CLASS_HWMON. Signed-off-by:
Arnaud Patard <arnaud.patard@rtp-net.org> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
David Brownell authored
Build fixes for isp1301_omap driver. I think an earlier version of this must have gotten lost somewhere, or maybe it only went into the Linux-OMAP tree. Also, some whitespace fixes to bring this more into sync with the version of this found in the Linux-OMAP tree. (That version has updates for the OTG controller on the OMAP 1710 which break that functionality on OMAP 161x boards like the H2, so merging all of it is not currently an option.) Signed-off-by:
David Brownell <dbrownell@users.sourceforge.net> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Scott Wood authored
Signed-off-by:
Scott Wood <scottwood@freescale.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Jean Delvare authored
Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
- Jul 29, 2007
-
-
Rafael J. Wysocki authored
Replace CONFIG_SOFTWARE_SUSPEND with CONFIG_HIBERNATION to avoid confusion (among other things, with CONFIG_SUSPEND introduced in the next patch). Signed-off-by:
Rafael J. Wysocki <rjw@sisk.pl> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jul 26, 2007
-
-
Andrew Morton authored
ia64: drivers/i2c/chips/ds1682.c: In function `ds1682_show': drivers/i2c/chips/ds1682.c:78: warning: long long unsigned int format, long unsigned int arg (arg 3) drivers/i2c/chips/ds1682.c:78: warning: long long unsigned int format, long unsigned int arg (arg 3) Cc: Jean Delvare <khali@linux-fr.org> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jul 25, 2007
-
-
Bryan Wu authored
Signed-off-by:
Bryan Wu <bryan.wu@analog.com>
-
- Jul 19, 2007
-
-
Jean Delvare authored
There are no users of i2c-isa left, so we can finally get rid of it. Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
- Jul 17, 2007
-
-
Tony Lindgren authored
Add Texas Instruments TWL92330/Menelaus Power Management chip driver. This includes voltage regulators, Dual slot memory card tranceivers and real-time clock(RTC). The support for RTC is integrated with this driver only; it is not separate module. Passes 'rtctest' on OMAP H4 EVM, other than lack of "periodic" (1/N second) IRQs. System wakeup alarms (from suspend-to-RAM) work too. The battery keeps the RTC active over power off, so once you set clock (rdate/ntpdate/etc, then "hwclock -w") then RTC_HCTOSYS at boot time will behave as expected. Cc: "Jean Delvare" <khali@linux-fr.org> Cc: "Tony Lindgren" <tony@atomide.com> Cc: "David Brownell" <david-b@pacbell.net> Signed-off-by:
Trilok Soni <soni.trilok@gmail.com> Acked-by:
Alessandro Zummo <alessandro.zummo@towertech.it> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
Yoann Padioleau authored
Signed-off-by:
Yoann Padioleau <padator@wanadoo.fr> Cc: Jean Delvare <khali@linux-fr.org> Signed-off-by:
Andrew Morton <akpm@linux-foundation.org> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jul 15, 2007
-
-
Al Viro authored
It depends on tristate I2C and it's trivial to make modular. The current Kconfig allows I2C=m, I2C_ACORN=y, which doesn't work at all; alternatives are dependency on I2C=y and making I2C_ACORN itself a tristate. The latter is the right thing to do... Signed-off-by:
Al Viro <viro@zeniv.linux.org.uk> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org> Acked-by:
Russell King <rmk+kernel@arm.linux.org.uk>
-
Al Viro authored
Fallout from commit 91a69029 ('sysfs: add parameter "struct bin_attribute *" ...') Signed-off-by:
Al Viro <viro@zeniv.linux.org.uk> Signed-off-by:
Linus Torvalds <torvalds@linux-foundation.org>
-
- Jul 12, 2007
-
-
Jean Delvare authored
This driver has been broken forever. It depends on i2c-algo-8xx which has never been in the mainline kernel. Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Domen Puncer authored
Work around a problem reported on: http://ozlabs.org/pipermail/linuxppc-embedded/2005-July/019038.html Without this patch I2C on mpc5200 becomes unusable after a while. Tested on mpc5200 boards by Matthias Fechner and me. Signed-off-by:
Domen Puncer <domen.puncer@telargo.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Marc St-Jean authored
Add TWI driver for the PMC-Sierra MSP71xx devices. [JD: Drop the probe hack, don't set algo_data as we never use it, return the right error code if the driver registration fails.] Signed-off-by:
Marc St-Jean <Marc_St-Jean@pmc-sierra.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Jean Delvare authored
Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Jean Delvare authored
There's some redundancy in the tsl2550 initialization sequence. It is powering up the device twice, and setting the operating mode twice too. Setting things just once saves SMBus transactions, which aren't always cheap, speeding up the device initialization. Signed-off-by:
Jean Delvare <khali@linux-fr.org> Cc: Rodolfo Giometti <giometti@linux.it>
-
Jean Delvare authored
This is a new I2C bus driver for the TAOS evaluation modules. Developped and tested on the TAOS TSL2550 EVM. Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Oleg Ryjkov authored
Add an ability to utilize the internal SRAM buffer on ICH4 and newer host controllers to speed up execution of block operations. I've split the code so that it is more clear which block transaction is performed. First of all the host controller's type is identified. isich4 is set when we think that the controller has the internal buffer. Then, before every block transaction, if isich4 is set, we attempt to enable the E32B bit in SMBAUXCTL register. Signed-off-by:
Oleg Ryjkov <olegr@google.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Oleg Ryjkov authored
* Use defines instead of raw numbers for register bits * Fix several wrong indentations and trailing whitespace * Move hwpec timeout checking to a separate function Signed-off-by:
Oleg Ryjkov <olegr@google.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Rodolfo Giometti authored
Add support for Taos TSL2550 ambient light sensors. (http://www.taosinc.com/product_detail.asp?cateid=4&proid=18 ). Signed-off-by:
Rodolfo Giometti <giometti@linux.it> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Rodolfo Giometti authored
Signed-off-by:
Rodolfo Giometti <giometti@linux.it> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Atsushi Nemoto authored
i2c_gpio_getsda() and i2c_gpio_getscl() are only used in this file. Signed-off-by:
Atsushi Nemoto <anemo@mba.ocn.ne.jp> Acked-by:
Haavard Skinnemoen <hskinnemoen@atmel.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Atsushi Nemoto authored
Use i2c_bit_add_numbered_bus() so that the i2c-gpio adapter works well with new-style pre-declared devices. Signed-off-by:
Atsushi Nemoto <anemo@mba.ocn.ne.jp> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Martin Michlmayr authored
Update the IOP3xx I2C driver to use i2c_add_numbered_adapter(), so that later patches can convert boards to using new-style drivers. Signed-off-by:
Martin Michlmayr <tbm@cyrius.com> Tested-by:
Voipio Riku <Riku.Voipio@movial.fi> Cc: Dan J Williams <dan.j.williams@intel.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Jean Delvare authored
Let the i2c-sis5595 driver release its PCI device after registering. This is to allow the sis5595 hardware monitoring driver to also access this PCI device. The same trick is already used in the i2c-viapro and via686a drivers to let them both load. Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Oleg Ryjkov authored
Add support for SMBus block read/write transactions to i2c-nforce2 driver, in particular to host controllers MCP51 and MCP55. Signed-off-by:
Oleg Ryjkov <olegr@google.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Grant Likely authored
Move the i2c-mpc driver over to using the new i2c infrastructure. Specifically, it now uses i2c_add_numbered_adapter so that the bus number can be determined ahead of time and used to register i2c clients before the bus is instantiated. Tested on an MPC5200 based board Signed-off-by:
Grant Likely <grant.likely@secretlab.ca> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Dale Farnsworth authored
Convert the Marvell mv64xxx I2C driver to use the new i2c infrastructure, by calling i2c_add_numbered_adapter(). This allows clients to be registered before the bus is instantiated. Signed-off-by:
Dale Farnsworth <dale@farnsworth.org> Acked-by:
Mark A. Greer <mgreer@mvista.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Henry Su authored
Add the SMBus device ID for ATI SB700. Signed-off-by:
Henry Su <Henry.su@amd.com> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Grant Likely authored
A driver for the Dallas DS1682 elapsed time recorder chip. Tested on a MPC5200 based board using the integrated i2c adapter. Signed-off-by:
Grant Likely <grant.likely@secretlab.ca> Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-
Jean Delvare authored
Let the drivers specify how many bytes they want to read with i2c_smbus_read_i2c_block_data(). So far, the block count was hard-coded to I2C_SMBUS_BLOCK_MAX (32), which did not make much sense. Many driver authors complained about this before, and I believe it's about time to fix it. Right now, authors have to do technically stupid things, such as individual byte reads or full-fledged I2C messaging, to work around the problem. We do not want to encourage that. I even found that some bus drivers (e.g. i2c-amd8111) already implemented I2C block read the "right" way, that is, they didn't follow the old, broken standard. The fact that it was never noticed before just shows how little i2c_smbus_read_i2c_block_data() was used, which isn't that surprising given how broken its prototype was so far. There are some obvious compatiblity considerations: * This changes the i2c_smbus_read_i2c_block_data() prototype. Users outside the kernel tree will notice at compilation time, and will have to update their code. * User-space has access to i2c_smbus_xfer() directly using i2c-dev, so the changed expectations would affect tools such as i2cdump. In order to preserve binary compatibility, we give I2C_SMBUS_I2C_BLOCK_DATA a new numeric value, and define I2C_SMBUS_I2C_BLOCK_BROKEN with the old numeric value. When i2c-dev receives a transaction with the old value, it can convert it to the new format on the fly. Signed-off-by:
Jean Delvare <khali@linux-fr.org>
-