Files
linux/drivers
Vadim Pasternak d2d8f64012 i2c: mlxcpld: Fix wrong initialization order in probe
commit 13067ef73f upstream.

Fix wrong order in probing routine initialization - field `base_addr'
is used before it's initialized. Move assignment of 'priv->base_addr`
to the beginning, prior the call to mlxcpld_i2c_read_comm().
Wrong order caused the first read of capability register to be executed
at wrong offset 0x0 instead of 0x2000. By chance it was a "good
garbage" at 0x0 offset.

Fixes: 313ce648b5 ("i2c: mlxcpld: Add support for extended transaction length for i2c-mlxcpld")
Signed-off-by: Vadim Pasternak <vadimp@mellanox.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Cc: stable@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-06-09 09:17:18 +02:00
..
2019-05-31 06:46:31 -07:00
2019-05-14 19:17:53 +02:00
2019-05-14 19:17:53 +02:00
2018-12-21 14:15:17 +01:00
2019-05-31 06:46:34 -07:00
2018-11-13 11:08:51 -08:00
2018-11-27 16:13:09 +01:00
2019-04-27 09:36:31 +02:00
2019-05-31 06:46:14 -07:00