i3c: fix i2c and i3c scl rate by bus mode
authorVitor Soares <Vitor.Soares@synopsys.com>
Wed, 19 Jun 2019 18:36:31 +0000 (20:36 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 26 Jul 2019 07:13:02 +0000 (09:13 +0200)
commit3620a72ccc726aef247e4d7c5968546a94fdb551
tree543e07590f64110620d936956eed1b0f18ab7243
parent7eb45a94c279dd5af4cafaa738ae93737517eef4
i3c: fix i2c and i3c scl rate by bus mode

commit ecc8fb54bd443bf69996d9d5ddb8d90a50f14936 upstream.

Currently the I3C framework limits SCL frequency to FM speed when
dealing with a mixed slow bus, even if all I2C devices are FM+ capable.

The core was also not accounting for I3C speed limitations when
operating in mixed slow mode and was erroneously using FM+ speed as the
max I2C speed when operating in mixed fast mode.

Fixes: 3a379bbcea0a ("i3c: Add core I3C infrastructure")
Signed-off-by: Vitor Soares <vitor.soares@synopsys.com>
Cc: Boris Brezillon <bbrezillon@kernel.org>
Cc: <stable@vger.kernel.org>
Cc: <linux-kernel@vger.kernel.org>
Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/i3c/master.c