aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2017-10-11 15:54:32 -0400
committerScott Murray <scott.murray@konsulko.com>2017-10-11 16:02:52 -0400
commitdc710d7a1835b444554572a8ca390c0388ceb91f (patch)
tree9bedd175c98eaa97cad91df39cc2963ff649ca24
parent29ffbaaf5c84f0c8fad0940939bd8a54d5879c56 (diff)
Switch to AFB_SESSION_NONE for verbs
Recent testing found that the verbs no longer work now with the AFB_SESSION_CHECK flag set on them and the binding split out to be standalone from the app. Since the radio does not really need the concept of a session, switch to AFB_SESSION_NONE to get things working, rather than add the extra infrastructure to enable session support. Change-Id: I9c022eaf7a18a1094b9afb7c6bddf1a8ebc9e875 Signed-off-by: Scott Murray <scott.murray@konsulko.com>
-rw-r--r--binding/radio-binding.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/binding/radio-binding.c b/binding/radio-binding.c
index c82c435..505ee4c 100644
--- a/binding/radio-binding.c
+++ b/binding/radio-binding.c
@@ -446,18 +446,18 @@ static void unsubscribe(struct afb_req request)
}
static const struct afb_verb_v2 verbs[]= {
- { .verb = "frequency", .session = AFB_SESSION_CHECK, .callback = frequency, .info = "Get/Set frequency" },
- { .verb = "band", .session = AFB_SESSION_CHECK, .callback = band, .info = "Get/Set band" },
- { .verb = "band_supported", .session = AFB_SESSION_CHECK, .callback = band_supported, .info = "Check band support" },
- { .verb = "frequency_range", .session = AFB_SESSION_CHECK, .callback = frequency_range, .info = "Get frequency range" },
- { .verb = "frequency_step", .session = AFB_SESSION_CHECK, .callback = frequency_step, .info = "Get frequency step" },
- { .verb = "start", .session = AFB_SESSION_CHECK, .callback = start, .info = "Start radio playback" },
- { .verb = "stop", .session = AFB_SESSION_CHECK, .callback = stop, .info = "Stop radio playback" },
- { .verb = "scan_start", .session = AFB_SESSION_CHECK, .callback = scan_start, .info = "Start station scan" },
- { .verb = "scan_stop", .session = AFB_SESSION_CHECK, .callback = scan_stop, .info = "Stop station scan" },
- { .verb = "stereo_mode", .session = AFB_SESSION_CHECK, .callback = stereo_mode, .info = "Get/Set stereo_mode" },
- { .verb = "subscribe", .session = AFB_SESSION_CHECK, .callback = subscribe, .info = "Subscribe for an event" },
- { .verb = "unsubscribe", .session = AFB_SESSION_CHECK, .callback = unsubscribe, .info = "Unsubscribe for an event" },
+ { .verb = "frequency", .session = AFB_SESSION_NONE, .callback = frequency, .info = "Get/Set frequency" },
+ { .verb = "band", .session = AFB_SESSION_NONE, .callback = band, .info = "Get/Set band" },
+ { .verb = "band_supported", .session = AFB_SESSION_NONE, .callback = band_supported, .info = "Check band support" },
+ { .verb = "frequency_range", .session = AFB_SESSION_NONE, .callback = frequency_range, .info = "Get frequency range" },
+ { .verb = "frequency_step", .session = AFB_SESSION_NONE, .callback = frequency_step, .info = "Get frequency step" },
+ { .verb = "start", .session = AFB_SESSION_NONE, .callback = start, .info = "Start radio playback" },
+ { .verb = "stop", .session = AFB_SESSION_NONE, .callback = stop, .info = "Stop radio playback" },
+ { .verb = "scan_start", .session = AFB_SESSION_NONE, .callback = scan_start, .info = "Start station scan" },
+ { .verb = "scan_stop", .session = AFB_SESSION_NONE, .callback = scan_stop, .info = "Stop station scan" },
+ { .verb = "stereo_mode", .session = AFB_SESSION_NONE, .callback = stereo_mode, .info = "Get/Set stereo_mode" },
+ { .verb = "subscribe", .session = AFB_SESSION_NONE, .callback = subscribe, .info = "Subscribe for an event" },
+ { .verb = "unsubscribe", .session = AFB_SESSION_NONE, .callback = unsubscribe, .info = "Unsubscribe for an event" },
{ }
};