arm: Remove pcm051 board
[oweals/u-boot.git] / include / twl6030.h
index 40e2c111d7602a80d1f0931ac9260cd853cc366b..41f17de3ab5572fbe511fcfc5f60c0606ba785d9 100644 (file)
@@ -1,8 +1,7 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
 /*
  * (C) Copyright 2010
  * Texas Instruments, <www.ti.com>
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #ifndef TWL6030_H
@@ -187,6 +186,7 @@ struct twl6030_data{
 };
 
 /* Functions to read and write from TWL6030 */
+#ifndef CONFIG_DM_I2C
 static inline int twl6030_i2c_write_u8(u8 chip_no, u8 reg, u8 val)
 {
        return i2c_write(chip_no, reg, 1, &val, 1);
@@ -196,6 +196,10 @@ static inline int twl6030_i2c_read_u8(u8 chip_no, u8 reg, u8 *val)
 {
        return i2c_read(chip_no, reg, 1, val, 1);
 }
+#else
+int twl6030_i2c_write_u8(u8 chip_no, u8 reg, u8 val);
+int twl6030_i2c_read_u8(u8 chip_no, u8 reg, u8 *val);
+#endif
 
 /*
  * Power