Apply DA model specification 03/307003/1
authorWootak Jung <wootak.jung@samsung.com>
Tue, 13 Feb 2024 00:21:11 +0000 (09:21 +0900)
committerWootak Jung <wootak.jung@samsung.com>
Sun, 3 Mar 2024 23:07:09 +0000 (08:07 +0900)
Disable A2DP/AVRCP profiles

Change-Id: Ie20002629367c9383973dba6f900425aa0e9a763
Signed-off-by: Wootak Jung <wootak.jung@samsung.com>
profiles/audio/avrcp.c
profiles/audio/media.c

index bbda7f66c3798d476c3572d75589033a0fdefbd1..9a846c306dd1a2b457c953287f07eaafc5c7eb46 100644 (file)
@@ -5297,6 +5297,11 @@ static int avrcp_target_server_probe(struct btd_profile *p,
        sdp_record_t *record;
        struct avrcp_server *server;
 
+       if (TIZEN_FEATURE_BLUEZ_DA && !TIZEN_FEATURE_BLUEZ_FHUB) {
+               DBG("AVRCP Target not supported in DA (non-fhub) product");
+               return -1;
+       }
+
        DBG("path %s", adapter_get_path(adapter));
 
        server = find_server(servers, adapter);
@@ -5385,6 +5390,11 @@ static int avrcp_controller_server_probe(struct btd_profile *p,
        sdp_record_t *record;
        struct avrcp_server *server;
 
+       if (TIZEN_FEATURE_BLUEZ_DA && !TIZEN_FEATURE_BLUEZ_FHUB) {
+               DBG("AVRCP Controller not supported in DA (non-fhub) product");
+               return -1;
+       }
+
        DBG("path %s", adapter_get_path(adapter));
 
        server = find_server(servers, adapter);
index 3b6bc239233cd162ec647d79de4c443e6bd5c44b..af5412fa2310f0498f0b92ff76bda070e4c06fe6 100644 (file)
@@ -905,6 +905,11 @@ static void a2dp_destroy_endpoint(void *user_data)
 
 static bool endpoint_init_a2dp_source(struct media_endpoint *endpoint, int *err)
 {
+       if (TIZEN_FEATURE_BLUEZ_DA && !TIZEN_FEATURE_BLUEZ_FHUB) {
+               DBG("A2DP source not supported in DA (non-fhub) product");
+               return FALSE;
+       }
+
        endpoint->sep = a2dp_add_sep(endpoint->adapter->btd_adapter,
                                        AVDTP_SEP_TYPE_SOURCE, endpoint->codec,
                                        endpoint->delay_reporting, &a2dp_endpoint,
@@ -921,6 +926,11 @@ static bool endpoint_init_a2dp_source(struct media_endpoint *endpoint, int *err)
 
 static bool endpoint_init_a2dp_sink(struct media_endpoint *endpoint, int *err)
 {
+       if (TIZEN_FEATURE_BLUEZ_DA && !TIZEN_FEATURE_BLUEZ_FHUB) {
+               DBG("A2DP sink not supported in DA (non-fhub) product");
+               return FALSE;
+       }
+
        endpoint->sep = a2dp_add_sep(endpoint->adapter->btd_adapter,
                                        AVDTP_SEP_TYPE_SINK, endpoint->codec,
                                        endpoint->delay_reporting, &a2dp_endpoint,