Skip to content

Commit

Permalink
Merge branch 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/…
Browse files Browse the repository at this point in the history
…kernel/git/wsa/linux

Pull i2c fixes from Wolfram Sang:
 "A few bugfixes and one PCI ID addition from I2C"

* 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
  i2c: i801: add Intel Lewisburg device IDs
  i2c: fix wakeup irq parsing
  i2c: xiic: Prevent concurrent running of the IRQ handler and __xiic_start_xfer()
  i2c: Revert "i2c: xiic: Do not reset controller before every transfer"
  i2c: imx: fix a compiling error
  • Loading branch information
Linus Torvalds committed Nov 20, 2015
2 parents 116dfe5 + cdc5a31 commit 81051f9
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 2 deletions.
1 change: 1 addition & 0 deletions Documentation/i2c/busses/i2c-i801
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ Supported adapters:
* Intel Sunrise Point-LP (PCH)
* Intel DNV (SOC)
* Intel Broxton (SOC)
* Intel Lewisburg (PCH)
Datasheets: Publicly available at the Intel website

On Intel Patsburg and later chipsets, both the normal host SMBus controller
Expand Down
1 change: 1 addition & 0 deletions drivers/i2c/busses/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ config I2C_I801
Sunrise Point-LP (PCH)
DNV (SOC)
Broxton (SOC)
Lewisburg (PCH)

This driver can also be built as a module. If so, the module
will be called i2c-i801.
Expand Down
6 changes: 6 additions & 0 deletions drivers/i2c/busses/i2c-i801.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@
* Sunrise Point-LP (PCH) 0x9d23 32 hard yes yes yes
* DNV (SOC) 0x19df 32 hard yes yes yes
* Broxton (SOC) 0x5ad4 32 hard yes yes yes
* Lewisburg (PCH) 0xa1a3 32 hard yes yes yes
* Lewisburg Supersku (PCH) 0xa223 32 hard yes yes yes
*
* Features supported by this driver:
* Software PEC no
Expand Down Expand Up @@ -206,6 +208,8 @@
#define PCI_DEVICE_ID_INTEL_SUNRISEPOINT_LP_SMBUS 0x9d23
#define PCI_DEVICE_ID_INTEL_DNV_SMBUS 0x19df
#define PCI_DEVICE_ID_INTEL_BROXTON_SMBUS 0x5ad4
#define PCI_DEVICE_ID_INTEL_LEWISBURG_SMBUS 0xa1a3
#define PCI_DEVICE_ID_INTEL_LEWISBURG_SSKU_SMBUS 0xa223

struct i801_mux_config {
char *gpio_chip;
Expand Down Expand Up @@ -869,6 +873,8 @@ static const struct pci_device_id i801_ids[] = {
{ PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_SUNRISEPOINT_LP_SMBUS) },
{ PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_DNV_SMBUS) },
{ PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_BROXTON_SMBUS) },
{ PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_LEWISBURG_SMBUS) },
{ PCI_DEVICE(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_LEWISBURG_SSKU_SMBUS) },
{ 0, }
};

Expand Down
1 change: 1 addition & 0 deletions drivers/i2c/busses/i2c-imx.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
#include <linux/of_device.h>
#include <linux/of_dma.h>
#include <linux/of_gpio.h>
#include <linux/pinctrl/consumer.h>
#include <linux/platform_data/i2c-imx.h>
#include <linux/platform_device.h>
#include <linux/sched.h>
Expand Down
4 changes: 3 additions & 1 deletion drivers/i2c/busses/i2c-xiic.c
Original file line number Diff line number Diff line change
Expand Up @@ -662,8 +662,10 @@ static void __xiic_start_xfer(struct xiic_i2c *i2c)

static void xiic_start_xfer(struct xiic_i2c *i2c)
{

spin_lock(&i2c->lock);
xiic_reinit(i2c);
__xiic_start_xfer(i2c);
spin_unlock(&i2c->lock);
}

static int xiic_xfer(struct i2c_adapter *adap, struct i2c_msg *msgs, int num)
Expand Down
2 changes: 1 addition & 1 deletion drivers/i2c/i2c-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -715,7 +715,7 @@ static int i2c_device_probe(struct device *dev)
if (wakeirq > 0 && wakeirq != client->irq)
status = dev_pm_set_dedicated_wake_irq(dev, wakeirq);
else if (client->irq > 0)
status = dev_pm_set_wake_irq(dev, wakeirq);
status = dev_pm_set_wake_irq(dev, client->irq);
else
status = 0;

Expand Down

0 comments on commit 81051f9

Please sign in to comment.