Re: [PATCH] gattrib: Fix command timeout handling

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

 



Hi Johan,

On 20:17 Tue 05 Jun, Johan Hedberg wrote:
> From: Johan Hedberg <johan.hedberg@xxxxxxxxx>
> 
> This patch fixes command timeout handling. Previously attrib_destroy was
> explicitly called which ignored any reference holders. This patch fixes
> the issue by first passing errors to command callbacks and after that
> marking the GAttrib object as stale so no further operations can be
> done.
> ---
> This is an untested patch which should hopefully fix bluetoothd crashes
> when we fail to receive a response to a command. I'm sending it to
> linux-bluetooth in case someone can spot some obvious problem with it.
> If there are no objections I'll complete testing of it during the next
> 24 hours and then apply it upstream.

Looks fine to me as well.

On a side note, I took a look at how gatchat[1] (from ofono) does this, and
it gave me some ideas about how to simplify some things, I am thinking
mostly about the GAttrib destruction code path. And this "stale"
condition would be useful.


[snip]


Cheers,
-- 
Vinicius

[1] http://git.kernel.org/?p=network/ofono/ofono.git;a=blob;f=gatchat/gatio.c;hb=HEAD
--
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