diff options
author | h.sandeep <h.sandeep@samsung.com> | 2016-11-14 14:35:00 +0530 |
---|---|---|
committer | h.sandeep <h.sandeep@samsung.com> | 2016-11-14 15:26:19 +0530 |
commit | 4a464ed00b68a2279c7040139e38791ebb68cabd (patch) | |
tree | 2b9a04f1a3362d0df7cc64b269ba67840fc4f685 | |
parent | 197e6b17112216af538350fb341483223bd19a73 (diff) | |
download | bluez-4a464ed00b68a2279c7040139e38791ebb68cabd.tar.gz bluez-4a464ed00b68a2279c7040139e38791ebb68cabd.tar.bz2 bluez-4a464ed00b68a2279c7040139e38791ebb68cabd.zip |
iBeacon: Remove ibeaconReport signal logic.
This patch removes the ibeacon report filter logic
and removes the signal iBeaconReport.
iBeacon filter logic is handled in CAPI.
Change-Id: Iecc1b82be967e70a5f2a9d497b5f791d5d092edf
Signed-off-by: h.sandeep <h.sandeep@samsung.com>
-rw-r--r-- | src/adapter.c | 2 | ||||
-rw-r--r-- | src/device.c | 65 | ||||
-rw-r--r-- | src/device.h | 4 |
3 files changed, 0 insertions, 71 deletions
diff --git a/src/adapter.c b/src/adapter.c index b3bf5642..732506da 100644 --- a/src/adapter.c +++ b/src/adapter.c @@ -9909,8 +9909,6 @@ static void update_found_devices(struct btd_adapter *adapter, else { /* if the application has registered for iBeacon report, * then send ibeacon report along with advertisement report */ - if (allow_report == IBEACON_REPORT) - device_set_ibeacon_report_info(dev, (void*)data, data_len, adv_type, rssi); device_set_adv_report_info(dev, (void*)data, data_len, adv_type, rssi); } #endif diff --git a/src/device.c b/src/device.c index e349c471..49de44b2 100644 --- a/src/device.c +++ b/src/device.c @@ -3926,17 +3926,6 @@ static const GDBusSignalTable device_signals[] = { { "max_rx_time", "q"})) }, { GDBUS_SIGNAL("IpspStateChanged", GDBUS_ARGS({"connected","b"},{"if_name","s"}))}, -#ifdef TIZEN_FEATURE_PLATFROM_SCAN_FILTER - { GDBUS_SIGNAL("iBeaconReport", - GDBUS_ARGS({"Address","s"}, - { "Address Type", "y" }, - { "company id", "u"}, - { "beacon type", "u"}, - { "UUID", "s"}, - { "major id", "u"}, - { "minor id", "u"}, - { "measured power", "y"})) }, -#endif }; #endif @@ -8262,60 +8251,6 @@ void btd_device_disconnect(struct btd_device *device) return; } -#ifdef TIZEN_FEATURE_PLATFROM_SCAN_FILTER -void device_set_ibeacon_report_info(struct btd_device *device, void *data, uint8_t data_len, - uint8_t adv_type, int8_t rssi) -{ - char peer_addr[18]; - const char *paddr = peer_addr; - const uint8_t *uuid_ptr = data+6; - uuid_t service; - const char *uuid_str = NULL; - dbus_int32_t rssi_val = rssi; - dbus_uint32_t company_id = 0; - dbus_uint32_t beacon_type = 0; - dbus_uint32_t major_id = 0; - dbus_uint32_t minor_id = 0; - uint8_t measured_power = 0; - uint8_t addr_type; - int k; - if (!device) - return; - - ba2str(&device->bdaddr, peer_addr); - /* Replace address type for paired RPA device since IDA passed from controller */ - if(device_get_rpa_exist(device) == true) - addr_type = BDADDR_LE_RANDOM; - else - addr_type = device->bdaddr_type; - - company_id = get_le16(data+2); - beacon_type = get_le16(data+4); - major_id = get_le16(data+22); - minor_id = get_le16(data+24); - measured_power = get_u8(data+26); - service.type = SDP_UUID128; - for (k = 0; k < 16; k++) - service.value.uuid128.data[k] = uuid_ptr[16 - k - 1]; - uuid_str = bt_uuid2string(&service); - - DBG("Company_id: 0x%04x, beacon_type: 0x%04x, UUID: %s", - company_id, beacon_type, uuid_str); - DBG(" major_id : 0x%04x, Minor_id: 0x%04x, measured_power: %d", - major_id, minor_id, measured_power); - g_dbus_emit_signal(dbus_conn, device->path, - DEVICE_INTERFACE, "iBeaconReport", - DBUS_TYPE_STRING, &paddr, - DBUS_TYPE_BYTE, &addr_type, - DBUS_TYPE_UINT32, &company_id, - DBUS_TYPE_UINT32, &beacon_type, - DBUS_TYPE_STRING, &uuid_str, - DBUS_TYPE_UINT32, &major_id, - DBUS_TYPE_UINT32, &minor_id, - DBUS_TYPE_BYTE, &measured_power, - DBUS_TYPE_INVALID); -} -#endif /* TIZEN_FEATURE_PLATFROM_SCAN_FILTER */ #endif static gboolean notify_attios(gpointer user_data) diff --git a/src/device.h b/src/device.h index 5fec33e1..11e655c3 100644 --- a/src/device.h +++ b/src/device.h @@ -186,10 +186,6 @@ void device_le_data_length_changed(struct btd_device *device, uint16_t max_tx_oc uint16_t max_rx_time); void device_get_tizen_addr(struct btd_device *device, uint8_t type, struct device_addr_type *addr); -#ifdef TIZEN_FEATURE_PLATFROM_SCAN_FILTER -void device_set_ibeacon_report_info(struct btd_device *device, void *data, uint8_t data_len, - uint8_t adv_type, int8_t rssi); -#endif /* TIZEN_FEATURE_PLATFROM_SCAN_FILTER */ #endif struct btd_device *btd_device_ref(struct btd_device *device); |