i2c: add support for offset overflow in to address
authorRobert Beckett <bob.beckett@collabora.com>
Mon, 28 Oct 2019 17:44:57 +0000 (17:44 +0000)
committerHeiko Schocher <hs@denx.de>
Tue, 17 Dec 2019 05:57:12 +0000 (06:57 +0100)
commit85968522b928e19a27aa79f0cb186c80b8b82e47
tree21562077d4dc1e2c3558e76076c453fea952c87b
parent553cb06887825314e74a9bdac337467c77d1db88
i2c: add support for offset overflow in to address

Some devices (2 wire eeproms for example) use some bits from the chip
address to represent the high bits of the offset instead of or as well
as using multiple bytes for the offset, effectively stealing chip
addresses on the bus.

Add a chip offset mask that can be set for any i2c chip which gets
filled with the offset overflow during offset setup.

Signed-off-by: Robert Beckett <bob.beckett@collabora.com>
Signed-off-by: Ian Ray <ian.ray@ge.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
drivers/i2c/i2c-uclass.c
include/i2c.h