From e2927bb07b71d0ce26843f48354f29106be0cc37 Mon Sep 17 00:00:00 2001 From: Seungyoun Ju Date: Tue, 13 Sep 2016 22:00:59 +0900 Subject: [PATCH] Support old storage format [Model] COMMON [BinType] AP [Customer] OPEN [Issue#] N/A [Request] Internal [Occurrence Version] N/A [Problem] Old storage has BR/EDR/LE information in one RPA directory. So dbus object path is made as RPA. If we pass IDA when upper layer requests, it cannot be used because there is no matched dbus object path. [Cause & Measure] Current storage policy separates BR/EDR and LE information to each addresses. So both dbus object paths are created. So in this case, IDA should be passed to upper layer. But in case of old version's paired device, RPA should be passed to upper layer. [Checking Method] The device which has old storage (e.g. R730 VP1) makes pairing with iOS -> FOTA to new storage (e.g. VP2) [Team] Basic connection [Developer] Seungyoun Ju [Solution company] Samsung [Change Type] Specification change Change-Id: I3dd1a1afad93a38ee2b3bfd2bb6cc371cc066dc2 --- src/device.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/device.c b/src/device.c index 4e797c1..c87a0f6 100644 --- a/src/device.c +++ b/src/device.c @@ -3767,9 +3767,12 @@ static DBusMessage *device_get_ida(DBusConnection *conn, DBusMessage *msg, if (!device->le) return btd_error_not_supported(msg); - if (device->rpa) - ba2str(&device->bdaddr, device_idaddr); - else + if (device->rpa) { + if (device->bredr) + ba2str(device->rpa, device_idaddr); + else + ba2str(&device->bdaddr, device_idaddr); + } else return btd_error_does_not_exist(msg); reply = dbus_message_new_method_return(msg); -- 2.7.4