On Tue, 2012-05-15 at 15:55 +0200, Fr?d?ric Danis wrote: > When a Bluetooth headset is connected only to HFP profile (not connected > to A2DP) and host streams to it, a crash occurs if host disconnects. > > When HFP disconnects, audio thread will fail on POLLHUP then generate > a message to set PA profile to Off before ending. > If this message is managed before PA unload bluetooth device module, > all works fine. > But, if this message is managed during module unload, this finish by > re-entrance in release code (stop_thread) and a crash. > > This fix prevents to process profile change when module is unloading. Thanks, pushed. -- Tanu