device: Add DA logic to restrict the connection to only one mobile device 04/307004/1 accepted/tizen_unified accepted/tizen_unified_x accepted/tizen/unified/20240308.173922 accepted/tizen/unified/x/20240311.100348
authorWootak Jung <wootak.jung@samsung.com>
Thu, 29 Feb 2024 02:18:14 +0000 (11:18 +0900)
committerWootak Jung <wootak.jung@samsung.com>
Sun, 3 Mar 2024 23:07:11 +0000 (08:07 +0900)
Change-Id: Ibd4e485a594b2644ef5ab89de8e559a766480cf0
Signed-off-by: Wootak Jung <wootak.jung@samsung.com>
src/device.c

index 270053d..eaf9e5f 100644 (file)
@@ -7369,8 +7369,13 @@ void device_unpair(struct btd_device *device, gboolean remove_stored)
        device->trusted_profiles.pbap = SHOW_AUTHORIZATION;
        device->trusted_profiles.map = SHOW_AUTHORIZATION;
        device->trusted_profiles.sap = SHOW_AUTHORIZATION;
-       device->trusted_profiles.hfp_hs = SUPPORTED_TRUSTED;
-       device->trusted_profiles.a2dp = SUPPORTED_TRUSTED;
+       if (TIZEN_MODEL_DA) {
+               device->trusted_profiles.hfp_hs = SHOW_AUTHORIZATION;
+               device->trusted_profiles.a2dp = SHOW_AUTHORIZATION;
+       } else {
+               device->trusted_profiles.hfp_hs = SUPPORTED_TRUSTED;
+               device->trusted_profiles.a2dp = SUPPORTED_TRUSTED;
+       }
        if (device->alias != NULL) {
                /* Remove alias name because
                 * In UG if we rename and then unpair device and