From 12aac29eb27cfd070ba1ebbaebb59b4f47edb442 Mon Sep 17 00:00:00 2001 From: DoHyun Pyun Date: Tue, 20 Sep 2016 14:41:51 +0900 Subject: [PATCH] Fix UTC fail issue for tv profile UX3 kernel task is not complete, so MGMT value is different. Before completing kernel's task, we need to return the dummy scan status. Change-Id: I9ba9517aa71659361cc06f7414983386a7a2b269 Signed-off-by: DoHyun Pyun --- packaging/bluez.spec | 4 ++++ src/adapter.c | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/packaging/bluez.spec b/packaging/bluez.spec index c6dff64..550ca22 100644 --- a/packaging/bluez.spec +++ b/packaging/bluez.spec @@ -104,6 +104,10 @@ export CFLAGS="${CFLAGS} -D__TIZEN_PATCH__ -D__BROADCOM_PATCH__ -DBLUEZ5_27_GATT export CFLAGS="${CFLAGS} -D__BT_SCMST_FEATURE__ -DSUPPORT_SMS_ONLY -D__BROADCOM_QOS_PATCH__ -DTIZEN_WEARABLE" %endif +%if "%{?profile}" == "tv" +export CFLAGS="${CFLAGS} -DTIZEN_PROFILE_TV" +%endif + export LDFLAGS=" -lncurses -Wl,--as-needed " export CFLAGS+=" -DPBAP_SIM_ENABLE -DSUPPORT_AVRCP_TARGET" %reconfigure --disable-static \ diff --git a/src/adapter.c b/src/adapter.c index c18f6c2..0ac54cf 100644 --- a/src/adapter.c +++ b/src/adapter.c @@ -1911,17 +1911,25 @@ static void start_le_discovery_complete(uint8_t status, uint16_t length, const void *param, void *user_data) { struct btd_adapter *adapter = user_data; +#ifndef TIZEN_PROFILE_TV const struct mgmt_cp_start_discovery *rp = param; +#endif DBG("status 0x%02x", status); +#ifndef TIZEN_PROFILE_TV DBG("Discovery Type 0x%02x", rp->type); if (length < sizeof(*rp)) { error("Wrong size of start discovery return parameters"); return; } +#else + status = MGMT_STATUS_SUCCESS; +#endif if (status == MGMT_STATUS_SUCCESS) { +#ifndef TIZEN_PROFILE_TV adapter->discovery_type |= rp->type; +#endif adapter->discovery_enable = 0x01; if (adapter->le_discovering) -- 2.7.4