Re: [PATCH 8/8] proximity: reporter: implement D-Bus API

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hey Anderson,

On Wed, Mar 14, 2012 at 15:19, Anderson Lizardo
<anderson.lizardo@xxxxxxxxxxxxx> wrote:
>> +       /*
>> +        * Register watches for getting device change events. We watch
>> +        * for existing, new and removed devices.
>> +        */
>> +       radapter->watch_added = g_dbus_add_signal_watch(radapter->conn,
>> +                                       BLUEZ_SERVICE, NULL, ADAPTER_INTERFACE,
>> +                                       "DeviceAdded", handle_device_change,
>> +                                       radapter, NULL);
>> +
>> +       radapter->watch_created = g_dbus_add_signal_watch(radapter->conn,
>> +                                       BLUEZ_SERVICE, NULL, ADAPTER_INTERFACE,
>> +                                       "DeviceCreated", handle_device_change,
>> +                                       radapter, NULL);
>> +
>> +       radapter->watch_removed = g_dbus_add_signal_watch(radapter->conn,
>> +                                       BLUEZ_SERVICE, NULL, ADAPTER_INTERFACE,
>> +                                       "DeviceRemoved", handle_device_change,
>> +                                       radapter, NULL);
>
> Again, setting a watcher for BlueZ own signals is strange. Why can't
> you use a device driver like other plugins?

For some strange reason I was convinced btd_device_drivers only get
notified when a device connects. But of course this isn't the case.
This will simplify the code a bit. I'll also remove the patch adding
the "DeviceAdded" signal.

Thanks,
Arik
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux