summaryrefslogtreecommitdiffstats
path: root/configfs.c
diff options
context:
space:
mode:
authorMark Farrugia <mark.farrugia@fiberdyne.com.au>2018-10-07 21:52:53 +1100
committerMark Farrugia <mark.farrugia@fiberdyne.com.au>2018-10-26 17:27:37 +1100
commitf834eb7b0799a4678639d2a9f71c1dc4352469ce (patch)
tree0be207d5be59bdbbd0560ba96cb03caecc9da71b /configfs.c
parentaeb43d0374f4b1fb383da088b198de55f139a280 (diff)
Move 'streams_sealed' to avirt_core
Signed-off-by: Mark Farrugia <mark.farrugia@fiberdyne.com.au>
Diffstat (limited to 'configfs.c')
-rw-r--r--configfs.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/configfs.c b/configfs.c
index bca0f56..cdfd171 100644
--- a/configfs.c
+++ b/configfs.c
@@ -10,8 +10,6 @@
#include <sound/core.h>
#include "core_internal.h"
-static bool streams_sealed = false;
-
static ssize_t cfg_avirt_stream_direction_show(struct config_item *item,
char *page)
{
@@ -137,7 +135,7 @@ cfg_avirt_stream_make_item(struct config_group *group, const char *name)
static ssize_t cfg_avirt_stream_group_sealed_show(struct config_item *item,
char *page)
{
- return snprintf(page, PAGE_SIZE, "%d\n", streams_sealed);
+ return snprintf(page, PAGE_SIZE, "%d\n", __avirt_streams_sealed());
}
static ssize_t cfg_avirt_stream_group_sealed_store(struct config_item *item,
@@ -147,7 +145,7 @@ static ssize_t cfg_avirt_stream_group_sealed_store(struct config_item *item,
unsigned long tmp;
char *p = (char *)page;
- if (streams_sealed) {
+ if (__avirt_streams_sealed()) {
pr_err("AVIRT streams are already sealed!\n");
return -EPERM;
}
@@ -159,8 +157,6 @@ static ssize_t cfg_avirt_stream_group_sealed_store(struct config_item *item,
return -ERANGE;
}
- streams_sealed = (bool)tmp;
-
CHK_ERR(__avirt_card_register());
return count;