summaryrefslogtreecommitdiff
path: root/io-module/mts_io.c
diff options
context:
space:
mode:
authorMykyta Dorokhin <mykyta.dorokhin@globallogic.com>2016-09-13 22:35:55 +0300
committerMykyta Dorokhin <mykyta.dorokhin@globallogic.com>2016-09-13 22:35:55 +0300
commitf544b19438dc3a0c14b957d8ba5fcc1113ecf542 (patch)
treeb646dff5614f9f2009904cec34d49c466ddb227b /io-module/mts_io.c
parentf85e518970c3fec481ce59aabf91f097466ef40c (diff)
downloadmts-io-f544b19438dc3a0c14b957d8ba5fcc1113ecf542.tar.gz
mts-io-f544b19438dc3a0c14b957d8ba5fcc1113ecf542.tar.bz2
mts-io-f544b19438dc3a0c14b957d8ba5fcc1113ecf542.zip
feat: add MTP-0.0 hardware support1.3.0
Diffstat (limited to 'io-module/mts_io.c')
-rw-r--r--io-module/mts_io.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/io-module/mts_io.c b/io-module/mts_io.c
index deb2d92..bf0a6bd 100644
--- a/io-module/mts_io.c
+++ b/io-module/mts_io.c
@@ -623,6 +623,7 @@ static DEVICE_ATTR_RO_MTS(dev_attr_eth_mac, "mac-eth",
/* include per-device pins and attributes */
#include "mtcdt.c"
+#include "mtp.c"
#if NUM_AP > 0
@@ -766,7 +767,12 @@ static int mts_id_eeprom_load(void)
if (mts_id_eeprom[0] == 0xFF) {
log_error("uninitialized eeprom");
return -EIO;
- } else if (strncmp(id_eeprom.hw_version, HW_VERSION_MTCDT_0_1, strlen(HW_VERSION_MTCDT_0_1)) == 0) {
+ } else if (strncmp(id_eeprom.hw_version, HW_VERSION_MTP_0_0, strlen(HW_VERSION_MTP_0_0)) == 0) {
+ attr_group = &mtp_0_0_platform_attribute_group;
+ gpio_pins = gpio_pins_mtp_0_0;
+ log_info("detected board %s", HW_VERSION_MTP_0_0);
+ }
+ else if (strncmp(id_eeprom.hw_version, HW_VERSION_MTCDT_0_1, strlen(HW_VERSION_MTCDT_0_1)) == 0) {
attr_group = &mtcdt_0_1_platform_attribute_group;
gpio_pins = gpio_pins_mtcdt_0_1;
log_info("detected board %s", HW_VERSION_MTCDT_0_1);