]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
Merge branch 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa...
authorLinus Torvalds <torvalds@linux-foundation.org>
Fri, 29 Nov 2013 17:55:13 +0000 (09:55 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 29 Nov 2013 17:55:13 +0000 (09:55 -0800)
Pull i2c fixes from Wolfram Sang:
 "Some easy but needed fixes for i2c drivers since rc1"

* 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
  i2c: bcm2835: Linking platform nodes to adapter nodes
  i2c: omap: raw read and write endian fix
  i2c: i2c-bcm-kona: Fix module build
  i2c: i2c-diolan-u2c: different usb endpoints for DLN-2-U2C
  i2c: bcm-kona: remove duplicated include
  i2c: davinci: raw read and write endian fix

1  2 
drivers/i2c/busses/i2c-omap.c

index d76228d81d5f1d4acf82e933d9ed059a0aa85c16,a61cbcc9645a3abd0bb3cb547e3cc721a83801df..90dcc2eaac5fb688fedba904b181be2312e40b3d
@@@ -266,13 -266,13 +266,13 @@@ static const u8 reg_map_ip_v2[] = 
  static inline void omap_i2c_write_reg(struct omap_i2c_dev *i2c_dev,
                                      int reg, u16 val)
  {
-       __raw_writew(val, i2c_dev->base +
+       writew_relaxed(val, i2c_dev->base +
                        (i2c_dev->regs[reg] << i2c_dev->reg_shift));
  }
  
  static inline u16 omap_i2c_read_reg(struct omap_i2c_dev *i2c_dev, int reg)
  {
-       return __raw_readw(i2c_dev->base +
+       return readw_relaxed(i2c_dev->base +
                                (i2c_dev->regs[reg] << i2c_dev->reg_shift));
  }
  
@@@ -1037,20 -1037,6 +1037,20 @@@ static const struct i2c_algorithm omap_
  };
  
  #ifdef CONFIG_OF
 +static struct omap_i2c_bus_platform_data omap2420_pdata = {
 +      .rev = OMAP_I2C_IP_VERSION_1,
 +      .flags = OMAP_I2C_FLAG_NO_FIFO |
 +                      OMAP_I2C_FLAG_SIMPLE_CLOCK |
 +                      OMAP_I2C_FLAG_16BIT_DATA_REG |
 +                      OMAP_I2C_FLAG_BUS_SHIFT_2,
 +};
 +
 +static struct omap_i2c_bus_platform_data omap2430_pdata = {
 +      .rev = OMAP_I2C_IP_VERSION_1,
 +      .flags = OMAP_I2C_FLAG_BUS_SHIFT_2 |
 +                      OMAP_I2C_FLAG_FORCE_19200_INT_CLK,
 +};
 +
  static struct omap_i2c_bus_platform_data omap3_pdata = {
        .rev = OMAP_I2C_IP_VERSION_1,
        .flags = OMAP_I2C_FLAG_BUS_SHIFT_2,
@@@ -1069,14 -1055,6 +1069,14 @@@ static const struct of_device_id omap_i
                .compatible = "ti,omap3-i2c",
                .data = &omap3_pdata,
        },
 +      {
 +              .compatible = "ti,omap2430-i2c",
 +              .data = &omap2430_pdata,
 +      },
 +      {
 +              .compatible = "ti,omap2420-i2c",
 +              .data = &omap2420_pdata,
 +      },
        { },
  };
  MODULE_DEVICE_TABLE(of, omap_i2c_of_match);
@@@ -1162,9 -1140,9 +1162,9 @@@ omap_i2c_probe(struct platform_device *
         * Read the Rev hi bit-[15:14] ie scheme this is 1 indicates ver2.
         * On omap1/3/2 Offset 4 is IE Reg the bit [15:14] is 0 at reset.
         * Also since the omap_i2c_read_reg uses reg_map_ip_* a
-        * raw_readw is done.
+        * readw_relaxed is done.
         */
-       rev = __raw_readw(dev->base + 0x04);
+       rev = readw_relaxed(dev->base + 0x04);
  
        dev->scheme = OMAP_I2C_SCHEME(rev);
        switch (dev->scheme) {