Search Linux Wireless

Re: [PATCH 2/6] NFC: add nfc generic netlink interface

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

 



On Fri, Jun 3, 2011 at 5:38 PM, Johannes Berg <johannes@xxxxxxxxxxxxxxxx> wrote:
> On Fri, 2011-06-03 at 17:18 -0300, Lauro Ramos Venancio wrote:
>> We don't need a generation counter here because we have the events
>> NFC_EVENT_DEVICE_ADDED and NFC_EVENT_DEVICE_REMOVED. So, it is
>> possible to keep the device list consistency listening for these
>> events.
>
> That may be true, but it complicates coding in userspace. Much easier to
> check a generation counter (in both cases) to see if data is consistent
> than to listen to multiple events concurrently with receiving a dump.

The userspace must listen to these events anyway. In addition, the
application needs to get the list of devices only once (on its
initialization).

In the target list case, the userspace application would have to
orderly call start_poll before receive the dump in order to create the
"invalid list" situation.

I understand the benefits of the generation counters, but IMO they are
'too much' in these cases.

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


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux