summaryrefslogtreecommitdiff
path: root/io-module/mtcdt.c
diff options
context:
space:
mode:
Diffstat (limited to 'io-module/mtcdt.c')
-rw-r--r--io-module/mtcdt.c25
1 files changed, 19 insertions, 6 deletions
diff --git a/io-module/mtcdt.c b/io-module/mtcdt.c
index 048e11c..b84e67a 100644
--- a/io-module/mtcdt.c
+++ b/io-module/mtcdt.c
@@ -714,12 +714,6 @@ static struct attribute *mtcdt_0_1_platform_attributes[] = {
&dev_attr_reset.attr,
&dev_attr_reset_monitor.attr,
&dev_attr_reset_monitor_intervals.attr,
- &dev_attr_radio_power.attr,
- &dev_attr_radio_reset.attr,
-
- &dev_attr_radio_reset_backoffs.attr,
- &dev_attr_radio_reset_backoff_index.attr,
- &dev_attr_radio_reset_backoff_seconds.attr,
&dev_attr_led_status.attr,
&dev_attr_led_cd_gpio.attr,
@@ -734,6 +728,18 @@ static struct attribute *mtcdt_0_1_platform_attributes[] = {
&dev_attr_usbhub_reset.attr,
&dev_attr_eth_reset.attr,
+
+ // radio feature is last to be able to
+ // easily remove radio.
+ // is_radio_power_attr_mtcdt() truncates
+ // this list.
+ &dev_attr_radio_power.attr,
+ &dev_attr_radio_reset.attr,
+
+ &dev_attr_radio_reset_backoffs.attr,
+ &dev_attr_radio_reset_backoff_index.attr,
+ &dev_attr_radio_reset_backoff_seconds.attr,
+
NULL,
};
@@ -757,3 +763,10 @@ static struct attribute_group mtcdt_platform_attribute_group = {
static struct attribute_group mtcdt_0_1_platform_attribute_group = {
.attrs = mtcdt_0_1_platform_attributes
};
+
+
+static int
+is_radio_power_attr_mtcdt(struct attribute *attr)
+{
+ return (attr == &dev_attr_radio_power.attr);
+} \ No newline at end of file