For platform with auto restart support, when doing i2c multi transfer
in high speed, for example, doing write-then-read transfer, the master
code will occupy the first transfer, and the second transfer will be
the read transfer, the write transfer will be discarded. So we should
first send the
This series contain two patches, first is to optimize Mediatek I2C driver to
use WRRD
if hardware support auto restart. Because auto restart will issue auto restart
interrupt, change to use WRRD can reduce interrupt latency. The second is to fix
multi transfer error in high speed mode. If
For platform with auto restart support, between every transfer,
i2c controller will trigger an interrupt and SW need to handle
it to start new transfer. When doing write-then-read transfer,
instead of restart mechanism, using WRRD mode to have controller
send both transfer in one request to reduce
Move the macro definitions above the struct definitions and add some
tabs for better readability.
Signed-off-by: Bartosz Golaszewski
---
drivers/misc/eeprom/at24.c | 16
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git
The at24cs series EEPROM chips have an additional read-only memory area,
that is visible on a different i2c slave address. Tie it up with a dummy
device.
Signed-off-by: Bartosz Golaszewski
---
drivers/misc/eeprom/at24.c | 30 ++
1 file
The at24 driver is now capable of reading the serial number from at24cs
EEPROM chips. Export the serial number through sysfs.
Signed-off-by: Bartosz Golaszewski
---
drivers/misc/eeprom/at24.c | 44
1 file changed, 40
Chips from the at24cs EEPROM series have an additional read-only memory area
containing a factory pre-programmed serial number. In order to access it, a
dummy write must be executed before reading the serial number bytes.
This series adds support for reading the serial number through a sysfs
In preparation for supporting the at24cs EEPROM series add a new flag to
platform data. When set, it should tell the driver that the chip has an
additional read-only memory area that holds a factory pre-programmed serial
number.
Signed-off-by: Bartosz Golaszewski
---
The at24cs series EEPROM chips have an additional read-only memory area
containing a factory pre-programmed serial number. In order to access
it, one has to perform a dummy write before reading the serial number
bytes.
Add a function that allows to access the serial number.
Signed-off-by:
The infrastructure for reading of the factory-programmed serial number
for at24cs EEPROM series is now in place. Add the chips that are actually
equipped with the serial number memory area to the list of supported
devices.
Signed-off-by: Bartosz Golaszewski
---
Use BIT() macro to replace the 0xXX constants in platform_data flags
definitions.
Signed-off-by: Bartosz Golaszewski
---
include/linux/platform_data/at24.h | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/include/linux/platform_data/at24.h
Improve the readability of the device table by separating columns with
tabs.
Signed-off-by: Bartosz Golaszewski
---
drivers/misc/eeprom/at24.c | 28 ++--
1 file changed, 14 insertions(+), 14 deletions(-)
diff --git a/drivers/misc/eeprom/at24.c
It seems as if the second check for I2C_FUNC_I2C functionality had been
introduced accidentally during a merge. Tt's reduntant, so remove it.
Signed-off-by: Bartosz Golaszewski
---
drivers/misc/eeprom/at24.c | 3 ---
1 file changed, 3 deletions(-)
diff --git
Added I2C_AQ_NO_CLK_STRETCH, to be used when clock stretching is not
supported.
Signed-off-by: Nicola Corna
---
include/linux/i2c.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/include/linux/i2c.h b/include/linux/i2c.h
index 768063b..9697002 100644
---
October 20 2015 5:35 PM, "Wolfram Sang" wrote:
> On Wed, Sep 16, 2015 at 03:32:01PM +0200, Nicola Corna wrote:
>
>> Added I2C_FUNC_NO_CLK_STRETCH, to be used when clock stretching is not
>> supported.
>>
>> Signed-off-by: Nicola Corna
>
> I think this
As reported here
http://www.advamation.com/knowhow/raspberrypi/rpi-i2c-bug.html
the BCM2835 has a bug in its i2c implementation which prevents a correct
clock stretching.
Signed-off-by: Nicola Corna
---
drivers/i2c/busses/i2c-bcm2835.c | 5 +
1 file changed, 5
The Si7013/20/21 modules support 2 read modes:
* Hold mode (blocking), where the device stretches the clock until the end
of the measurement
* No Hold mode (non-blocking), where the device replies NACK for every I2C
call during the measurement
Here the No Hold mode is implemented, selectable
Added I2C_AQ_NO_CLK_STRETCH to drivers/i2c/algos/i2c-algo-bit.c when
getscl is not available.
Signed-off-by: Nicola Corna
---
drivers/i2c/algos/i2c-algo-bit.c | 6 ++
1 file changed, 6 insertions(+)
diff --git a/drivers/i2c/algos/i2c-algo-bit.c
Not a complete review, I just stumbled over this one:
> + if (client->adapter->quirks &&
> +client->adapter->quirks->flags |
'|' should be '&', or?
> +I2C_AQ_NO_CLK_STRETCH)
> + return -ENODEV;
19 matches
Mail list logo