summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjklug <jklug@jakDebian11.dc.multitech.prv>2022-01-23 09:44:14 -0600
committerjklug <jklug@jakDebian11.dc.multitech.prv>2022-01-23 09:44:14 -0600
commit1e8f15e4a6d38678f289b9557d9c665afb70df3f (patch)
tree3245cd495d8bda3e3d705de7f5439f0087838fae
parent969e42d72045e315196317d08c001433ce04169e (diff)
downloadmts-io-1e8f15e4a6d38678f289b9557d9c665afb70df3f.tar.gz
mts-io-1e8f15e4a6d38678f289b9557d9c665afb70df3f.tar.bz2
mts-io-1e8f15e4a6d38678f289b9557d9c665afb70df3f.zip
Add monitor pins for USB Host Power Control4.8.4
-rw-r--r--configure.ac2
-rw-r--r--io-module/machine/mtcdt.c46
-rw-r--r--io-module/version.h2
3 files changed, 47 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac
index 071ec84..0bde50a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,4 @@
-AC_INIT([mts-io], [4.8.3])
+AC_INIT([mts-io], [4.8.4])
AC_CONFIG_SRCDIR([util/mts_util_lora2_reset.c])
AM_INIT_AUTOMAKE
AM_CONFIG_HEADER([config.h])
diff --git a/io-module/machine/mtcdt.c b/io-module/machine/mtcdt.c
index 5ee77cb..09223c1 100644
--- a/io-module/machine/mtcdt.c
+++ b/io-module/machine/mtcdt.c
@@ -323,6 +323,24 @@ static struct gpio_pin gpio_pins_mtcdt_0_1[] = {
}
},
{
+ .name = "N_USB_HOST_OC",
+ .pin = {
+ .gpio = AT91_PIN_PA7,
+ .flags = GPIOF_IN,
+ .label = "usb-host-oc",
+ },
+ .active_low = 1,
+ },
+ {
+ .name = "N_USB_HOST_PWR_EN",
+ .pin = {
+ .gpio = AT91_PIN_PA8,
+ .flags = GPIOF_IN,
+ .label = "usb-host-pwr",
+ },
+ .active_low = 1,
+ },
+ {
.name = "GNSS_INT",
.pin = {
.gpio = AT91_PIN_PD19,
@@ -542,6 +560,24 @@ static struct gpio_pin gpio_pins_mtcdt_0_2[] = {
}
},
{
+ .name = "N_USB_HOST_OC",
+ .pin = {
+ .gpio = AT91_PIN_PA7,
+ .flags = GPIOF_IN,
+ .label = "usb-host-oc",
+ },
+ .active_low = 1,
+ },
+ {
+ .name = "N_USB_HOST_PWR_EN",
+ .pin = {
+ .gpio = AT91_PIN_PA8,
+ .flags = GPIOF_IN,
+ .label = "usb-host-pwr",
+ },
+ .active_low = 1,
+ },
+ {
.name = "GNSS_INT",
.pin = {
.gpio = AT91_PIN_PD19,
@@ -578,6 +614,10 @@ static DEVICE_ATTR_MTS(dev_attr_gnss_reset, "gnss-reset",
mts_attr_show_gpio_pin, mts_attr_store_gpio_pin);
static DEVICE_ATTR_MTS(dev_attr_usbhub_reset, "usbhub-reset",
mts_attr_show_gpio_pin, mts_attr_store_gpio_pin);
+static DEVICE_ATTR_RO_MTS(dev_attr_usbhost_oc, "usb-host-oc",
+ mts_attr_show_gpio_pin);
+static DEVICE_ATTR_RO_MTS(dev_attr_usbhost_pwr, "usb-host-pwr",
+ mts_attr_show_gpio_pin);
static DEVICE_ATTR_MTS(dev_attr_eth_reset, "eth-reset",
mts_attr_show_gpio_pin, mts_attr_store_gpio_pin);
static DEVICE_ATTR_MTS(dev_attr_gnss_int, "gnss-int",
@@ -652,6 +692,8 @@ static struct attribute *mtcdt_0_1_platform_attributes[] = {
&dev_attr_led_d_gpio.attr,
&dev_attr_usbhub_reset.attr,
+ &dev_attr_usbhost_oc.attr,
+ &dev_attr_usbhost_pwr.attr,
&dev_attr_eth_reset.attr,
// radio feature is last to be able to
@@ -696,9 +738,11 @@ static struct attribute *mtcdt_0_2_platform_attributes[] = {
&dev_attr_led_d_gpio.attr,
&dev_attr_usbhub_reset.attr,
+ &dev_attr_usbhost_oc.attr,
+ &dev_attr_usbhost_pwr.attr,
&dev_attr_eth_reset.attr,
- &dev_attr_radio_power.attr, /* Must be first radio attribute */
+ &dev_attr_radio_power.attr, /* Must be first radio attribute */
&dev_attr_radio_reset.attr,
&dev_attr_radio_status.attr,
diff --git a/io-module/version.h b/io-module/version.h
index 0ecb889..3432796 100644
--- a/io-module/version.h
+++ b/io-module/version.h
@@ -1,7 +1,7 @@
#ifndef __VERSION_H
#define __VERSION_H
-#define DRIVER_VERSION "v4.8.3"
+#define DRIVER_VERSION "v4.8.4"
#define DRIVER_AUTHOR "Multitech Systems"
#define DRIVER_DESC "MTS-IO Controller"
#define DRIVER_NAME "mts-io"