summaryrefslogtreecommitdiffstats
path: root/include/i2c_eeprom.h
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2014-12-10 08:55:54 -0700
committerSimon Glass <sjg@chromium.org>2014-12-11 13:18:43 -0700
commit20142019a96a72bf1516be93a86fc10d028fd136 (patch)
treea029c7e3490243ceb6d22fe929fa3a0aadf2d1aa /include/i2c_eeprom.h
parent776f96f513869a784c3c0bd5a972f408c10e067a (diff)
downloadblackbird-obmc-uboot-20142019a96a72bf1516be93a86fc10d028fd136.tar.gz
blackbird-obmc-uboot-20142019a96a72bf1516be93a86fc10d028fd136.zip
dm: Add a simple EEPROM driver
There seem to be a few EEPROM drivers around - perhaps we should have a single standard one? This simple driver is used for sandbox testing, but could be pressed into more active service. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Heiko Schocher <hs@denx.de> Reviewed-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Diffstat (limited to 'include/i2c_eeprom.h')
-rw-r--r--include/i2c_eeprom.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/include/i2c_eeprom.h b/include/i2c_eeprom.h
new file mode 100644
index 0000000000..ea6c962a39
--- /dev/null
+++ b/include/i2c_eeprom.h
@@ -0,0 +1,19 @@
+/*
+ * Copyright (c) 2014 Google, Inc
+ *
+ * SPDX-License-Identifier: GPL-2.0+
+ */
+
+#ifndef __I2C_EEPROM
+#define __I2C_EEPROM
+
+struct i2c_eeprom_ops {
+ int (*read)(struct udevice *dev, int offset, uint8_t *buf, int size);
+ int (*write)(struct udevice *dev, int offset, const uint8_t *buf,
+ int size);
+};
+
+struct i2c_eeprom {
+};
+
+#endif
OpenPOWER on IntegriCloud