]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
i2c: stm32f7: fix first byte to send in slave mode
authorFabrice Gasnier <fabrice.gasnier@st.com>
Mon, 30 Sep 2019 15:28:01 +0000 (17:28 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Tue, 12 Nov 2019 17:47:35 +0000 (18:47 +0100)
commitcf62ce3a1f6932bb314d0afd0ff8dadaf98bc46a
tree6492d7a6c4712e16020fd6e6dc3bdfe8db9e9e46
parent32d2e60b094833d59e84decaf35e66b82f749011
i2c: stm32f7: fix first byte to send in slave mode

BugLink: https://bugs.launchpad.net/bugs/1852111
[ Upstream commit 02e64276c6dbcc4c5f39844f33d18180832a58f3 ]

The slave-interface documentation [1] states "the bus driver should
transmit the first byte" upon I2C_SLAVE_READ_REQUESTED slave event:
- 'val': backend returns first byte to be sent
The driver currently ignores the 1st byte to send on this event.

[1] https://www.kernel.org/doc/Documentation/i2c/slave-interface

Fixes: 60d609f30de2 ("i2c: i2c-stm32f7: Add slave support")
Signed-off-by: Fabrice Gasnier <fabrice.gasnier@st.com>
Reviewed-by: Pierre-Yves MORDRET <pierre-yves.mordret@st.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Connor Kuehl <connor.kuehl@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
drivers/i2c/busses/i2c-stm32f7.c