#define PROFILE_SUPPORTED 0x3 /* This corresponds to binary 0b11*/
typedef enum {
- CONNECTION_RESTRICTED = 0x0, /* 0b00 */
- CONNECTION_PERMITTED = 0x1, /* 0b01 */
+ CONNECTION_PERMITTED = 0x0, /* 0b00 */
+ CONNECTION_RESTRICTED = 0x1, /* 0b01 */
} bt_profile_restricted_states;
#define HFP_HS_SHIFT_OFFSET 0
dev->restricted_profiles.a2dp);
if (g_strcmp0(uuid, HFP_HS_UUID) == 0) {
if (profile_restricted)
- hfp_hs = CONNECTION_PERMITTED;
- else
hfp_hs = CONNECTION_RESTRICTED;
+ else
+ hfp_hs = CONNECTION_PERMITTED;
} else if (g_strcmp0(uuid, A2DP_SINK_UUID) == 0) {
if (profile_restricted)
- a2dp = CONNECTION_PERMITTED;
- else
a2dp = CONNECTION_RESTRICTED;
+ else
+ a2dp = CONNECTION_PERMITTED;
} else {
return btd_error_invalid_args(msg);
}