Commit Graph

5 Commits

Author SHA1 Message Date
Simon Glass e160f7d430 dm: core: Replace of_offset with accessor
At present devices use a simple integer offset to record the device tree
node associated with the device. In preparation for supporting a live
device tree, which uses a node pointer instead, refactor existing code to
access this field through an inline function.

Signed-off-by: Simon Glass <sjg@chromium.org>
2017-02-08 06:12:14 -07:00
Wenyou Yang 52f37333bc i2c: at91_i2c: Change error return -ENODEV to -EINVAL
Change the error return value -ENODEV from to -EINVAL for more
reasonable.

Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
2016-10-28 18:37:14 +02:00
Wenyou Yang 2ccc07bbdc i2c: at91_i2c: Remove unnecessary clock calling
Due to the peripheral clock driver improvement, remove the
unnecessary clock calling.

Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
2016-10-28 18:37:14 +02:00
Wenyou Yang 76062b9cdb i2c: at91_i2c: Fix the wrong include file
Since the 'clk_client.h' doesn't exist, it should be 'clk.h'.

Signed-off-by: Wenyou Yang <wenyou.yang@atmel.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2016-09-13 06:58:54 +02:00
Songjun Wu 8800e0fa20 i2c: atmel: add i2c driver
Add i2c driver.

Signed-off-by: Songjun Wu <songjun.wu@atmel.com>
Reviewed-by: Heiko Schocher <hs@denx.de>
Acked-by: Heiko Schocher <hs@denx.de>
2016-08-15 22:12:00 +02:00