<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git/include/linux/i2c.h, branch v4.19.32</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.19.32</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.19.32'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2018-08-30T21:13:15Z</updated>
<entry>
<title>i2c: refactor function to release a DMA safe buffer</title>
<updated>2018-08-30T21:13:15Z</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa+renesas@sang-engineering.com</email>
</author>
<published>2018-08-24T14:52:44Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=82fe39a6bc7b866fc3ffd838e3c5a4cadb328b04'/>
<id>urn:sha1:82fe39a6bc7b866fc3ffd838e3c5a4cadb328b04</id>
<content type='text'>
a) rename to 'put' instead of 'release' to match 'get' when obtaining
   the buffer
b) change the argument order to have the buffer as first argument
c) add a new argument telling the function if the message was
   transferred. This allows the function to be used also in cases
   where setting up DMA failed, so the buffer needs to be freed without
   syncing to the message buffer.

Also convert the only user.

Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Reviewed-by: Niklas Söderlund &lt;niklas.soderlund+renesas@ragnatech.se&gt;
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
<entry>
<title>i2c: remove deprecated attach_adapter callback</title>
<updated>2018-08-24T12:42:45Z</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa@the-dreams.de</email>
</author>
<published>2018-08-21T15:02:40Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=0c36dd37d5b80b43f4e3dc5a1dbfe6dbd86e8f2a'/>
<id>urn:sha1:0c36dd37d5b80b43f4e3dc5a1dbfe6dbd86e8f2a</id>
<content type='text'>
There aren't any users left. Remove this callback from the 2.4 times.
Phew, finally, that took years to reach...

Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
<entry>
<title>i2c: core: Parse SDA hold time from firmware</title>
<updated>2018-08-08T20:28:52Z</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2018-07-25T14:39:25Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=4717be73c2843a3d6d8546872177a19358f6b7b5'/>
<id>urn:sha1:4717be73c2843a3d6d8546872177a19358f6b7b5</id>
<content type='text'>
There are two drivers already using the SDA hold time setting.
It might be more in the future, thus, make I2C core to parse the setting
for us if provided by firmware.

Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Tested-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Reviewed-by: Alexandre Belloni &lt;alexandre.belloni@bootlin.com&gt;
Acked-by: Ludovic Desroches &lt;ludovic.desroches@microchip.com&gt;
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
<entry>
<title>i2c: quirks: add zero length checks</title>
<updated>2018-08-04T21:24:03Z</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa+renesas@sang-engineering.com</email>
</author>
<published>2018-07-23T20:26:05Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=d9cfe2ce246845b9cca0ec1b881e826965893c58'/>
<id>urn:sha1:d9cfe2ce246845b9cca0ec1b881e826965893c58</id>
<content type='text'>
Some adapters do not support a message length of 0. Add this as a quirk
so drivers don't have to open code it.

Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Reviewed-by: Niklas Söderlund &lt;niklas.soderlund+renesas@ragnatech.se&gt;
Reviewed-by: Andy Shevchenko &lt;andy.shevchenko@gmail.com&gt;
Tested-by: Jarkko Nikula &lt;jarkko.nikula@linux.intel.com&gt;
Acked-by: Jarkko Nikula &lt;jarkko.nikula@linux.intel.com&gt;
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
<entry>
<title>i2c: recovery: add get_bus_free callback</title>
<updated>2018-07-17T08:46:51Z</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa+renesas@sang-engineering.com</email>
</author>
<published>2018-07-10T22:24:22Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=7ca5f6be7900ca753ed01c0202dc5f998a41f4ee'/>
<id>urn:sha1:7ca5f6be7900ca753ed01c0202dc5f998a41f4ee</id>
<content type='text'>
Some IP cores have an internal 'bus free' logic which may be more
advanced than just checking if SDA is high. Add a separate callback to
get this status. Filling it is optional.

Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
<entry>
<title>i2c: recovery: require either get_sda or set_sda</title>
<updated>2018-07-17T08:41:55Z</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa+renesas@sang-engineering.com</email>
</author>
<published>2018-07-10T21:42:16Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=ffc59c496bf8498657321c59433f55bbcf2d9c38'/>
<id>urn:sha1:ffc59c496bf8498657321c59433f55bbcf2d9c38</id>
<content type='text'>
For bus recovery, we either need to bail out early if we can read SDA or
we need to send STOP after every pulse. Otherwise recovery might be
misinterpreted as an unwanted write. So, require one of those SDA
handling functions to avoid this problem.

Signed-off-by: Wolfram Sang &lt;wsa+renesas@sang-engineering.com&gt;
Acked-by: Peter Rosin &lt;peda@axentia.se&gt;
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
<entry>
<title>Merge branch 'i2c/precise-locking-names_immutable' into i2c/for-4.19</title>
<updated>2018-07-12T22:12:53Z</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa@the-dreams.de</email>
</author>
<published>2018-07-12T22:12:53Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=fb2896a77989314ea89d89c3bdfee93002a760c9'/>
<id>urn:sha1:fb2896a77989314ea89d89c3bdfee93002a760c9</id>
<content type='text'>
</content>
</entry>
<entry>
<title>i2c: remove i2c_lock_adapter and use i2c_lock_bus directly</title>
<updated>2018-07-12T22:09:37Z</updated>
<author>
<name>Peter Rosin</name>
<email>peda@axentia.se</email>
</author>
<published>2018-06-20T05:18:03Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=3f3a89e1d7c31558c070692241e3d6146d2cf1bf'/>
<id>urn:sha1:3f3a89e1d7c31558c070692241e3d6146d2cf1bf</id>
<content type='text'>
The i2c_lock_adapter name is ambiguous since it is unclear if it
refers to the root adapter or the adapter you name in the argument.
The natural interpretation is the adapter you name in the argument,
but there are historical reasons for that not being the case; it
in fact locks the root adapter. Just remove the function and force
users to spell out the I2C_LOCK_ROOT_ADAPTER name to indicate what
is really going on. Also remove i2c_unlock_adapter, of course.

This patch was generated with

git grep -l 'i2c_\(un\)\?lock_adapter' \
| xargs sed -i 's/i2c_\(un\)\?lock_adapter(\([^)]*\))/'\
'i2c_\1lock_bus(\2, I2C_LOCK_ROOT_ADAPTER)/g'

followed by white-space touch-up.

Signed-off-by: Peter Rosin &lt;peda@axentia.se&gt;
Acked-by: Jonathan Cameron &lt;jonathan.cameron@huawei.com&gt;
Tested-by: Sekhar Nori &lt;nsekhar@ti.com&gt;
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
<entry>
<title>i2c: smbus: add unlocked __i2c_smbus_xfer variant</title>
<updated>2018-07-03T20:57:25Z</updated>
<author>
<name>Peter Rosin</name>
<email>peda@axentia.se</email>
</author>
<published>2018-06-20T08:51:53Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=63453b59e41173241c4efe9335815f6432fa8586'/>
<id>urn:sha1:63453b59e41173241c4efe9335815f6432fa8586</id>
<content type='text'>
Removes all locking from i2c_smbus_xfer and renames it to __i2c_smbus_xfer,
then adds a new i2c_smbus_xfer function that simply grabs the lock while
calling the unlocked variant.

This is not perfectly equivalent, since i2c_smbus_xfer was callable from
atomic/irq context if you happened to end up emulating SMBus with an I2C
transfer, and that is no longer the case with this patch. It is unknown
(to me) if anything depends on that quirk, but it seems fragile enough to
simply break those cases and require them to call i2c_transfer directly
instead.

While at it, for consistency rename the 2nd to last argument (size) of
the i2c_smbus_xfer declaration to protocol and remove the surplus extern
marker.

Signed-off-by: Peter Rosin &lt;peda@axentia.se&gt;
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
<entry>
<title>i2c: Export of_i2c_get_board_info()</title>
<updated>2018-05-22T11:42:16Z</updated>
<author>
<name>Boris Brezillon</name>
<email>boris.brezillon@bootlin.com</email>
</author>
<published>2018-03-25T12:49:03Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=da0086d018223529c686ef46db039533572418d8'/>
<id>urn:sha1:da0086d018223529c686ef46db039533572418d8</id>
<content type='text'>
I3C busses have to know about all I2C devices connected on the I3C bus
to properly initialize the I3C master, and I2C frames can't be sent on
the bus until this initialization is done.

We can't let the I2C core parse the DT and instantiate I2C devices as
part of its i2c_add_adapter() procedure because, when done this way,
I2C devices are directly registered to the device-model and might be
attached to drivers which could in turn start sending frames on the bus,
which won't work since, as said above, the bus is not yet initialized.

Export of_i2c_register_device() in order to let the I3C core parse the
I2C device nodes by itself and initialize the bus.

Signed-off-by: Boris Brezillon &lt;boris.brezillon@bootlin.com&gt;
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
</content>
</entry>
</feed>
